StatefulServiceContext Class
- java.
lang. Object - ServiceContext
- system.
fabric. StatefulServiceContext
- system.
public class StatefulServiceContext extends ServiceContext
Represents the service context that the stateful service is operating under.
Constructor Summary
Constructor | Description |
---|---|
StatefulServiceContext(NodeContext nodeContext, CodePackageActivationContext codePackageActivationContext, String serviceTypeName, URI serviceName, byte[] initializationData, UUID partitionId, long replicaId) |
Instantiates the system.fabric.StatefulServiceContext object. |
Method Summary
Modifier and Type | Method and Description |
---|---|
long |
getReplicaId()
Gets the stateful service replica ID. |
Inherited Members
ServiceContext.getCodePackageActivationContext()
ServiceContext.getInitializationData()
ServiceContext.getNodeContext()
ServiceContext.getPartitionId()
ServiceContext.getReplicaOrInstanceId()
ServiceContext.getServiceName()
ServiceContext.getServiceTypeName()
ServiceContext.getTraceId()
ServiceContext.ServiceContext(NodeContext nodeContext, CodePackageActivationContext codePackageActivationContext, String serviceTypeName, URI serviceName, byte[] initializationData, UUID partitionId, long replicaOrInstanceId)
Constructor Details
StatefulServiceContext
public StatefulServiceContext(NodeContext nodeContext, CodePackageActivationContext codePackageActivationContext, String serviceTypeName, URI serviceName, byte[] initializationData, UUID partitionId, long replicaId)
Instantiates the system.fabric.StatefulServiceContext object.
Parameters:
nodeContext
- The node context, which contains information about the node where the stateless service instance is running.
codePackageActivationContext
- The code package activation context, which contains information from the service manifest and the currently activated code package, like work directory, context ID etc.
serviceTypeName
- The service type name.
serviceName
- The service name.
initializationData
- The service initialization data, which represents custom initialization data provided by the creator of the service.
partitionId
- The partition ID.
replicaId
- The replica ID.
Method Details
getReplicaId
public long getReplicaId()
Gets the stateful service replica ID.
Returns:
The stateful service replica ID.
Applies to
GitHub で Microsoft と共同作業する
このコンテンツのソースは GitHub にあります。そこで、issue や pull request を作成および確認することもできます。 詳細については、共同作成者ガイドを参照してください。
Azure SDK for Java