ServiceControl is the backend to ServicePulse and ServiceInsight. It is a background process that collects useful information about an NServiceBus system. This includes messages that cannot be processed, their exceptions, and the ability to collect every message flowing through the system. It can also collect saga state changes, endpoint heartbeats, and perform custom checks. This information is exposed to ServicePulse and ServiceInsight via an HTTP API.
ServiceControl can also be configured to collect detailed performance metrics for display in ServicePulse.
For more information on how ServiceControl, ServicePulse, and ServiceInsight work together, refer to the Particular Service Platform.
After installation, the ServiceControl Management Utility provides the ability to add, upgrade and delete ServiceControl instances. There are three different instances that can be created:
- Error instances
This is the most commonly used ServiceControl instance and indispensable to ensure the correct working of an NServiceBus system. Together with SerivcePulse, it provides the ability to visualize and retry failed messages.
- Audit instances
This ServiceControl Audit instance provides valuable information about the message flow through a system.
- Monitoring instances
For performance monitoring and analyzing additional metrics, especially in production.
After downloading ServiceControl, the ServiceControl Management utility is available in the Windows Start menu. The ServiceControl instances mentioned above need to be installed and configured via the Management utility.
Read more about how to install and configure ServiceControl instances.
NServiceBus endpoints need to be configured to send data about their operations to a set of centralized queues that are unique to the system. ServiceControl monitors these queues, collects and processes this data.
Note that the data is sent to queues, even when ServiceControl is down. When ServiceControl becomes available, it will process the messages that were stored in the queue while it was offline.
To enable ServiceControl to gather this information, configure the endpoints appropriately:
- Configure recoverability to collect failed messages.
- Enable auditing to collect all messages.
- Install plugins to monitor endpoint health, collect saga state changes, and use custom checks.
See Optimizing ServiceControl for use in different environments for more information about practical considerations.