This article shows how to terminate the JVM of a specific ActiveMQ broker using the REST API.
Terminate JVM on ActiveMQ Broker
POST /activemq/brokers/{nodeName}/{managerName}/{brokerName}/terminate-jvm/{exitCode}
Terminates the JVM process of the specified ActiveMQ broker with the given exit code. This operation will shut down the broker’s JVM entirely.
Example Request
curl -X 'POST' \ 'http://<hostname>:8019/rest/v1/activemq/brokers/CMACTIVEMQ/Activemq-server/DemoBroker/terminate-jvm/1' \ -H 'accept: */*' \ -H 'Authorization: Basic QWRtaW46YWRtaW4=' \ -d ''
Path Parameters
| Parameter | Type | Description |
|---|---|---|
nodeName | string | The node name. |
managerName | string | The manager name. |
brokerName | string | The ActiveMQ Broker name. |
exitCode | integer | The exit code with which to terminate the JVM. Example: 1. |
Query Parameters
| Parameter | Type | Description |
|---|---|---|
jobDate | integer | Schedule job date (Unix timestamp). |
jobTags | string | Comma-separated list of job tags (used only with jobDate). |
validateAccessForUser | string | Validate endpoint access for user. |
Response Codes
201 Object created – JVM terminated successfully.
304 Action failed – JVM termination request did not complete.
* Error response – Returns error details in
ErrorPojo.
Response Header
201 Object created – JVM terminated successfully.
access-control-allow-credentials: true access-control-allow-origin: http://<hostname>:8019 date: Fri,26 Sep 2025 13:44:43 GMT server: Jetty(10.0.22) vary: Origin