CygNet Service Endpoints

The remaining sections of the sample_appsettings.json file define information about the sources, including each name, role, what type of data each endpoint provides, the data format, protocol, and data retrieval information. There must be an endpoint section for each of the CygNet services you wish to query:

Each service is identified in the endpointConnections object in the gateway section of the appsettings.json file.

Note: The following table lists all common properties found in each endpoint section of the appsettings.json file. For service endpoints with unique data retrieval properties, this will be noted, and linked to the endpoint topics that follow. Properties are listed in the order they appear in the sample_appsettings.json file. Use the search or link to find a particular property.

Property Description Required Property: Value Example

name

The root object that contains the name of the endpoint, specified in endpointConnections.

yes

"name": "MyUIS",

 

"name": "MyVHS",

 

"name": "MyDDS",

 

role

The function performed by the endpoint. Possible values include:

  • Source — Where the data to be published is collected from CygNet
  • Target — Where the collected data is published to the MQTT server

The publisher endpoint role must be set to "Target" and the CygNet service endpoints' role must be set to "Source".

yes

"role": "Source",

 

"role": "Target",

dataFormat

Defines the data format of the source or target data. Contains required and optional members.

yes

"dataFormat": {

"type": "CvsService"

},

type

Specifies the dataFormat type. Possible values include:

  • CvsService (formerly called "UisService", which is deprecated but supported for backwards compatibility)
  • VhsService
  • DdsService

yes

See dataFormat.

defaultFormat

Specifies the format of the transaction data published from a DDS endpoint only. Possible values include:

  • xml — The entire XML transaction is published in a single metric
  • Structured — The XML transaction is parsed by Link and the elements are published as individual metrics

no

"dataFormat": {

"type": "DdsService",

"defaultFormat": "xml"

},

protocol

Contains service protocol information including type, hostname, and port number.

yes

"protocol": {

"type": "CygNet",

"hostname": "CYGNET.UIS",

"port": 30102

},

type

Specifies the protocol type. For CygNet service endpoints the protocol type is "CygNet".

Formerly "CygNetDevice" or "CygNetHistorian", is deprecated but supported for backwards compatibility.

yes

See protocol.

hostname

The host name of the endpoint. Possible values include:

  • If the type is "MQTT", the name or IP address of the server
  • If the type is "CygNet", the appropriate Site.Service

The hostname is required for the target endpoint and the CVS endpoint but is optional for the VHS and DDS endpoints. Since this hostname is in the service endpoint, the value is the Site Service endpoint name.

  • VHS endpoint — Will be auto-resolved from the CVS endpoint if the hostname is not specified, or if the value is either "<empty>", or "<auto>", and the VHS endpoint is connected to the CVS endpoint in endpointConnections
  • DDS endpoint — Will be auto-resolved from the CVS endpoint if the hostname is not specified, or if the value is either "<empty>", or "<auto>", and the DDS endpoint is connected to the CVS endpoint in endpointConnections

yes &

no

See protocol.

port

The port number for the source or target host. Possible values include:

  • If the type is "MQTT", this refers to the port on the MQTT server.
  • If the type is "CygNet", this refers to the domain of the CygNet Site.Service.

The port is required for the CVS endpoint but is optional for the DDS and VHS endpoints. Since this port is in the service endpoint, the value is the domain of the CygNet Site.Service.

  • VHS endpoint — Will be auto-resolved from the CVS endpoint if the port is not specified or if the value is 0, and the VHS endpoint is connected to the CVS endpoint in endpointConnections
  • DDS endpoint — Will be auto-resolved from the CVS endpoint if the port is not specified or if the value is 0, and the DDS endpoint is connected to the CVS endpoint in endpointConnections

yes &

no

See protocol.

data

Defines the data to be published from the CVS, VHS and DDS. See each endpoint, which contains different objects:

yes

////////// CVS ENDPOINT //////////

"data": {

"defaultPollingFreq": 1000,

"defaultQualityOfService": "Medium",

"strictPointValues": true,

"strictPointValidation": true,

"pointLimit": "200",

"publish": [

{

"pointTag": "CYGNET.UIS::METERFAC1.TEMP",

"historicalRollup": {

"type": "ThinMinMax",

"unit": "Minutes",

"period": 10,

"topOfUnit": 0

},

"pollingFreq": 60000

},

{

"facilityFilter": "facility_id='METERFAC2' or (facility_id='998800*' and facility_desc='PK*')"

},

{

"pointFilter": "activestatus='Y' and facilityid='METERFAC3'",

},

{

"facilityFilter": "facility_desc='PL*'",

"pointFilter": "uniformdatacode='PRESS'",

"qualityOfService": "Low"

}]

data continued

yes

////////// VHS ENDPOINT //////////

"data": {

"defaultPollingFreq": 10000,

"pointDiscoveryFreq": 3600000, //one hour

"defaultQualityOfService": "Medium",

"publish": [

{

"dynaCard": "CYGNET.UIS::WELLPILOTC001"

},

{

"dynaCard": "CYGNET.UIS::WELLPILOT002"

}

]

}

data continued

yes

////////// DDS ENDPOINT //////////

"data": {

"defaultPollingFreq": 10000,

"defaultQualityOfService": "Medium", // Low, Medium, or High. For MQTT endpoints, this translates to 0, 1, or 2 QoS levels, respectively.

"publish": [

{

"device": "WELLPILOT001",

"dataGroup": "DynaCard"

},

{

"device": "WELLPILOT002",

"dataGroup": "DynaCard"

}

]

}

defaultPollingFreq

The default global frequency (in ms) used to poll data specified in the publish object of each endpoint. Used when a publishobject does not specify its own pollingFreq value. The minimum value is 200 (ms).

no

See data.

defaultQualityOfService

The default global value used to determine how data is sent to the server in the case of intermittent communication failure. The defaultQualityOfService is a way of specifying the quality of service (QoS) of the MQTT protocol and is used when a publish object does not specify its own qualityOfService value. Possible values include:

  • Low — The message delivered to the server at most once
  • Medium — The message delivered to the server at least once
  • High — The message delivered to the server exactly once

Note: If the endpoint type is "AWS", only Low or Medium values can be used. If a High value is configured, the value will be changed to Medium.

no

See data.

strictPointValues

Determines how the real-time point type and value is published for the CVS endpoint only. Possible values include:

  • true — If set to "true" (default), publishing of a point is blocked and a warning is logged if its current value does not match the associated point type (for example, if the point is an Analog point and the value is a string)
  • false — If set to "false", the point will be published but the type shown in the Sparkplug payload will match the current value rather than the associated point type (for example, if the point is an Analog point and the value is a string, the Sparkplug payload will report its value type as "string")

Link applies the following logic when strictPointValues is configured in the appsettings.json file.

  • When strictPointValues is true and
    • if a point has the wrong value type prior to birth, Link will not birth the device and polling will not happen
    • if the point has the wrong value type after birth, Link will publish an error and continue polling the other points on that device
  • When strictPointValues is false, Link will publish whatever the value is regardless of type

Note: strictPointValues is not supported for history rollup points in 9.4.2000.

no

See data (for the CVS endpoint only).

strictPointValidation

Determines if point data is missing, disabled, or other security errors prevent data from getting published for the CVS endpoint only. Possible values include:

  • true — If set to "true" (default), Link will Link will generate an error if the point is missing, disabled, or inaccessible, etc.
  • false — If set to "false", Link will publish the metric, except the value will be null and there will be a property called "Error" with a value of "PointNotFound". Link will publish a null value when a configured point is unitialized.

Link applies the following logic when strictPointValidation is configured in the appsettings.json file.

  • When strictPointValidation is true and
    • if a point is missing prior to birth, Link will not birth the device and polling will not happen
    • if the point becomes missing after birth, Link will publish an error and continue polling the other points on that device
  • When strictPointValidation is false, Link will publish an error and successfully birth the device and poll other points on the device

strictPointValidation relates to the environment mode setting (Edge vs SCADA):

  • in Edge mode enable strictPointValidation, because any configuration error should to be addressed immediately, before the Edge box publishes anything
  • in SCADA mode you can be more lenient, and allow a device to be polled even of one or two points are configured incorrectly

Note: strictPointValidation also applies to history rollup, when rollup is defined in appsettings.json file, but a point is not configured to report to VHS.

no

See data (for the CVS endpoint only).

pointLimit

Specifies the maximum number of points that Link can publish at any point in time.

Note: The recommended maximum amount of data that Link can publish at any point in time is 200,000 points across all CVS service endpoints in each Link instance. If you plan to publish more than 200,000 points, ensure that the system has sufficient CPU and memory to process the total amount of data, as attempting to publish too many points can severely impact a system's performance.

no

If pointLimit is not defined, Link will look at the limit from the license file.

See data (for the CVS endpoint only).

pointDiscoveryFreq

Specifies the frequency (in ms) used to query the PNT service for any new DynaCard points that will be published from the VHS. Configured for a VHS endpoint only.

no

See data (for the VHS endpoint only).

publish

Specifies the data to be published to the target from the CVS, VHS, and DDS endpoints. The contents of this object depend on the type of endpoint:

yes

See publish examples for CVS, VHS, and DDS endpoints.


More: