AI agents: use the documentation index at llms.txt to locate machine-readable pages. This section is indexed by https://docs.particular.net/servicecontrol/llms.txt. The markdown version of this page is served as plain text. An MCP server at /mcp serves the same content via the search_docs and read_doc tools; it is read-only and needs no credentials. Markdown versions of documentation pages are available by appending .md to the page URL. Directory URLs use index.md. They are served as text/plain because some retrieval backends reject text/markdown.

Replacing an Audit instance using Containers

Component:
ServiceControl

This article describes how to replace an Audit instance with zero downtime when using containers. For an overview of the process and details for other deployment scenarios, see Replacing an Audit Instance.

Add a new audit instance

First, a new audit instance must be created. Deploy a new Audit instance container with its own database container.

Add the instance to RemoteInstances

Next, modify the Error instance container by changing the REMOTEINSTANCES environment variable to include the new Audit instance's API URL. The value must be a JSON-encoded array containing objects that each have an api_uri value.

This example of a REMOTEINSTANCES value (as it would be used in a docker run command) shows two remote instances on the Docker internal network:

-e REMOTEINSTANCES='[{"api_uri":"http://audit-1:44444/api"},{"api_uri":"http://audit-2:44444/api"}]'

Disable audit queue ingestion on the old instance

Modify the old Audit instance container by specifying the INGESTAUDITMESSAGES environment variable with a value of false.

Decommission the old audit instance

When the audit retention period has expired and there are no remaining processed messages in the database, you can decommission the old audit instance:

  1. Adjust the REMOTEINSTANCES environment variable as described above except remove the old Audit instance URI from the collection.
  2. Remove the old Audit instance by stopping and removing the container, as well as the related database container.

Related Articles