ServiceControl

ServiceControl

Docker app from Syknight's Repository

Overview

Particular Software ServiceControl The 'particular/servicecontrol' image is part of the Particular Service Platform, which includes the following images: - particular/servicecontrol-ravendb | The database used by the error/audit instances (https://docs.particular.net/servicecontrol/ravendb/containers) - particular/servicecontrol | The primary/error instance, which includes error handling and recoverability (https://docs.particular.net/servicecontrol/servicecontrol-instances/) - particular/servicecontrol-audit | The audit instance, which stores audit data, and can be scaled out to multiple audit instances (https://docs.particular.net/servicecontrol/audit-instances/) - particular/servicecontrol-monitoring | The monitoring instance, which tracks runtime information like throughput, queue length, and other metrics (https://docs.particular.net/servicecontrol/monitoring-instances/) - particular/servicepulse | The web application that provides a front end for recoverability and monitoring features (https://docs.particular.net/servicepulse/) Additional optional environment variables can be configured. See "https://docs.particular.net/servicecontrol/servicecontrol-instances/configuration".

ServiceControl Current Version

ServiceControl is the monitoring brain in the Particular Service Platform, which includes NServiceBus and tools to build, monitor, and debug distributed systems. ServiceControl collects data on every single message flowing through the system (Audit Queue), errors (Error Queue), as well as additional information regarding sagas, endpoints heartbeats, and custom checks (Control Queue). The information is then exposed to ServicePulse and ServiceInsight via an HTTP API and SignalR notifications.

See the ServiceControl documentation for more information.

How to run/debug locally

ServiceControl, ServiceControl.Audit, and ServiceControl.Monitoring can be run/debugged locally by following these steps:

  • Edit the app.config file of the instance type that needs to be run/debugged to select which transport and persistence to use.
    • The configuration file contains commented settings for each supported transport and persistence. It also provides some guidance on additional required settings for specific persisters.
    • ServiceControl works with a RavenDB persistence
    • ServiceControl.Audit can work with RavenDB or an InMemory persistence
  • Run or debug the project as usual

A video demo showing how to set it up is available on the Particular YouTube channel:

Containers

All containers are created on each build and pushed to the GitHub container registry where the various instance type can be accessed by their names and run locally.

[!NOTE] ghcr images are only tagged with the exact version, e.g. docker pull ghcr.io/particular/servicecontrol:6.3.1. If you are unsure what tags are available in ghcr, go to https://github.com/Particular/ServiceControl/pkgs/container/{name}, e.g. https://github.com/Particular/ServiceControl/pkgs/container/servicecontrol to view available tags.

It's also possible to locally test containers built from PRs in GitHub Container Registry

Infrastructure setup

If the instance is executed for the first time, it must set up the required infrastructure. To do so, once the instance is configured to use the selected transport and persister, run it in setup mode. This can be done by using the Setup {instance name} launch profile that is defined in the launchSettings.json file of each instance. When started in setup mode, the instance will start as usual, execute the setup process, and exit. At this point the instance can be run normally by using the non-setup launch profile.

Secrets

Testing using the CI workflow depends on the following secrets. The Particular values for these secrets are stored in the secure note named ServiceControl Repo Secrets.

  • LICENSETEXT: Particular Software license text
  • AWS_ACCESS_KEY_ID: For testing SQS
  • AWS_SECRET_ACCESS_KEY: For testing SQS
  • AWS_REGION: For testing SQS

Running the Tests

Running all tests all the times takes a lot of resources. Tests are filtered based on the ServiceControl_TESTS_FILTER environment variable. To run only a subset, e.g., SQS transport tests, define the variable as ServiceControl_TESTS_FILTER=SQS. The following list contains all the possible ServiceControl_TESTS_FILTER values:

  • Default - runs only non-transport-specific tests
  • AzureServiceBus
  • AzureStorageQueues
  • MSMQ
  • RabbitMQ
  • SqlServer
  • SQS

NOTE: If no variable is defined all tests will be executed.

Security Configuration

Documentation for configuring security features:

Local testing guides:

How to developer test the PowerShell Module

Steps:

  • Build the solution

  • Open PowerShell 7

  • Import the module by specifying the path to the ServiceControl git repo folder deploy\PowerShellModules\Particular.ServiceControl.Management

    Import-Module -Name S:\ServiceControl\deploy\PowerShellModules\Particular.ServiceControl.Management -Verbose 
    
    • If there are any issues running the import script, try setting the execution policy to "unrestricted' by running the following script in PowerShell 7 admin mode. Then run the command to import the module.
      Set-ExecutionPolicy Unrestricted
      
  • Now that the module has been successfully imported, enter any of the ServiceControl PowerShell scripts to test them out. Eg: the following creates a new ServiceControl Instance

    $serviceControlInstance = New-ServiceControlInstance `
       -Name 'Test.DEV.ServiceControl' `
       -InstallPath C:\ServiceControl\Bin `
       -DBPath C:\ServiceControl\DB `
       -LogPath C:\ServiceControl\Logs `
       -Port 44334 `
       -DatabaseMaintenancePort 44335 `
       -Transport 'RabbitMQ - Direct routing topology (quorum queues)' `
       -ConnectionString 'host=localhost;username=guest;password=guest' `
       -ErrorQueue errormq `
       -ErrorRetentionPeriod 10:00:00:00 `
       -Acknowledgements RabbitMQBrokerVersion310
    

Integrated ServicePulse

Since version 6.13, ServiceControl ships with a copy of ServicePulse and can host it from an Error instance.

ServiceControl Error instances have a reference to the Particular.ServicePulse.Core package; this contains the ServicePulse assets, along with the code required to serve them out of an ASP.NET web host.

Install ServiceControl on Unraid in a few clicks.

Find ServiceControl in Community Apps on your Unraid server, review the template, and click Install. Unraid handles the Docker app or plugin setup from the published template.

Open the Apps tab on your Unraid server Search Community Apps for ServiceControl Review the template variables and paths Click Install

Requirements

See "https://docs.particular.net/servicecontrol/servicecontrol-instances/deployment/containers" and "https://github.com/Particular/PlatformContainerExamples".

Download Statistics

241,119
Total Downloads
14,179
This Month
15,086
Avg / Month

Total Downloads Over Time

Loading chart...

Related apps

Explore more like this

Explore all

Details

Repository
particular/servicecontrol:latest
Last Updated2026-06-23
First Seen2025-08-05

Runtime arguments

Network
bridge
Shell
sh
Privileged
false

Template configuration

RAVENDB_CONNECTIONSTRINGVariable

Provides the URL to connect to the database container that stores the instance's data. The database container should be exclusive to the instance, and not shared by any other ServiceControl instances.

Default
http://servicecontrol-db:8080
Value
http://servicecontrol-ravendb:8080
REMOTEINSTANCESVariable

A JSON structure that provides URLs for the Error instance to access any remote audit instances (https://docs.particular.net/servicecontrol/servicecontrol-instances/remotes). When requesting audit data via the ServiceControl API, the Error instance will communicate to each of the remote audit instances in a scatter-gather pattern and then return the combined results. The URLs must be accessible by the Error instance directly, not constructed to be accessible from an external browser.

Default
[{"api_uri":"http://servicecontrol-audit:44444/api"}]
TRANSPORTTYPEVariable

Determines the message transport used to communicate with message endpoints. See

CONNECTIONSTRINGVariable

Provides the connection information to connect to the chosen transport. The form of this connection string is different for every message transport. See

PARTICULARSOFTWARE_LICENSEVariable

The Particular Software license, which is most easily provided to a container as an environment variable (https://docs.particular.net/nservicebus/licensing/#license-management-environment-variable). The environment variable should contain the full multi-line contents of the license file. A license file can also be volume-mounted to the container. e.g. (/usr/share/ParticularSoftware/license.xml). If no license file is provided, a trial license will be automatically enabled.

ParticularPlatformFilesPathrw

An optionally shared folder used by all Particular Service Platform containers. The license file can be saved here and shared among all containers.

Target
/usr/share/ParticularSoftware/
Default
/mnt/cache/appdata/ParticularPlatform/
Canonical PortPorttcp

33333 is the canonical port exposed by the error instance API within the container, though this port can be mapped to any desired external port.

Target
33333
Default
33333
Value
33333