All endpoints require the X-Management-Token header. rqboot defaults to Ricequant123; override it in real deployments.
-
GET /management/infoReturns structured descriptive metadata for rendering:producerTypetitlesubtitletileoverviewsectionsEach item or section carries display type information so hubs and UIs can render non-RicequantMainprocesses without hardcoded rqboot assumptions.
-
GET /management/stateReturns dynamic runtime state: lifecycle state, health, uptime, current debug level, and JVM memory/CPU/thread metrics. -
POST /management/log-levelRequest body:{"level":"2"}. Changes the active debug level immediately and returns the updated level. -
POST /management/shutdownRequest body:{"reason":"operator requested"}. Initiates graceful shutdown through the existingRicequantMain.stop()path. -
GET /management/commandsReturns the user-registered custom management commands. Each item includes command name, title, description, and typed argument metadata. -
POST /management/commands/{commandName}Executes a user-registered custom management command. The request body is a JSON object whose fields match the declared command arguments. Supported argument types arelong,double,string,long[],double[], andstring[].
200success400malformed JSON or missing required fields401missing or invalid management token405wrong HTTP method500unexpected server error
- Clients should fetch
/management/infoon page load or manual refresh. - Clients should poll
/management/stateperiodically. - Force refresh from a hub should call both endpoints explicitly and store the fetch timestamp.
- Clients can fetch
/management/commandswhen opening an operator command panel or when the process definition changes.
Applications receive ManagementCommandService in IApplication.start(...). Register commands there before the service is exposed to users.
The example below shows the registration pattern; replace cacheService with your own application service.
import com.ricequant.rqboot.jmx.server.IJmxBeanRegistry;
import com.ricequant.rqboot.management.server.ManagementCommandArg;
import com.ricequant.rqboot.management.server.ManagementCommandArgType;
import com.ricequant.rqboot.management.server.ManagementCommandService;
import com.ricequant.rqboot.management.server.ManagementCustomCommand;
import java.util.List;
import java.util.Map;
@Override
public void start(IJmxBeanRegistry beanRegistry, ManagementCommandService managementCommandService) throws Exception {
managementCommandService.registerCustomCommand(
new ManagementCustomCommand("reloadCache", "Reload Cache", "Reload cache entries for one account.", List.of(
ManagementCommandArg.required("accountId", ManagementCommandArgType.STRING)
.titled("Account ID"),
ManagementCommandArg.optional("partitions", ManagementCommandArgType.LONG_ARRAY)
.titled("Partitions")
.describedAs("Optional partition ids to reload."))),
args -> {
String accountId = (String) args.get("accountId");
long[] partitions = args.containsKey("partitions") ? (long[]) args.get("partitions") : new long[0];
int reloaded = cacheService.reload(accountId, partitions);
return Map.of(
"ok", true,
"accountId", accountId,
"reloadedEntries", reloaded);
});
// continue normal startup...
}Each command defines:
name: stable API identifier used inPOST /management/commands/{name}title: user-facing display labeldescription: operator help textargs: ordered typed argument definitions
Command names must match [A-Za-z0-9_.-]+.
longdoublestringlong[]double[]string[]
At execution time, ManagementCommandService validates:
- unknown argument names
- missing required arguments
- argument type conversion
The handler receives already-converted Java values:
LongDoubleStringlong[]double[]String[]
A custom command handler returns Map<String, Object>. The returned structure should be JSON-serializable.
Recommended value types:
StringNumberBooleannullMap<String, Object>List<?>- arrays
Command list response:
{
"items": [
{
"name": "reloadCache",
"title": "Reload Cache",
"description": "Reload cache entries for one account.",
"args": [
{
"name": "accountId",
"title": "Account ID",
"description": "Account ID",
"type": "string",
"required": true
},
{
"name": "partitions",
"title": "Partitions",
"description": "Optional partition ids to reload.",
"type": "long[]",
"required": false
}
]
}
]
}Command execution request:
{
"accountId": "sim-001",
"partitions": [1, 3, 7]
}Command execution response:
{
"ok": true,
"accountId": "sim-001",
"reloadedEntries": 42
}- Register commands during application startup, before operators begin using the service.
- Keep handlers fast and deterministic where possible.
- Return explicit fields rather than embedding human-only text.
- For destructive operations, require explicit arguments such as IDs, scopes, or reasons.
- These commands are available both over direct HTTP management and, when applicable, through the gateway-hub management tunnel.