SetSubscriptionDurable Method is used to set a Subscription into a mode where MonitoredItem data and event queues are stored and delivered even if an OPC UA Client was disconnected for a longer time or the OPC UA Server was restarted. Its intended use is defined in OPC 10000-4.
Signature
SetSubscriptionDurable(
[in] UInt32 subscriptionId
[in] UInt32 lifetimeInHours
[out] UInt32 revisedLifetimeInHours
);
Argument |
Description |
subscriptionId |
Identifier of the Subscription. |
lifetimeInHours |
The requested lifetime in hours for the durable Subscription. |
revisedLifetimeInHours |
The revised lifetime in hours the Server applied to the durable Subscription. |
Method Result Codes (defined in Call Service)
Result Code |
Description |
Bad_SubscriptionIdInvalid |
Defined in OPC 10000-4 |
Bad_InvalidState |
Defined in OPC 10000-4 This is returned when a Subscription already contains MonitoredItems. |
Bad_UserAccessDenied |
Defined in OPC 10000-4 The Method was not called in the context of the Session that owns the Subscription. |
Table 116 specifies the AddressSpace representation for the SetSubscriptionDurable Method.
Table 116 – SetSubscriptionDurable Method AddressSpace definition
Attribute |
Value |
||||
BrowseName |
SetSubscriptionDurable |
||||
References |
NodeClass |
BrowseName |
DataType |
TypeDefinition |
ModellingRule |
HasProperty |
Variable |
InputArguments |
Argument[] |
PropertyType |
Mandatory |
HasProperty |
Variable |
OutputArguments |
Argument[] |
PropertyType |
Mandatory |
Conformance Units |
|||||
Base Info ServerType |