| { |
| "documentation": "https://lucene.apache.org/solr/guide/solrcloud-autoscaling-api.html", |
| "description": "The Scaling API provides API for adding cluster level scaling rules, triggers and event listeners", |
| "methods": [ |
| "GET", |
| "POST" |
| ], |
| "url": { |
| "paths": [ |
| "/cluster/autoscaling", |
| "/cluster/autoscaling/diagnostics", |
| "/cluster/autoscaling/suggestions" |
| ] |
| }, |
| "commands": { |
| "set-trigger": { |
| "type": "object", |
| "description": "The set-trigger command allows you to add and update triggers on various system metrics", |
| "properties": { |
| "name": { |
| "type": "string", |
| "description": "The name of the trigger" |
| }, |
| "event": { |
| "type": "string", |
| "description": "The event type on which to set a trigger" |
| }, |
| "waitFor": { |
| "type": "string", |
| "description": "The amount of time to wait after the trigger condition is satisfied before trigger is activated" |
| }, |
| "lowerBound": { |
| "type": "number", |
| "description": "The lower bound of the condition below which the trigger is activated" |
| }, |
| "upperBound": { |
| "type": "number", |
| "description": "The upper bound of the condition below which the trigger is activated" |
| }, |
| "enabled": { |
| "type": "boolean", |
| "description": "The state of the trigger" |
| }, |
| "actions": { |
| "type": "array", |
| "description": "The actions to be performed in sequence when the trigger is activated", |
| "items": { |
| "type": "object" |
| } |
| } |
| }, |
| "required": [ |
| "name", |
| "event" |
| ] |
| }, |
| "remove-trigger": { |
| "description": "Remove a trigger", |
| "type": "object", |
| "properties": { |
| "name": { |
| "type": "string", |
| "description": "The name of the trigger to be removed" |
| }, |
| "removeListeners": { |
| "type": "boolean", |
| "description": "If true, all listeners of this triggers are deleted together with the trigger" |
| } |
| }, |
| "required": [ |
| "name" |
| ] |
| }, |
| "set-listener": { |
| "description": "The set-listener command lets you add a listener to a trigger", |
| "type": "object", |
| "properties": { |
| "name": { |
| "type": "string", |
| "description": "The name of the listener" |
| }, |
| "trigger": { |
| "type": "string", |
| "description": "The name of the trigger to listen to" |
| }, |
| "stage": { |
| "type": "array", |
| "description": "The stage of the trigger for which to listen", |
| "items": { |
| "type": "string" |
| } |
| }, |
| "beforeAction": { |
| "type": "array", |
| "description": "The name of the action before which the listener should be notified", |
| "items": { |
| "type": "string" |
| } |
| }, |
| "afterAction": { |
| "type": "array", |
| "description": "The name of the action after which the listener should be notified", |
| "items": { |
| "type": "string" |
| } |
| }, |
| "class": { |
| "type": "string", |
| "description": "The listener class to be notified once the given stage of the given trigger is activated" |
| } |
| }, |
| "required": [ |
| "name", |
| "trigger", |
| "class" |
| ], |
| "additionalProperties": true |
| }, |
| "remove-listener": { |
| "description": "Remove a listener", |
| "type": "object", |
| "properties": { |
| "name": { |
| "type": "string", |
| "description": "The name of the listener to be removed" |
| } |
| }, |
| "required": [ |
| "name" |
| ] |
| }, |
| "suspend-trigger": { |
| "description": "Pauses a trigger until an explicit resume is invoked or if the optional timeout expires", |
| "type": "object", |
| "properties": { |
| "name": { |
| "type": "string", |
| "description": "The name of the trigger to be suspended or '#EACH' to suspend all triggers" |
| }, |
| "timeout": { |
| "type": "string", |
| "description": "Optional timeout after which all triggers are resumed automatically" |
| } |
| }, |
| "required": [ |
| "name" |
| ] |
| }, |
| "resume-trigger": { |
| "description": "Resumes a suspended trigger", |
| "type": "object", |
| "properties": { |
| "name": { |
| "type": "string", |
| "description": "The name of the trigger to be resumed or '#EACH' to resume all triggers" |
| } |
| }, |
| "required": [ |
| "name" |
| ] |
| }, |
| "set-policy": { |
| "type": "object", |
| "description": "The set-policy command allows you to add and update policies that apply to collections", |
| /* "patternProperties": { |
| "^.+$": { |
| "type": "array" |
| } |
| },*/ |
| "additionalProperties": true |
| }, |
| "set-cluster-policy": { |
| "type": "array", |
| "description": "The set-cluster-policy command allows you to add and update cluster-level policy that acts as the base for all collection level policies, if any" |
| }, |
| "set-cluster-preferences": { |
| "type": "array", |
| "description": "The set-cluster-preferences command allows you to add and update cluster-level preferences that are used to sort nodes for selection in cluster operations" |
| }, |
| "remove-policy": { |
| "description": "Remove a policy", |
| "type": "object", |
| "properties": { |
| "name": { |
| "type": "string", |
| "description": "The name of the policy to be removed" |
| } |
| }, |
| "required": [ |
| "name" |
| ] |
| }, |
| "set-properties": { |
| "type": "object", |
| "description": "The set-properties command allows you to add and update properties used by autoscaling framework itself", |
| "additionalProperties": true |
| } |
| } |
| } |