Connecting to ServiceControl
Version 2 of the ServiceControl plugins changes the way that the plugins connect to ServiceControl. The plugins no longer derive a ServiceControl queue name from the Error/Audit queues. Additional configuration is required to specify the location of the ServiceControl queue.
Configuration File
The location of the ServiceControl queue can be specified once for all plugins in via an appSetting
in the endpoint configuration file.
<appSettings>
<add key="ServiceControl/Queue"
value="particular.servicecontrol@machine" />
</appSettings>
Code
The location of the ServiceControl queue can be specified via plugin-specific extensions to the endpoint configuration.
Heartbeats
var endpointConfiguration = new EndpointConfiguration("myendpoint");
endpointConfiguration.HeartbeatPlugin(
serviceControlQueue: "ServiceControl_Queue");
CustomChecks
var endpointConfiguration = new EndpointConfiguration("myendpoint");
endpointConfiguration.CustomCheckPlugin(
serviceControlQueue: "ServiceControl_Queue");
SagaAudit
var endpointConfiguration = new EndpointConfiguration("myendpoint");
endpointConfiguration.SagaPlugin(
serviceControlQueue: "particular.servicecontrol@machine");