set_authoritative — sets the type of a point.
(set_authoritative domain flag)
domain
The name of the data domain.
flag
A value of 1 indicates that this application is
authoritative. A value of 0 indicates that the
DataHub instance should be authoritative .
A message indicating success or error. Please refer to Return Syntax for details.
This command tells the DataHub instance that this application should be
considered the authoritative source of data for this data domain. The DataHub
instance will keep track of which data points this application has written to
it, and will automatically mark those points as being Not
Connected quality when the application disconnects. This provides
a mechanism for the DataHub instance to provide quality information even if the
source application exits unexpectedly.
There should only ever be one authoritative source of data for any data point,
though the DataHub instance will not enforce this. If more than one application
claims to be authoritative for a data point, that point will be given a
Not Connected quality even if another authoritative
application is still connected.
The command (set_authoritative domain 0) does NOT mean
"turn off authoritative status". It informs the DataHub instance that the
application is explicitly non-authoritative, and by extension that DataHub instance
should behave as if it is authoritative. Normally this is only meaningful
between DataHub instances constructing a tunnel. An application should not send
(set_authoritative domain 0) to a DataHub instance. If an
application does not want to be authoritative for a data domain, it simply
should not send a set_authoritative command.