Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Manage MariaDB MaxScale programmatically using the REST API. This interface allows for the dynamic administration and monitoring of MaxScale resources like servers, services, and listeners.
inetunixGET /v1/users/inet/:name{
"data": {
"attributes": {
"account": "admin",
"created": "Fri, 05 Jan 2024 07:23:54 GMT",
"last_login": "Fri, 05 Jan 2024 07:24:11 GMT",
"last_update": null,
"name": "admin"
},
"id": "admin",
"links": {
"self": "http://localhost:8989/v1/users/inet/admin/"
},
"type": "inet"
},
"links": {
"self": "http://localhost:8989/v1/users/inet/admin/"
}
}GET /v1/users/inet{
"data": [
{
"attributes": {
"account": "admin",
"created": "Fri, 05 Jan 2024 07:23:54 GMT",
"last_login": "Fri, 05 Jan 2024 07:24:11 GMT",
"last_update": null,
"name": "admin"
},
"id": "admin",
"links": {
"self": "http://localhost:8989/v1/users/inet/admin/"
},
"type": "inet"
}
],
"links": {
"self": "http://localhost:8989/v1/users/inet/"
}
}GET /v1/users/unix/:nameGET /v1/users/unixGET /v1/users{
"data": [
{
"attributes": {
"account": "admin",
"created": "Fri, 05 Jan 2024 07:23:54 GMT",
"last_login": "Fri, 05 Jan 2024 07:24:11 GMT",
"last_update": null,
"name": "admin"
},
"id": "admin",
"links": {
"self": "http://localhost:8989/v1/users/inet/admin/"
},
"type": "inet"
}
],
"links": {
"self": "http://localhost:8989/v1/users/inet/"
}
}POST /v1/users/inet{
"data": {
"id": "my-user", // The user to create
"type": "inet", // The type of the user
"attributes": {
"password": "my-password", // The password to use for the user
"account": "basic" // The type of the account
}
}
}Status: 204 No ContentPOST /v1/users/unix{
"data": {
"id": "jdoe", // Account name
"type": "unix" // Account type
"attributes": {
"account": "basic" // Type of the user account in MaxScale
}
}
}Status: 204 No ContentDELETE /v1/users/inet/:nameStatus: 204 No ContentDELETE /v1/users/unix/:nameStatus: 204 No ContentPATCH /v1/users/inet/:name{
"data": {
"attributes": {
"password": "new-password"
}
}
}Status: 204 No ContentfiltersGET /v1/filters/:name{
"data": {
"attributes": {
"filter_diagnostics": null,
"module": "qlafilter",
"parameters": {
"append": false,
"duration_unit": "ms",
"exclude": null,
"filebase": "/tmp/qla.log",
"flush": true,
"log_data": "date,user,query",
"log_type": "unified",
"match": null,
"module": "qlafilter",
"newline_replacement": " ",
"options": "",
"separator": ",",
"source": null,
"source_exclude": null,
"source_match": null,
"use_canonical_form": false,
"user": null,
"user_exclude": null,
"user_match": null
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
}
},
"id": "QLA",
"links": {
"self": "http://localhost:8989/v1/filters/QLA/"
},
"relationships": {
"services": {
"data": [
{
"id": "Read-Connection-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/filters/QLA/relationships/services/"
}
}
},
"type": "filters"
},
"links": {
"self": "http://localhost:8989/v1/filters/QLA/"
}
}GET /v1/filters{
"data": [
{
"attributes": {
"filter_diagnostics": null,
"module": "qlafilter",
"parameters": {
"append": false,
"duration_unit": "ms",
"exclude": null,
"filebase": "/tmp/qla.log",
"flush": true,
"log_data": "date,user,query",
"log_type": "unified",
"match": null,
"module": "qlafilter",
"newline_replacement": " ",
"options": "",
"separator": ",",
"source": null,
"source_exclude": null,
"source_match": null,
"use_canonical_form": false,
"user": null,
"user_exclude": null,
"user_match": null
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
}
},
"id": "QLA",
"links": {
"self": "http://localhost:8989/v1/filters/QLA/"
},
"relationships": {
"services": {
"data": [
{
"id": "Read-Connection-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/filters/QLA/relationships/services/"
}
}
},
"type": "filters"
},
{
"attributes": {
"module": "hintfilter",
"parameters": {
"module": "hintfilter"
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
}
},
"id": "Hint",
"links": {
"self": "http://localhost:8989/v1/filters/Hint/"
},
"relationships": {
"services": {
"data": [
{
"id": "Read-Connection-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/filters/Hint/relationships/services/"
}
}
},
"type": "filters"
}
],
"links": {
"self": "http://localhost:8989/v1/filters/"
}
}POST /v1/filters{
"data": {
"id": "test-filter", // Name of the filter
"type": "filters",
"attributes": {
"module": "qlafilter", // The filter uses the qlafilter module
"parameters": { // Filter parameters
"filebase": "/tmp/qla.log"
}
}
}
}PATCH /v1/filters/:name{
"data": {
"attributes": {
"parameters": {
"match": ".*users.*"
}
}
}
}DELETE /v1/filters/:filtermonitorsGET /v1/monitors/:name{
"data": {
"attributes": {
"module": "mariadbmon",
"monitor_diagnostics": {
"master": "server1",
"master_gtid_domain_id": 0,
"primary": null,
"server_info": [
{
"gtid_binlog_pos": "0-3000-5",
"gtid_current_pos": "0-3000-5",
"lock_held": null,
"master_group": null,
"name": "server1",
"read_only": false,
"server_id": 3000,
"slave_connections": [],
"state_details": null
},
{
"gtid_binlog_pos": "0-3000-5",
"gtid_current_pos": "0-3000-5",
"lock_held": null,
"master_group": null,
"name": "server2",
"read_only": false,
"server_id": 3001,
"slave_connections": [
{
"connection_name": "",
"gtid_io_pos": "",
"last_io_error": "",
"last_sql_error": "",
"master_host": "127.0.0.1",
"master_port": 3000,
"master_server_id": 3000,
"master_server_name": "server1",
"seconds_behind_master": 0,
"slave_io_running": "Yes",
"slave_sql_running": "Yes",
"using_gtid": "No"
}
],
"state_details": null
}
],
"state": "Idle"
},
"parameters": {
"assume_unique_hostnames": true,
"auto_failover": false,
"auto_rejoin": false,
"backend_connect_attempts": 1,
"backend_connect_timeout": "3000ms",
"backend_read_timeout": "3000ms",
"backend_write_timeout": "3000ms",
"backup_storage_address": null,
"backup_storage_path": null,
"cooperative_monitoring_locks": "none",
"cs_admin_api_key": null,
"cs_admin_base_path": "/cmapi/0.4.0",
"cs_admin_port": 8640,
"demotion_sql_file": null,
"disk_space_check_interval": "0ms",
"disk_space_threshold": null,
"enforce_read_only_slaves": false,
"enforce_simple_topology": false,
"enforce_writable_master": false,
"events": "all,master_down,master_up,slave_down,slave_up,server_down,server_up,synced_down,synced_up,donor_down,donor_up,lost_master,lost_slave,lost_synced,lost_donor,new_master,new_slave,new_synced,new_donor",
"failcount": 5,
"failover_timeout": "90000ms",
"handle_events": true,
"journal_max_age": "28800000ms",
"maintenance_on_low_disk_space": true,
"mariadb-backup_parallel": 1,
"mariadb-backup_use_memory": "1G",
"master_conditions": "primary_monitor_master",
"master_failure_timeout": "10000ms",
"module": "mariadbmon",
"monitor_interval": "1000ms",
"password": "*****",
"promotion_sql_file": null,
"rebuild_port": 4444,
"replication_custom_options": null,
"replication_master_ssl": false,
"replication_password": "*****",
"replication_user": "maxuser",
"script": null,
"script_max_replication_lag": -1,
"script_timeout": "90000ms",
"servers_no_promotion": null,
"slave_conditions": "",
"ssh_check_host_key": true,
"ssh_keyfile": null,
"ssh_port": 22,
"ssh_timeout": "10000ms",
"ssh_user": null,
"switchover_on_low_disk_space": false,
"switchover_timeout": "90000ms",
"type": "monitor",
"user": "maxuser",
"verify_master_failure": true
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Running",
"ticks": 12
},
"id": "MariaDB-Monitor",
"links": {
"self": "http://localhost:8989/v1/monitors/MariaDB-Monitor/"
},
"relationships": {
"servers": {
"data": [
{
"id": "server1",
"type": "servers"
},
{
"id": "server2",
"type": "servers"
}
],
"links": {
"related": "http://localhost:8989/v1/servers/",
"self": "http://localhost:8989/v1/monitors/MariaDB-Monitor/relationships/servers/"
}
},
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/monitors/MariaDB-Monitor/relationships/services/"
}
}
},
"type": "monitors"
},
"links": {
"self": "http://localhost:8989/v1/monitors/MariaDB-Monitor/"
}
}GET /v1/monitors{
"data": [
{
"attributes": {
"module": "mariadbmon",
"monitor_diagnostics": {
"master": "server1",
"master_gtid_domain_id": 0,
"primary": null,
"server_info": [
{
"gtid_binlog_pos": "0-3000-5",
"gtid_current_pos": "0-3000-5",
"lock_held": null,
"master_group": null,
"name": "server1",
"read_only": false,
"server_id": 3000,
"slave_connections": [],
"state_details": null
},
{
"gtid_binlog_pos": "0-3000-5",
"gtid_current_pos": "0-3000-5",
"lock_held": null,
"master_group": null,
"name": "server2",
"read_only": false,
"server_id": 3001,
"slave_connections": [
{
"connection_name": "",
"gtid_io_pos": "",
"last_io_error": "",
"last_sql_error": "",
"master_host": "127.0.0.1",
"master_port": 3000,
"master_server_id": 3000,
"master_server_name": "server1",
"seconds_behind_master": 0,
"slave_io_running": "Yes",
"slave_sql_running": "Yes",
"using_gtid": "No"
}
],
"state_details": null
}
],
"state": "Idle"
},
"parameters": {
"assume_unique_hostnames": true,
"auto_failover": false,
"auto_rejoin": false,
"backend_connect_attempts": 1,
"backend_connect_timeout": "3000ms",
"backend_read_timeout": "3000ms",
"backend_write_timeout": "3000ms",
"backup_storage_address": null,
"backup_storage_path": null,
"cooperative_monitoring_locks": "none",
"cs_admin_api_key": null,
"cs_admin_base_path": "/cmapi/0.4.0",
"cs_admin_port": 8640,
"demotion_sql_file": null,
"disk_space_check_interval": "0ms",
"disk_space_threshold": null,
"enforce_read_only_slaves": false,
"enforce_simple_topology": false,
"enforce_writable_master": false,
"events": "all,master_down,master_up,slave_down,slave_up,server_down,server_up,synced_down,synced_up,donor_down,donor_up,lost_master,lost_slave,lost_synced,lost_donor,new_master,new_slave,new_synced,new_donor",
"failcount": 5,
"failover_timeout": "90000ms",
"handle_events": true,
"journal_max_age": "28800000ms",
"maintenance_on_low_disk_space": true,
"mariadb-backup_parallel": 1,
"mariadb-backup_use_memory": "1G",
"master_conditions": "primary_monitor_master",
"master_failure_timeout": "10000ms",
"module": "mariadbmon",
"monitor_interval": "1000ms",
"password": "*****",
"promotion_sql_file": null,
"rebuild_port": 4444,
"replication_custom_options": null,
"replication_master_ssl": false,
"replication_password": "*****",
"replication_user": "maxuser",
"script": null,
"script_max_replication_lag": -1,
"script_timeout": "90000ms",
"servers_no_promotion": null,
"slave_conditions": "",
"ssh_check_host_key": true,
"ssh_keyfile": null,
"ssh_port": 22,
"ssh_timeout": "10000ms",
"ssh_user": null,
"switchover_on_low_disk_space": false,
"switchover_timeout": "90000ms",
"type": "monitor",
"user": "maxuser",
"verify_master_failure": true
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Running",
"ticks": 12
},
"id": "MariaDB-Monitor",
"links": {
"self": "http://localhost:8989/v1/monitors/MariaDB-Monitor/"
},
"relationships": {
"servers": {
"data": [
{
"id": "server1",
"type": "servers"
},
{
"id": "server2",
"type": "servers"
}
],
"links": {
"related": "http://localhost:8989/v1/servers/",
"self": "http://localhost:8989/v1/monitors/MariaDB-Monitor/relationships/servers/"
}
},
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/monitors/MariaDB-Monitor/relationships/services/"
}
}
},
"type": "monitors"
}
],
"links": {
"self": "http://localhost:8989/v1/monitors/"
}
}POST /v1/monitors{
data: {
"id": "test-monitor", // Name of the monitor
"type": "monitors",
"attributes": {
"module": "mariadbmon", // The monitor uses the mariadbmon module
"parameters": { // Monitor parameters
"monitor_interval": 1000,
"user": "maxuser,
"password": "maxpwd"
}
},
"relationships": { // List of server relationships that this monitor uses
"servers": {
"data": [ // This monitor uses two servers
{
"id": "server1",
"type": "servers"
},
{
"id": "server2",
"type": "servers"
}
]
}
}
}
}PATCH /v1/monitors/:namePATCH /v1/monitors/:name/relationships/serversPATCH /v1/monitors/my-monitor/relationships/servers
{
data: [
{ "id": "my-server", "type": "servers" }
]
}PATCH /v1/monitors/my-monitor/relationships/servers
{
data: []
}DELETE /v1/monitors/:namePUT /v1/monitors/:name/stopPUT /v1/monitors/:name/startGET /v1/sessions/:id{
"data": {
"attributes": {
"client": {
"cipher": "",
"connection_attributes": {
"_client_name": "libmariadb",
"_client_version": "3.3.4",
"_os": "Linux",
"_pid": "502300",
"_platform": "x86_64",
"_server_host": "127.0.0.1"
},
"sescmd_history_len": 1,
"sescmd_history_stored_metadata": 0,
"sescmd_history_stored_responses": 1
},
"connected": "Fri, 05 Jan 2024 07:24:06 GMT",
"connections": [
{
"cipher": "",
"connection_id": 129,
"server": "server1"
}
],
"idle": 5.2000000000000002,
"io_activity": 16,
"log": [],
"memory": {
"connection_buffers": {
"backends": {
"server1": {
"misc": 662,
"readq": 0,
"total": 662,
"writeq": 0
}
},
"client": {
"misc": 654,
"readq": 65536,
"total": 66190,
"writeq": 0
},
"total": 66852
},
"exec_metadata": 0,
"last_queries": 0,
"sescmd_history": 485,
"total": 67337,
"variables": 0
},
"parameters": {
"log_debug": false,
"log_error": false,
"log_info": false,
"log_notice": false,
"log_warning": false
},
"port": 40664,
"queries": [],
"remote": "127.0.0.1",
"seconds_alive": 5.209291554,
"state": "Session started",
"thread": 2,
"user": "maxuser"
},
"id": "1",
"links": {
"self": "http://localhost:8989/v1/sessions/1/"
},
"relationships": {
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/sessions/1/relationships/services/"
}
}
},
"type": "sessions"
},
"links": {
"self": "http://localhost:8989/v1/sessions/1/"
}
}GET /v1/sessions{
"data": [
{
"attributes": {
"client": {
"cipher": "",
"connection_attributes": {
"_client_name": "libmariadb",
"_client_version": "3.3.4",
"_os": "Linux",
"_pid": "502300",
"_platform": "x86_64",
"_server_host": "127.0.0.1"
},
"sescmd_history_len": 1,
"sescmd_history_stored_metadata": 0,
"sescmd_history_stored_responses": 1
},
"connected": "Fri, 05 Jan 2024 07:24:06 GMT",
"connections": [
{
"cipher": "",
"connection_id": 129,
"server": "server1"
}
],
"idle": 5.2000000000000002,
"io_activity": 16,
"log": [],
"memory": {
"connection_buffers": {
"backends": {
"server1": {
"misc": 662,
"readq": 0,
"total": 662,
"writeq": 0
}
},
"client": {
"misc": 654,
"readq": 65536,
"total": 66190,
"writeq": 0
},
"total": 66852
},
"exec_metadata": 0,
"last_queries": 0,
"sescmd_history": 485,
"total": 67337,
"variables": 0
},
"parameters": {
"log_debug": false,
"log_error": false,
"log_info": false,
"log_notice": false,
"log_warning": false
},
"port": 40664,
"queries": [],
"remote": "127.0.0.1",
"seconds_alive": 5.2105843680000001,
"state": "Session started",
"thread": 2,
"user": "maxuser"
},
"id": "1",
"links": {
"self": "http://localhost:8989/v1/sessions/1/"
},
"relationships": {
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/sessions/1/relationships/services/"
}
}
},
"type": "sessions"
}
],
"links": {
"self": "http://localhost:8989/v1/sessions/"
}
}PATCH /v1/sessions/:id{
"data": {
"attributes": {
"parameters": {
"log_info": true
}
}
}
}{
"data": {
"attributes": {
"relationships": {
"filters": {
"data": [
{ "id": "my-cache-filter" },
{ "id": "my-log-filter" }
]
}
}
}
}
}POST /v1/sessions/:id/restartPOST /v1/sessions/restartDELETE /v1/sessions/:idGET /v1/listeners/:name{
"data": {
"attributes": {
"parameters": {
"MariaDBProtocol": {
"allow_replication": true
},
"address": "::",
"authenticator": null,
"authenticator_options": null,
"connection_init_sql_file": null,
"connection_metadata": [
"character_set_client=auto",
"character_set_connection=auto",
"character_set_results=auto",
"max_allowed_packet=auto",
"system_time_zone=auto",
"time_zone=auto",
"tx_isolation=auto",
"maxscale=auto"
],
"port": 4006,
"protocol": "MariaDBProtocol",
"proxy_protocol_networks": null,
"service": "RW-Split-Router",
"socket": null,
"sql_mode": "default",
"ssl": false,
"ssl_ca": null,
"ssl_cert": null,
"ssl_cert_verify_depth": 9,
"ssl_cipher": null,
"ssl_crl": null,
"ssl_key": null,
"ssl_verify_peer_certificate": false,
"ssl_verify_peer_host": false,
"ssl_version": "MAX",
"type": "listener",
"user_mapping_file": null
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Running"
},
"id": "RW-Split-Listener",
"relationships": {
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/listeners/RW-Split-Listener/relationships/services/"
}
}
},
"type": "listeners"
},
"links": {
"self": "http://localhost:8989/v1/listeners/RW-Split-Listener/"
}
}GET /v1/listeners{
"data": [
{
"attributes": {
"parameters": {
"MariaDBProtocol": {
"allow_replication": true
},
"address": "::",
"authenticator": null,
"authenticator_options": null,
"connection_init_sql_file": null,
"connection_metadata": [
"character_set_client=auto",
"character_set_connection=auto",
"character_set_results=auto",
"max_allowed_packet=auto",
"system_time_zone=auto",
"time_zone=auto",
"tx_isolation=auto",
"maxscale=auto"
],
"port": 4006,
"protocol": "MariaDBProtocol",
"proxy_protocol_networks": null,
"service": "RW-Split-Router",
"socket": null,
"sql_mode": "default",
"ssl": false,
"ssl_ca": null,
"ssl_cert": null,
"ssl_cert_verify_depth": 9,
"ssl_cipher": null,
"ssl_crl": null,
"ssl_key": null,
"ssl_verify_peer_certificate": false,
"ssl_verify_peer_host": false,
"ssl_version": "MAX",
"type": "listener",
"user_mapping_file": null
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Running"
},
"id": "RW-Split-Listener",
"relationships": {
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/listeners/RW-Split-Listener/relationships/services/"
}
}
},
"type": "listeners"
},
{
"attributes": {
"parameters": {
"MariaDBProtocol": {
"allow_replication": true
},
"address": "::",
"authenticator": null,
"authenticator_options": null,
"connection_init_sql_file": null,
"connection_metadata": [
"character_set_client=auto",
"character_set_connection=auto",
"character_set_results=auto",
"max_allowed_packet=auto",
"system_time_zone=auto",
"time_zone=auto",
"tx_isolation=auto",
"maxscale=auto"
],
"port": 4008,
"protocol": "MariaDBProtocol",
"proxy_protocol_networks": null,
"service": "Read-Connection-Router",
"socket": null,
"sql_mode": "default",
"ssl": false,
"ssl_ca": null,
"ssl_cert": null,
"ssl_cert_verify_depth": 9,
"ssl_cipher": null,
"ssl_crl": null,
"ssl_key": null,
"ssl_verify_peer_certificate": false,
"ssl_verify_peer_host": false,
"ssl_version": "MAX",
"type": "listener",
"user_mapping_file": null
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Running"
},
"id": "Read-Connection-Listener",
"relationships": {
"services": {
"data": [
{
"id": "Read-Connection-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/listeners/Read-Connection-Listener/relationships/services/"
}
}
},
"type": "listeners"
}
],
"links": {
"self": "http://localhost:8989/v1/listeners/"
}
}POST /v1/listeners{
"data": {
"id": "my-listener",
"type": "listeners",
"attributes": {
"parameters": {
"port": 3306
}
},
"relationships": {
"services": {
"data": [
{"id": "RW-Split-Router", "type": "services"}
]
}
}
}
}PATCH /v1/listeners/:nameDELETE /v1/listeners/:namePUT /v1/listeners/:name/stopPUT /v1/listeners/:name/startfields[TYPE]=field1,field2...GET /v1/auth{
"meta": {
"token": "eyJhbGciOiJIUzI1NiJ9.eyJhY2NvdW50IjoiYWRtaW4iLCJhdWQiOiJhZG1pbiIsImV4cCI6MTY4OTk1MDgwNCwiaWF0IjoxNjg5OTIyMDA0LCJpc3MiOiJtYXhzY2FsZSIsInN1YiI6ImFkbWluIn0.LRFeXaFAhYNBm7kLIosUpR2nOgd5H-gv3MpuLaCpPvk"
}
}GET /v1/auth?persist=yesGET /v1/auth?max-age=28800Authorization: Bearer eyJhbGciOiJIUzI1NiJ9.eyJhdWQiOiJhZG1pbiIsImV4cCI6MTU4MzI1NDE1MSwiaWF0IjoxNTgzMjI1MzUxLCJpc3MiOiJtYXhzY2FsZSJ9.B1BqhjjKaCWKe3gVXLszpOPfeu8cLiwSb4CMIJAoyqwfilter=id=and(ge(50),le(100))filter=id=or(eq(1),eq(5),eq(10))filter=id=not(eq(1),eq(5),eq(10)){
"error": {
"detail" : "The new `/servers/` resource is missing the `port` parameter"
}
}POST /v1/sql/query?token=eyJhbGciOiJIUzI1NiJ9.eyJhdWQiOiJhZG1pbiIsImV4cCI6MTU4MzI1NDE1MSwiaWF0IjoxNTgzMjI1MzUxLCJpc3MiOiJtYXhzY2FsZSJ9.B1BqhjjKaCWKe3gVXLszpOPfeu8cLiwSb4CMIJAoyqwGET /v1/sql/:id{
"data": {
"attributes": {
"seconds_idle": 0.0013705639999999999,
"sql": null,
"target": "server1",
"thread_id": 10
},
"id": "96be0ffe-10fb-4ed1-8e66-a17ef1eea0fe",
"links": {
"related": "http://localhost:8989/v1/sql/96be0ffe-10fb-4ed1-8e66-a17ef1eea0fe/queries/",
"self": "http://localhost:8989/v1/sql/96be0ffe-10fb-4ed1-8e66-a17ef1eea0fe/"
},
"type": "sql"
},
"links": {
"self": "http://localhost:8989/v1/sql/96be0ffe-10fb-4ed1-8e66-a17ef1eea0fe/"
}
}GET /v1/sql{
"data": [
{
"attributes": {
"seconds_idle": 0.0010341230000000001,
"sql": null,
"target": "server1",
"thread_id": 12
},
"id": "90761656-3352-420b-83e7-0dcef691552a",
"links": {
"related": "http://localhost:8989/v1/sql/90761656-3352-420b-83e7-0dcef691552a/queries/",
"self": "http://localhost:8989/v1/sql/90761656-3352-420b-83e7-0dcef691552a/"
},
"type": "sql"
},
{
"attributes": {
"seconds_idle": 0.002397377,
"sql": null,
"target": "server1",
"thread_id": 11
},
"id": "98a8b5c5-3632-4f0f-98bb-0dc440a3409a",
"links": {
"related": "http://localhost:8989/v1/sql/98a8b5c5-3632-4f0f-98bb-0dc440a3409a/queries/",
"self": "http://localhost:8989/v1/sql/98a8b5c5-3632-4f0f-98bb-0dc440a3409a/"
},
"type": "sql"
}
],
"links": {
"self": "http://localhost:8989/v1/sql/"
}
}POST /v1/sql{
"user": "jdoe",
"password": "my-s3cret",
"target": "server1",
"db": "test",
"timeout": 15
}{
"target": "odbc",
"connection_string": "Driver=MariaDB;SERVER=127.0.0.1;UID=maxuser;PWD=maxpwd"
}{
"data": {
"attributes": {
"seconds_idle": 7.6394000000000001e-5,
"sql": null,
"target": "server1",
"thread_id": 13
},
"id": "f4e38d96-99b4-479e-ac36-5f3b437aff99",
"links": {
"related": "http://localhost:8989/v1/sql/f4e38d96-99b4-479e-ac36-5f3b437aff99/queries/",
"self": "http://localhost:8989/v1/sql/f4e38d96-99b4-479e-ac36-5f3b437aff99/"
},
"type": "sql"
},
"links": {
"self": "http://localhost:8989/v1/sql/f4e38d96-99b4-479e-ac36-5f3b437aff99/"
},
"meta": {
"token": "eyJhbGciOiJIUzI1NiJ9.eyJhdWQiOiJmNGUzOGQ5Ni05OWI0LTQ3OWUtYWMzNi01ZjNiNDM3YWZmOTkiLCJleHAiOjE2ODk5NTA4MDQsImlhdCI6MTY4OTkyMjAwNCwiaXNzIjoibXhzLXF1ZXJ5Iiwic3ViIjoiZjRlMzhkOTYtOTliNC00NzllLWFjMzYtNWYzYjQzN2FmZjk5In0.gCKYl7XwwnMLjJbQT6UShDuK8aJ6gessmredQ1i0On4"
}
}DELETE /v1/sql/:idPOST /v1/sql/:id/reconnectPOST /v1/sql/:id/clonePOST /v1/sql/:id/queries{
"sql": "SELECT * FROM test.t1",
"max_rows": 1000
}{
"data": {
"attributes": {
"execution_time": 0.00028492799999999999,
"results": [
{
"complete": true,
"data": [
[
1
],
[
2
],
[
3
]
],
"fields": [
"id"
],
"metadata": [
{
"catalog": "def",
"decimals": 0,
"length": 11,
"name": "id",
"schema": "test",
"table": "t1",
"type": "LONG"
}
]
}
],
"sql": "SELECT id FROM test.t1"
},
"id": "b7243d92-5bc6-4814-80fb-6772831ead4b.1",
"type": "queries"
},
"links": {
"self": "http://localhost:8989/v1/sql/b7243d92-5bc6-4814-80fb-6772831ead4b/queries/b7243d92-5bc6-4814-80fb-6772831ead4b.1/"
}
}{
"data": {
"attributes": {
"execution_time": 0.00012686699999999999,
"results": [
{
"errno": 1064,
"message": "You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'TABLE test.t1' at line 1",
"sqlstate": "42000"
}
],
"sql": "SELECT syntax_error FROM TABLE test.t1"
},
"id": "621bacd9-48fd-436c-afda-b4e4d0d7b228.1",
"type": "queries"
},
"links": {
"self": "http://localhost:8989/v1/sql/621bacd9-48fd-436c-afda-b4e4d0d7b228/queries/621bacd9-48fd-436c-afda-b4e4d0d7b228.1/"
}
}{
"data": {
"attributes": {
"execution_time": 0.000474659,
"results": [
{
"affected_rows": 0,
"last_insert_id": 0,
"warnings": 0
}
],
"sql": "CREATE TABLE test.my_table(id INT)"
},
"id": "60005d40-c034-4aa3-94de-b15c14d9c91c.1",
"type": "queries"
},
"links": {
"self": "http://localhost:8989/v1/sql/60005d40-c034-4aa3-94de-b15c14d9c91c/queries/60005d40-c034-4aa3-94de-b15c14d9c91c.1/"
}
}{
"data": {
"attributes": {
"execution_time": 0.00014767200000000001,
"results": [
{
"complete": true,
"data": [
[
1
]
],
"fields": [
"1"
],
"metadata": [
{
"catalog": "def",
"decimals": 0,
"length": 1,
"name": "1",
"schema": "",
"table": "",
"type": "LONG"
}
]
}
],
"sql": "SELECT 1"
},
"id": "5999b711-d190-4f0e-8322-db3ce3bd97a2.1",
"type": "queries"
},
"links": {
"self": "http://localhost:8989/v1/sql/5999b711-d190-4f0e-8322-db3ce3bd97a2/queries/5999b711-d190-4f0e-8322-db3ce3bd97a2.1/"
}
}{
"data": {
"attributes": {
"execution_time": 0.0,
"sql": "SELECT 1"
},
"id": "3d23f7e0-6a83-4282-94a5-8a1089d56f72.1",
"type": "queries"
},
"links": {
"self": "http://localhost:8989/v1/sql/3d23f7e0-6a83-4282-94a5-8a1089d56f72/queries/3d23f7e0-6a83-4282-94a5-8a1089d56f72.1/"
}
}GET /v1/sql/:id/queries/:query_id{
"data": {
"attributes": {
"execution_time": 0.00011945,
"results": [
{
"complete": true,
"data": [
[
1
]
],
"fields": [
"1"
],
"metadata": [
{
"catalog": "def",
"decimals": 0,
"length": 1,
"name": "1",
"schema": "",
"table": "",
"type": "LONG"
}
]
}
],
"sql": "SELECT 1"
},
"id": "63ec5e96-2bfa-40a9-b631-425b4e3e993c.1",
"type": "queries"
},
"links": {
"self": "http://localhost:8989/v1/sql/63ec5e96-2bfa-40a9-b631-425b4e3e993c/queries/63ec5e96-2bfa-40a9-b631-425b4e3e993c.1/"
}
}DELETE /v1/sql/:id/queries/:query_idPOST /v1/sql/:id/cancelGET /v1/sql/odbc/drivers{
"data": [
{
"attributes": {
"description": "ODBC for MariaDB",
"driver": "/usr/lib/libmaodbc.so",
"driver64": "/usr/lib64/libmaodbc.so",
"fileusage": "1"
},
"id": "MariaDB",
"type": "drivers"
}
],
"links": {
"self": "http://localhost:8989/v1/sql/odbc/drivers/"
}
}POST /v1/sql/:id/etl/prepare- `mariadb`
Extract data from a MariaDB database.
- `postgresql`
Extract data from a PostgreSQL database. This requires that the PostgreSQL
ODBC driver is installed on the MaxScale server. This driver is often
available in the package manager of your operating system.
- `generic`
Extract data from a generic ODBC source. This uses the ODBC catalog
functions to determine the table layout. The results provided by this are
not as accurate as the specialized versions but it can serve as a good
starting point from which manual modifications to the SQL can be done.
This ETL type requires that the table catalog is provided at the top level
with the `catalog` field. The meaning of the catalog differs between
database implementations.{
"type": "mariadb",
"target": "e2a56d2f-6514-4926-8dba-dca0c4ae3a86",
"tables": [
{
"table": "t1",
"schema": "test"
}
]
}{
"data": {
"attributes": {
"execution_time": 0.0062226729999999997,
"results": {
"ok": true,
"stage": "prepare",
"tables": [
{
"create": "CREATE DATABASE IF NOT EXISTS `test`;\nUSE `test`;\nCREATE TABLE `t1` (\n `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,\n `data` varchar(255) DEFAULT NULL,\n UNIQUE KEY `id` (`id`)\n) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci",
"insert": "INSERT INTO `test`.`t1` (`id`,`data`) VALUES (?,?)",
"schema": "test",
"select": "SELECT `id`,`data` FROM `test`.`t1`",
"table": "t1"
}
]
},
"sql": "ETL"
},
"id": "31dc09b7-ec09-4e6d-b098-e925f706233c.1",
"type": "queries"
},
"links": {
"self": "http://localhost:8989/v1/sql/31dc09b7-ec09-4e6d-b098-e925f706233c/queries/31dc09b7-ec09-4e6d-b098-e925f706233c.1/"
}
}POST /v1/sql/:id/etl/start{
"data": {
"attributes": {
"execution_time": 0.0094386039999999997,
"results": {
"ok": true,
"stage": "load",
"tables": [
{
"create": "CREATE DATABASE IF NOT EXISTS `test`;\nUSE `test`;\nCREATE TABLE `t1` (\n `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,\n `data` varchar(255) DEFAULT NULL,\n UNIQUE KEY `id` (`id`)\n) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci",
"execution_time": 0.0033923809999999999,
"insert": "INSERT INTO `test`.`t1` (`id`,`data`) VALUES (?,?)",
"rows": 1,
"schema": "test",
"select": "SELECT `id`,`data` FROM `test`.`t1`",
"table": "t1"
}
]
},
"sql": "ETL"
},
"id": "1391b67e-58a7-4be3-b686-2498cb3a0e06.1",
"type": "queries"
},
"links": {
"self": "http://localhost:8989/v1/sql/1391b67e-58a7-4be3-b686-2498cb3a0e06/queries/1391b67e-58a7-4be3-b686-2498cb3a0e06.1/"
}
}servicesGET /v1/services/:name{
"data": {
"attributes": {
"connections": 0,
"listeners": [
{
"attributes": {
"parameters": {
"MariaDBProtocol": {
"allow_replication": true
},
"address": "::",
"authenticator": null,
"authenticator_options": null,
"connection_init_sql_file": null,
"connection_metadata": [
"character_set_client=auto",
"character_set_connection=auto",
"character_set_results=auto",
"max_allowed_packet=auto",
"system_time_zone=auto",
"time_zone=auto",
"tx_isolation=auto",
"maxscale=auto"
],
"port": 4008,
"protocol": "MariaDBProtocol",
"proxy_protocol_networks": null,
"service": "Read-Connection-Router",
"socket": null,
"sql_mode": "default",
"ssl": false,
"ssl_ca": null,
"ssl_cert": null,
"ssl_cert_verify_depth": 9,
"ssl_cipher": null,
"ssl_crl": null,
"ssl_key": null,
"ssl_verify_peer_certificate": false,
"ssl_verify_peer_host": false,
"ssl_version": "MAX",
"type": "listener",
"user_mapping_file": null
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Running"
},
"id": "Read-Connection-Listener",
"relationships": {
"services": {
"data": [
{
"id": "Read-Connection-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/listeners/Read-Connection-Listener/relationships/services/"
}
}
},
"type": "listeners"
}
],
"parameters": {
"auth_all_servers": false,
"connection_keepalive": "300000ms",
"disable_sescmd_history": false,
"enable_root_user": false,
"force_connection_keepalive": false,
"idle_session_pool_time": "-1ms",
"localhost_match_wildcard_host": true,
"log_auth_warnings": true,
"log_debug": false,
"log_info": false,
"log_notice": false,
"log_warning": false,
"master_accept_reads": true,
"max_connections": 0,
"max_replication_lag": "0ms",
"max_sescmd_history": 50,
"multiplex_timeout": "60000ms",
"net_write_timeout": "0ms",
"password": "*****",
"prune_sescmd_history": true,
"rank": "primary",
"retain_last_statements": -1,
"router": "readconnroute",
"router_options": "master",
"session_trace": false,
"strip_db_esc": true,
"type": "service",
"user": "maxuser",
"user_accounts_file": null,
"user_accounts_file_usage": "add_when_load_ok",
"version_string": null,
"wait_timeout": "0ms"
},
"router": "readconnroute",
"router_diagnostics": {
"queries": 0,
"server_query_statistics": []
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"started": "Fri, 05 Jan 2024 07:23:54 GMT",
"state": "Started",
"statistics": {
"active_operations": 0,
"avg_sescmd_history_length": 0.0,
"avg_session_lifetime": 0.0,
"connections": 0,
"failed_auths": 0,
"max_connections": 0,
"max_sescmd_history_length": 0,
"max_session_lifetime": 0,
"routed_packets": 0,
"total_connections": 0
},
"total_connections": 0,
"users": [
{
"default_role": "",
"global_priv": false,
"host": "localhost",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": false,
"user": "mariadb.sys"
},
{
"default_role": "",
"global_priv": true,
"host": "127.0.0.1",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "maxuser"
},
{
"default_role": "",
"global_priv": true,
"host": "%",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "maxuser"
},
{
"default_role": "",
"global_priv": true,
"host": "localhost",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "root"
},
{
"default_role": "",
"global_priv": true,
"host": "%",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "root"
}
],
"users_last_update": "Fri, 05 Jan 2024 07:23:55 GMT"
},
"id": "Read-Connection-Router",
"links": {
"self": "http://localhost:8989/v1/services/Read-Connection-Router/"
},
"relationships": {
"filters": {
"data": [
{
"id": "QLA",
"type": "filters"
},
{
"id": "Hint",
"type": "filters"
}
],
"links": {
"related": "http://localhost:8989/v1/filters/",
"self": "http://localhost:8989/v1/services/Read-Connection-Router/relationships/filters/"
}
},
"listeners": {
"data": [
{
"id": "Read-Connection-Listener",
"type": "listeners"
}
],
"links": {
"related": "http://localhost:8989/v1/listeners/",
"self": "http://localhost:8989/v1/services/Read-Connection-Router/relationships/listeners/"
}
},
"servers": {
"data": [
{
"id": "server1",
"type": "servers"
},
{
"id": "server2",
"type": "servers"
}
],
"links": {
"related": "http://localhost:8989/v1/servers/",
"self": "http://localhost:8989/v1/services/Read-Connection-Router/relationships/servers/"
}
}
},
"type": "services"
},
"links": {
"self": "http://localhost:8989/v1/services/Read-Connection-Router/"
}
}GET /v1/services{
"data": [
{
"attributes": {
"connections": 1,
"listeners": [
{
"attributes": {
"parameters": {
"MariaDBProtocol": {
"allow_replication": true
},
"address": "::",
"authenticator": null,
"authenticator_options": null,
"connection_init_sql_file": null,
"connection_metadata": [
"character_set_client=auto",
"character_set_connection=auto",
"character_set_results=auto",
"max_allowed_packet=auto",
"system_time_zone=auto",
"time_zone=auto",
"tx_isolation=auto",
"maxscale=auto"
],
"port": 4006,
"protocol": "MariaDBProtocol",
"proxy_protocol_networks": null,
"service": "RW-Split-Router",
"socket": null,
"sql_mode": "default",
"ssl": false,
"ssl_ca": null,
"ssl_cert": null,
"ssl_cert_verify_depth": 9,
"ssl_cipher": null,
"ssl_crl": null,
"ssl_key": null,
"ssl_verify_peer_certificate": false,
"ssl_verify_peer_host": false,
"ssl_version": "MAX",
"type": "listener",
"user_mapping_file": null
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Running"
},
"id": "RW-Split-Listener",
"relationships": {
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/listeners/RW-Split-Listener/relationships/services/"
}
}
},
"type": "listeners"
}
],
"parameters": {
"auth_all_servers": false,
"causal_reads": "none",
"causal_reads_timeout": "10000ms",
"connection_keepalive": "300000ms",
"delayed_retry": false,
"delayed_retry_timeout": "10000ms",
"disable_sescmd_history": false,
"enable_root_user": false,
"force_connection_keepalive": false,
"idle_session_pool_time": "-1ms",
"lazy_connect": false,
"localhost_match_wildcard_host": true,
"log_auth_warnings": true,
"log_debug": false,
"log_info": false,
"log_notice": false,
"log_warning": false,
"master_accept_reads": false,
"master_failure_mode": "fail_on_write",
"master_reconnection": true,
"max_connections": 0,
"max_replication_lag": "0ms",
"max_sescmd_history": 50,
"max_slave_connections": 255,
"multiplex_timeout": "60000ms",
"net_write_timeout": "0ms",
"optimistic_trx": false,
"password": "*****",
"prune_sescmd_history": true,
"rank": "primary",
"retain_last_statements": -1,
"retry_failed_reads": true,
"reuse_prepared_statements": false,
"router": "readwritesplit",
"session_trace": false,
"slave_connections": 255,
"slave_selection_criteria": "least_current_operations",
"strict_multi_stmt": false,
"strict_sp_calls": false,
"strict_tmp_tables": true,
"strip_db_esc": true,
"transaction_replay": false,
"transaction_replay_attempts": 5,
"transaction_replay_checksum": "full",
"transaction_replay_max_size": 1048576,
"transaction_replay_retry_on_deadlock": false,
"transaction_replay_retry_on_mismatch": false,
"transaction_replay_safe_commit": true,
"transaction_replay_timeout": "30000ms",
"type": "service",
"use_sql_variables_in": "all",
"user": "maxuser",
"user_accounts_file": null,
"user_accounts_file_usage": "add_when_load_ok",
"version_string": null,
"wait_timeout": "0ms"
},
"router": "readwritesplit",
"router_diagnostics": {
"queries": 4,
"replayed_transactions": 0,
"ro_transactions": 1,
"route_all": 1,
"route_master": 3,
"route_slave": 0,
"rw_transactions": 0,
"server_query_statistics": [
{
"avg_selects_per_session": 0,
"avg_sess_duration": "0ns",
"id": "server1",
"read": 1,
"total": 4,
"write": 3
},
{
"avg_selects_per_session": 0,
"avg_sess_duration": "0ns",
"id": "server2",
"read": 1,
"total": 1,
"write": 0
}
],
"trx_max_size_exceeded": 0
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"started": "Fri, 05 Jan 2024 07:23:54 GMT",
"state": "Started",
"statistics": {
"active_operations": 0,
"avg_sescmd_history_length": 0.0,
"avg_session_lifetime": 0.0,
"connections": 1,
"failed_auths": 0,
"max_connections": 1,
"max_sescmd_history_length": 0,
"max_session_lifetime": 0,
"routed_packets": 4,
"total_connections": 1
},
"total_connections": 1,
"users": [
{
"default_role": "",
"global_priv": false,
"host": "localhost",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": false,
"user": "mariadb.sys"
},
{
"default_role": "",
"global_priv": true,
"host": "127.0.0.1",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "maxuser"
},
{
"default_role": "",
"global_priv": true,
"host": "%",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "maxuser"
},
{
"default_role": "",
"global_priv": true,
"host": "localhost",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "root"
},
{
"default_role": "",
"global_priv": true,
"host": "%",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "root"
}
],
"users_last_update": "Fri, 05 Jan 2024 07:23:55 GMT"
},
"id": "RW-Split-Router",
"links": {
"self": "http://localhost:8989/v1/services/RW-Split-Router/"
},
"relationships": {
"listeners": {
"data": [
{
"id": "RW-Split-Listener",
"type": "listeners"
}
],
"links": {
"related": "http://localhost:8989/v1/listeners/",
"self": "http://localhost:8989/v1/services/RW-Split-Router/relationships/listeners/"
}
},
"monitors": {
"data": [
{
"id": "MariaDB-Monitor",
"type": "monitors"
}
],
"links": {
"related": "http://localhost:8989/v1/monitors/",
"self": "http://localhost:8989/v1/services/RW-Split-Router/relationships/monitors/"
}
}
},
"type": "services"
},
{
"attributes": {
"connections": 0,
"listeners": [
{
"attributes": {
"parameters": {
"MariaDBProtocol": {
"allow_replication": true
},
"address": "::",
"authenticator": null,
"authenticator_options": null,
"connection_init_sql_file": null,
"connection_metadata": [
"character_set_client=auto",
"character_set_connection=auto",
"character_set_results=auto",
"max_allowed_packet=auto",
"system_time_zone=auto",
"time_zone=auto",
"tx_isolation=auto",
"maxscale=auto"
],
"port": 4008,
"protocol": "MariaDBProtocol",
"proxy_protocol_networks": null,
"service": "Read-Connection-Router",
"socket": null,
"sql_mode": "default",
"ssl": false,
"ssl_ca": null,
"ssl_cert": null,
"ssl_cert_verify_depth": 9,
"ssl_cipher": null,
"ssl_crl": null,
"ssl_key": null,
"ssl_verify_peer_certificate": false,
"ssl_verify_peer_host": false,
"ssl_version": "MAX",
"type": "listener",
"user_mapping_file": null
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Running"
},
"id": "Read-Connection-Listener",
"relationships": {
"services": {
"data": [
{
"id": "Read-Connection-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/listeners/Read-Connection-Listener/relationships/services/"
}
}
},
"type": "listeners"
}
],
"parameters": {
"auth_all_servers": false,
"connection_keepalive": "300000ms",
"disable_sescmd_history": false,
"enable_root_user": false,
"force_connection_keepalive": false,
"idle_session_pool_time": "-1ms",
"localhost_match_wildcard_host": true,
"log_auth_warnings": true,
"log_debug": false,
"log_info": false,
"log_notice": false,
"log_warning": false,
"master_accept_reads": true,
"max_connections": 0,
"max_replication_lag": "0ms",
"max_sescmd_history": 50,
"multiplex_timeout": "60000ms",
"net_write_timeout": "0ms",
"password": "*****",
"prune_sescmd_history": true,
"rank": "primary",
"retain_last_statements": -1,
"router": "readconnroute",
"router_options": "master",
"session_trace": false,
"strip_db_esc": true,
"type": "service",
"user": "maxuser",
"user_accounts_file": null,
"user_accounts_file_usage": "add_when_load_ok",
"version_string": null,
"wait_timeout": "0ms"
},
"router": "readconnroute",
"router_diagnostics": {
"queries": 0,
"server_query_statistics": []
},
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"started": "Fri, 05 Jan 2024 07:23:54 GMT",
"state": "Started",
"statistics": {
"active_operations": 0,
"avg_sescmd_history_length": 0.0,
"avg_session_lifetime": 0.0,
"connections": 0,
"failed_auths": 0,
"max_connections": 0,
"max_sescmd_history_length": 0,
"max_session_lifetime": 0,
"routed_packets": 0,
"total_connections": 0
},
"total_connections": 0,
"users": [
{
"default_role": "",
"global_priv": false,
"host": "localhost",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": false,
"user": "mariadb.sys"
},
{
"default_role": "",
"global_priv": true,
"host": "127.0.0.1",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "maxuser"
},
{
"default_role": "",
"global_priv": true,
"host": "%",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "maxuser"
},
{
"default_role": "",
"global_priv": true,
"host": "localhost",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "root"
},
{
"default_role": "",
"global_priv": true,
"host": "%",
"plugin": "mysql_native_password",
"proxy_priv": false,
"ssl": false,
"super_priv": true,
"user": "root"
}
],
"users_last_update": "Fri, 05 Jan 2024 07:23:55 GMT"
},
"id": "Read-Connection-Router",
"links": {
"self": "http://localhost:8989/v1/services/Read-Connection-Router/"
},
"relationships": {
"filters": {
"data": [
{
"id": "QLA",
"type": "filters"
},
{
"id": "Hint",
"type": "filters"
}
],
"links": {
"related": "http://localhost:8989/v1/filters/",
"self": "http://localhost:8989/v1/services/Read-Connection-Router/relationships/filters/"
}
},
"listeners": {
"data": [
{
"id": "Read-Connection-Listener",
"type": "listeners"
}
],
"links": {
"related": "http://localhost:8989/v1/listeners/",
"self": "http://localhost:8989/v1/services/Read-Connection-Router/relationships/listeners/"
}
},
"servers": {
"data": [
{
"id": "server1",
"type": "servers"
},
{
"id": "server2",
"type": "servers"
}
],
"links": {
"related": "http://localhost:8989/v1/servers/",
"self": "http://localhost:8989/v1/services/Read-Connection-Router/relationships/servers/"
}
}
},
"type": "services"
}
],
"links": {
"self": "http://localhost:8989/v1/services/"
}
}POST /v1/services{
"data": {
"id": "my-service",
"type": "services",
"attributes": {
"router": "readwritesplit",
"parameters": {
"user": "maxuser",
"password": "maxpwd"
}
},
"relationships": {
"filters": {
"data": [
{
"id": "QLA",
"type": "filters"
}
]
},
"servers": {
"data": [
{
"id": "server1",
"type": "servers"
}
]
}
}
}
}DELETE /v1/services/:namePATCH /v1/services/:name{
"data": {
"attributes": {
"parameters": {
"user": "admin"
}
}
}
}PATCH /v1/services/:name/relationships/:typePATCH /v1/services/my-rw-service/relationships/servers
{
data: [
{ "id": "my-server", "type": "servers" }
]
}PATCH /v1/services/my-rw-service/relationships/servers
{
data: []
}PUT /v1/services/:name/stopPUT /v1/services/:name/startPOST /v1/services/:name/reloadGET /v1/services/:name/listenersGET /v1/services/:name/listeners/:listenerPOST /v1/services/:name/listenersDELETE /v1/services/:service/listeners/:nameGET /v1/servers/:name{
"data": {
"attributes": {
"gtid_binlog_pos": "0-3000-8",
"gtid_current_pos": "0-3000-8",
"last_event": "master_up",
"lock_held": null,
"master_group": null,
"master_id": -1,
"name": "server1",
"node_id": 3000,
"parameters": {
"address": "127.0.0.1",
"disk_space_threshold": null,
"extra_port": 0,
"max_routing_connections": 0,
"monitorpw": null,
"monitoruser": null,
"persistmaxtime": "0ms",
"persistpoolmax": 0,
"port": 3000,
"priority": 0,
"private_address": null,
"proxy_protocol": false,
"rank": "primary",
"replication_custom_options": null,
"socket": null,
"ssl": false,
"ssl_ca": null,
"ssl_cert": null,
"ssl_cert_verify_depth": 9,
"ssl_cipher": null,
"ssl_key": null,
"ssl_verify_peer_certificate": false,
"ssl_verify_peer_host": false,
"ssl_version": "MAX"
},
"read_only": false,
"replication_lag": 0,
"server_id": 3000,
"slave_connections": [],
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Master, Running",
"state_details": null,
"statistics": {
"active_operations": 0,
"adaptive_avg_select_time": "0ns",
"connection_pool_empty": 0,
"connections": 1,
"failed_auths": 0,
"max_connections": 1,
"max_pool_size": 0,
"persistent_connections": 0,
"response_time_distribution": {
"read": {
"distribution": [
{
"count": 0,
"time": "0.000001",
"total": 0.0
},
{
"count": 0,
"time": "0.000010",
"total": 0.0
},
{
"count": 0,
"time": "0.000100",
"total": 0.0
},
{
"count": 0,
"time": "0.001000",
"total": 0.0
},
{
"count": 0,
"time": "0.010000",
"total": 0.0
},
{
"count": 0,
"time": "0.100000",
"total": 0.0
},
{
"count": 0,
"time": "1.000000",
"total": 0.0
},
{
"count": 0,
"time": "10.000000",
"total": 0.0
},
{
"count": 0,
"time": "100.000000",
"total": 0.0
},
{
"count": 0,
"time": "1000.000000",
"total": 0.0
},
{
"count": 0,
"time": "10000.000000",
"total": 0.0
},
{
"count": 0,
"time": "100000.000000",
"total": 0.0
}
],
"operation": "read",
"range_base": 10
},
"write": {
"distribution": [
{
"count": 0,
"time": "0.000001",
"total": 0.0
},
{
"count": 0,
"time": "0.000010",
"total": 0.0
},
{
"count": 1,
"time": "0.000100",
"total": 9.0147000000000003e-5
},
{
"count": 3,
"time": "0.001000",
"total": 0.00131908
},
{
"count": 0,
"time": "0.010000",
"total": 0.0
},
{
"count": 0,
"time": "0.100000",
"total": 0.0
},
{
"count": 0,
"time": "1.000000",
"total": 0.0
},
{
"count": 0,
"time": "10.000000",
"total": 0.0
},
{
"count": 0,
"time": "100.000000",
"total": 0.0
},
{
"count": 0,
"time": "1000.000000",
"total": 0.0
},
{
"count": 0,
"time": "10000.000000",
"total": 0.0
},
{
"count": 0,
"time": "100000.000000",
"total": 0.0
}
],
"operation": "write",
"range_base": 10
}
},
"reused_connections": 0,
"routed_packets": 4,
"total_connections": 1
},
"triggered_at": "Fri, 05 Jan 2024 07:23:54 GMT",
"uptime": 2372,
"version_string": "10.6.15-MariaDB-1:10.6.15+maria~ubu2004-log"
},
"id": "server1",
"links": {
"self": "http://localhost:8989/v1/servers/server1/"
},
"relationships": {
"monitors": {
"data": [
{
"id": "MariaDB-Monitor",
"type": "monitors"
}
],
"links": {
"related": "http://localhost:8989/v1/monitors/",
"self": "http://localhost:8989/v1/servers/server1/relationships/monitors/"
}
},
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
},
{
"id": "Read-Connection-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/servers/server1/relationships/services/"
}
}
},
"type": "servers"
},
"links": {
"self": "http://localhost:8989/v1/servers/server1/"
}
}GET /v1/servers{
"data": [
{
"attributes": {
"gtid_binlog_pos": "0-3000-8",
"gtid_current_pos": "0-3000-8",
"last_event": "master_up",
"lock_held": null,
"master_group": null,
"master_id": -1,
"name": "server1",
"node_id": 3000,
"parameters": {
"address": "127.0.0.1",
"disk_space_threshold": null,
"extra_port": 0,
"max_routing_connections": 0,
"monitorpw": null,
"monitoruser": null,
"persistmaxtime": "0ms",
"persistpoolmax": 0,
"port": 3000,
"priority": 0,
"private_address": null,
"proxy_protocol": false,
"rank": "primary",
"replication_custom_options": null,
"socket": null,
"ssl": false,
"ssl_ca": null,
"ssl_cert": null,
"ssl_cert_verify_depth": 9,
"ssl_cipher": null,
"ssl_key": null,
"ssl_verify_peer_certificate": false,
"ssl_verify_peer_host": false,
"ssl_version": "MAX"
},
"read_only": false,
"replication_lag": 0,
"server_id": 3000,
"slave_connections": [],
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Master, Running",
"state_details": null,
"statistics": {
"active_operations": 0,
"adaptive_avg_select_time": "0ns",
"connection_pool_empty": 0,
"connections": 1,
"failed_auths": 0,
"max_connections": 1,
"max_pool_size": 0,
"persistent_connections": 0,
"response_time_distribution": {
"read": {
"distribution": [
{
"count": 0,
"time": "0.000001",
"total": 0.0
},
{
"count": 0,
"time": "0.000010",
"total": 0.0
},
{
"count": 0,
"time": "0.000100",
"total": 0.0
},
{
"count": 0,
"time": "0.001000",
"total": 0.0
},
{
"count": 0,
"time": "0.010000",
"total": 0.0
},
{
"count": 0,
"time": "0.100000",
"total": 0.0
},
{
"count": 0,
"time": "1.000000",
"total": 0.0
},
{
"count": 0,
"time": "10.000000",
"total": 0.0
},
{
"count": 0,
"time": "100.000000",
"total": 0.0
},
{
"count": 0,
"time": "1000.000000",
"total": 0.0
},
{
"count": 0,
"time": "10000.000000",
"total": 0.0
},
{
"count": 0,
"time": "100000.000000",
"total": 0.0
}
],
"operation": "read",
"range_base": 10
},
"write": {
"distribution": [
{
"count": 0,
"time": "0.000001",
"total": 0.0
},
{
"count": 0,
"time": "0.000010",
"total": 0.0
},
{
"count": 1,
"time": "0.000100",
"total": 9.0147000000000003e-5
},
{
"count": 3,
"time": "0.001000",
"total": 0.00131908
},
{
"count": 0,
"time": "0.010000",
"total": 0.0
},
{
"count": 0,
"time": "0.100000",
"total": 0.0
},
{
"count": 0,
"time": "1.000000",
"total": 0.0
},
{
"count": 0,
"time": "10.000000",
"total": 0.0
},
{
"count": 0,
"time": "100.000000",
"total": 0.0
},
{
"count": 0,
"time": "1000.000000",
"total": 0.0
},
{
"count": 0,
"time": "10000.000000",
"total": 0.0
},
{
"count": 0,
"time": "100000.000000",
"total": 0.0
}
],
"operation": "write",
"range_base": 10
}
},
"reused_connections": 0,
"routed_packets": 4,
"total_connections": 1
},
"triggered_at": "Fri, 05 Jan 2024 07:23:54 GMT",
"uptime": 2372,
"version_string": "10.6.15-MariaDB-1:10.6.15+maria~ubu2004-log"
},
"id": "server1",
"links": {
"self": "http://localhost:8989/v1/servers/server1/"
},
"relationships": {
"monitors": {
"data": [
{
"id": "MariaDB-Monitor",
"type": "monitors"
}
],
"links": {
"related": "http://localhost:8989/v1/monitors/",
"self": "http://localhost:8989/v1/servers/server1/relationships/monitors/"
}
},
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
},
{
"id": "Read-Connection-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/servers/server1/relationships/services/"
}
}
},
"type": "servers"
},
{
"attributes": {
"gtid_binlog_pos": "0-3001-12",
"gtid_current_pos": "0-3001-12",
"last_event": "lost_slave",
"lock_held": null,
"master_group": null,
"master_id": 3000,
"name": "server2",
"node_id": 3001,
"parameters": {
"address": "127.0.0.1",
"disk_space_threshold": null,
"extra_port": 0,
"max_routing_connections": 0,
"monitorpw": null,
"monitoruser": null,
"persistmaxtime": "0ms",
"persistpoolmax": 0,
"port": 3001,
"priority": 0,
"private_address": null,
"proxy_protocol": false,
"rank": "primary",
"replication_custom_options": null,
"socket": null,
"ssl": false,
"ssl_ca": null,
"ssl_cert": null,
"ssl_cert_verify_depth": 9,
"ssl_cipher": null,
"ssl_key": null,
"ssl_verify_peer_certificate": false,
"ssl_verify_peer_host": false,
"ssl_version": "MAX"
},
"read_only": false,
"replication_lag": -1,
"server_id": 3001,
"slave_connections": [
{
"connection_name": "",
"gtid_io_pos": "",
"last_io_error": "",
"last_sql_error": "",
"master_host": "127.0.0.1",
"master_port": 3000,
"master_server_id": 3000,
"seconds_behind_master": null,
"slave_io_running": "No",
"slave_sql_running": "No",
"using_gtid": "No"
}
],
"source": {
"file": "/etc/maxscale.cnf",
"type": "static"
},
"state": "Running",
"state_details": null,
"statistics": {
"active_operations": 0,
"adaptive_avg_select_time": "0ns",
"connection_pool_empty": 0,
"connections": 0,
"failed_auths": 0,
"max_connections": 1,
"max_pool_size": 0,
"persistent_connections": 0,
"response_time_distribution": {
"read": {
"distribution": [
{
"count": 0,
"time": "0.000001",
"total": 0.0
},
{
"count": 0,
"time": "0.000010",
"total": 0.0
},
{
"count": 0,
"time": "0.000100",
"total": 0.0
},
{
"count": 1,
"time": "0.001000",
"total": 0.00037632399999999998
},
{
"count": 0,
"time": "0.010000",
"total": 0.0
},
{
"count": 0,
"time": "0.100000",
"total": 0.0
},
{
"count": 0,
"time": "1.000000",
"total": 0.0
},
{
"count": 0,
"time": "10.000000",
"total": 0.0
},
{
"count": 0,
"time": "100.000000",
"total": 0.0
},
{
"count": 0,
"time": "1000.000000",
"total": 0.0
},
{
"count": 0,
"time": "10000.000000",
"total": 0.0
},
{
"count": 0,
"time": "100000.000000",
"total": 0.0
}
],
"operation": "read",
"range_base": 10
},
"write": {
"distribution": [
{
"count": 0,
"time": "0.000001",
"total": 0.0
},
{
"count": 0,
"time": "0.000010",
"total": 0.0
},
{
"count": 0,
"time": "0.000100",
"total": 0.0
},
{
"count": 0,
"time": "0.001000",
"total": 0.0
},
{
"count": 0,
"time": "0.010000",
"total": 0.0
},
{
"count": 0,
"time": "0.100000",
"total": 0.0
},
{
"count": 0,
"time": "1.000000",
"total": 0.0
},
{
"count": 0,
"time": "10.000000",
"total": 0.0
},
{
"count": 0,
"time": "100.000000",
"total": 0.0
},
{
"count": 0,
"time": "1000.000000",
"total": 0.0
},
{
"count": 0,
"time": "10000.000000",
"total": 0.0
},
{
"count": 0,
"time": "100000.000000",
"total": 0.0
}
],
"operation": "write",
"range_base": 10
}
},
"reused_connections": 0,
"routed_packets": 1,
"total_connections": 1
},
"triggered_at": "Fri, 05 Jan 2024 07:24:07 GMT",
"uptime": 2372,
"version_string": "10.6.15-MariaDB-1:10.6.15+maria~ubu2004-log"
},
"id": "server2",
"links": {
"self": "http://localhost:8989/v1/servers/server2/"
},
"relationships": {
"monitors": {
"data": [
{
"id": "MariaDB-Monitor",
"type": "monitors"
}
],
"links": {
"related": "http://localhost:8989/v1/monitors/",
"self": "http://localhost:8989/v1/servers/server2/relationships/monitors/"
}
},
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
},
{
"id": "Read-Connection-Router",
"type": "services"
}
],
"links": {
"related": "http://localhost:8989/v1/services/",
"self": "http://localhost:8989/v1/servers/server2/relationships/services/"
}
}
},
"type": "servers"
}
],
"links": {
"self": "http://localhost:8989/v1/servers/"
}
}POST /v1/servers{
"data": {
"id": "server3",
"type": "servers",
"attributes": {
"parameters": {
"address": "127.0.0.1",
"port": 3003
}
}
}
}{
"data": {
"id": "server4",
"type": "servers",
"attributes": {
"parameters": {
"address": "127.0.0.1",
"port": 3002
}
},
"relationships": {
"services": {
"data": [
{
"id": "RW-Split-Router",
"type": "services"
},
{
"id": "Read-Connection-Router",
"type": "services"
}
]
},
"monitors": {
"data": [
{
"id": "MySQL-Monitor",
"type": "monitors"
}
]
}
}
}
}PATCH /v1/servers/:name{
"data": {
"attributes": {
"parameters": {
"address": "192.168.0.123"
}
}
}
}{
"data": {
"relationships": {
"services": {
"data": [
{ "id": "Read-Connection-Router", "type": "services" }
]
},
"monitors": {
"data": [
{ "id": "MySQL-Monitor", "type": "monitors" }
]
}
}
}
}PATCH /v1/servers/:name/relationships/:typePATCH /v1/servers/my-db-server/relationships/services
{
data: [
{ "id": "my-rwsplit-service", "type": "services" }
]
}PATCH /v1/servers/my-db-server/relationships/services
{
data: []
}DELETE /v1/servers/:namePUT /v1/servers/:name/setPUT /v1/servers/db-server-1/set?state=maintenancePUT /v1/servers/db-server-1/set?state=maintenance&force=yesPUT /v1/servers/:name/clearlinks object should be used instead. This way the navigation will provide
a consistent view of the log that does not overlap.
Optionally, the id values in the returned data can be used as the values
for this parameter to read data from a known point in the file.priorityGET /v1/maxscale{
"data": {
"attributes": {
"activated_at": "Fri, 05 Jan 2024 07:23:54 GMT",
"commit": "af392f1a43e72e5538e1956aa500d77aca4d4456",
"config_sync": null,
"parameters": {
"admin_audit": false,
"admin_audit_exclude_methods": [],
"admin_audit_file": "/var/log/maxscale/admin_audit.csv",
"admin_auth": true,
"admin_enabled": true,
"admin_gui": true,
"admin_host": "127.0.0.1",
"admin_jwt_algorithm": "auto",
"admin_jwt_issuer": "maxscale",
"admin_jwt_key": null,
"admin_jwt_max_age": "86400000ms",
"admin_log_auth_failures": true,
"admin_oidc_url": null,
"admin_pam_readonly_service": null,
"admin_pam_readwrite_service": null,
"admin_port": 8989,
"admin_readonly_hosts": "*",
"admin_readwrite_hosts": "*",
"admin_secure_gui": false,
"admin_ssl_ca": null,
"admin_ssl_cert": null,
"admin_ssl_key": null,
"admin_ssl_version": "MAX",
"admin_verify_url": null,
"auth_connect_timeout": "10000ms",
"auth_read_timeout": "10000ms",
"auth_write_timeout": "10000ms",
"auto_tune": [],
"cachedir": "/var/cache/maxscale",
"config_sync_cluster": null,
"config_sync_db": "mysql",
"config_sync_interval": "5000ms",
"config_sync_password": null,
"config_sync_timeout": "10000ms",
"config_sync_user": null,
"connector_plugindir": "/usr/lib64/maxscale/plugin",
"datadir": "/var/lib/maxscale",
"debug": null,
"dump_last_statements": "never",
"execdir": "/usr/bin",
"key_manager": "none",
"language": "/var/lib/maxscale",
"libdir": "/usr/lib64/maxscale",
"load_persisted_configs": true,
"local_address": null,
"log_debug": false,
"log_info": false,
"log_notice": true,
"log_throttling": {
"count": 10,
"suppress": 10000,
"window": 1000
},
"log_warn_super_user": false,
"log_warning": true,
"logdir": "/var/log/maxscale",
"max_auth_errors_until_block": 10,
"max_read_amount": 0,
"maxlog": true,
"module_configdir": "/etc/maxscale.modules.d",
"ms_timestamp": false,
"passive": false,
"persist_runtime_changes": true,
"persistdir": "/var/lib/maxscale/maxscale.cnf.d",
"piddir": "/var/run/maxscale",
"query_classifier_cache_size": 5003753472,
"query_retries": 1,
"query_retry_timeout": "5000ms",
"rebalance_period": "0ms",
"rebalance_threshold": 20,
"rebalance_window": 10,
"retain_last_statements": 0,
"session_trace": 0,
"session_trace_match": null,
"skip_name_resolve": false,
"sql_mode": "default",
"syslog": false,
"threads": 3,
"threads_max": 256,
"users_refresh_interval": "0ms",
"users_refresh_time": "0ms",
"writeq_high_water": 65536,
"writeq_low_water": 1024
},
"process_datadir": "/var/lib/maxscale/data1",
"started_at": "Fri, 05 Jan 2024 07:23:54 GMT",
"system": {
"machine": {
"cores_available": 8,
"cores_physical": 8,
"cores_virtual": 8.0,
"memory_available": 33358356480,
"memory_physical": 33358356480
},
"maxscale": {
"query_classifier_cache_size": 5003753472,
"threads": 3
},
"os": {
"machine": "x86_64",
"nodename": "monolith",
"release": "6.6.4-100.fc38.x86_64",
"sysname": "Linux",
"version": "#1 SMP PREEMPT_DYNAMIC Sun Dec 3 18:11:27 UTC 2023"
}
},
"uptime": 12,
"version": "24.02.0"
},
"id": "maxscale",
"type": "maxscale"
},
"links": {
"self": "http://localhost:8989/v1/maxscale/"
}
}PATCH /v1/maxscaleGET /v1/maxscale/threads/:id{
"data": {
"attributes": {
"stats": {
"accepts": 0,
"avg_event_queue_length": 1,
"current_descriptors": 5,
"errors": 0,
"hangups": 0,
"listening": true,
"load": {
"last_hour": 0,
"last_minute": 0,
"last_second": 0
},
"max_event_queue_length": 1,
"max_exec_time": 0,
"max_queue_time": 0,
"memory": {
"query_classifier": 0,
"sessions": 0,
"total": 0,
"zombies": 0
},
"query_classifier_cache": {
"evictions": 0,
"hits": 0,
"inserts": 0,
"misses": 0,
"size": 0
},
"reads": 20,
"sessions": 0,
"state": "Active",
"total_descriptors": 5,
"writes": 0,
"zombies": 0
}
},
"id": "0",
"links": {
"self": "http://localhost:8989/v1/threads/0/"
},
"type": "threads"
},
"links": {
"self": "http://localhost:8989/v1/maxscale/threads/0/"
}
}GET /v1/maxscale/threads{
"data": [
{
"attributes": {
"stats": {
"accepts": 0,
"avg_event_queue_length": 1,
"current_descriptors": 5,
"errors": 0,
"hangups": 0,
"listening": true,
"load": {
"last_hour": 0,
"last_minute": 0,
"last_second": 0
},
"max_event_queue_length": 1,
"max_exec_time": 0,
"max_queue_time": 0,
"memory": {
"query_classifier": 0,
"sessions": 0,
"total": 0,
"zombies": 0
},
"query_classifier_cache": {
"evictions": 0,
"hits": 0,
"inserts": 0,
"misses": 0,
"size": 0
},
"reads": 21,
"sessions": 0,
"state": "Active",
"total_descriptors": 5,
"writes": 0,
"zombies": 0
}
},
"id": "0",
"links": {
"self": "http://localhost:8989/v1/threads/0/"
},
"type": "threads"
},
{
"attributes": {
"stats": {
"accepts": 1,
"avg_event_queue_length": 1,
"current_descriptors": 8,
"errors": 0,
"hangups": 0,
"listening": true,
"load": {
"last_hour": 0,
"last_minute": 0,
"last_second": 0
},
"max_event_queue_length": 2,
"max_exec_time": 1,
"max_queue_time": 0,
"memory": {
"query_classifier": 1481,
"sessions": 70221,
"total": 71702,
"zombies": 0
},
"query_classifier_cache": {
"evictions": 0,
"hits": 0,
"inserts": 3,
"misses": 4,
"size": 1481
},
"reads": 35,
"sessions": 1,
"state": "Active",
"total_descriptors": 8,
"writes": 15,
"zombies": 0
}
},
"id": "1",
"links": {
"self": "http://localhost:8989/v1/threads/1/"
},
"type": "threads"
},
{
"attributes": {
"stats": {
"accepts": 0,
"avg_event_queue_length": 1,
"current_descriptors": 5,
"errors": 0,
"hangups": 0,
"listening": true,
"load": {
"last_hour": 0,
"last_minute": 0,
"last_second": 0
},
"max_event_queue_length": 1,
"max_exec_time": 0,
"max_queue_time": 0,
"memory": {
"query_classifier": 0,
"sessions": 0,
"total": 0,
"zombies": 0
},
"query_classifier_cache": {
"evictions": 0,
"hits": 0,
"inserts": 0,
"misses": 0,
"size": 0
},
"reads": 20,
"sessions": 0,
"state": "Active",
"total_descriptors": 5,
"writes": 0,
"zombies": 0
}
},
"id": "2",
"links": {
"self": "http://localhost:8989/v1/threads/2/"
},
"type": "threads"
}
],
"links": {
"self": "http://localhost:8989/v1/maxscale/threads/"
}
}GET /v1/maxscale/logs{
"data": {
"attributes": {
"log_file": "/var/log/maxscale/maxscale.log",
"log_priorities": [
"alert",
"error",
"warning",
"notice"
],
"parameters": {
"log_debug": false,
"log_info": false,
"log_notice": true,
"log_throttling": {
"count": 10,
"suppress": 10000,
"window": 1000
},
"log_warning": true,
"maxlog": true,
"ms_timestamp": false,
"syslog": false
}
},
"id": "logs",
"type": "logs"
},
"links": {
"self": "http://localhost:8989/v1/maxscale/logs/"
}
}GET /v1/maxscale/logs/data{
"data": {
"attributes": {
"log": [
{
"id": "37",
"message": "MaxScale started with 3 worker threads.",
"priority": "notice",
"timestamp": "2024-01-05 07:23:54",
"unix_timestamp": 1704439434
},
{
"id": "38",
"message": "Read 8 user@host entries from 'server1' for service 'RW-Split-Router'.",
"priority": "notice",
"timestamp": "2024-01-05 07:23:55",
"unix_timestamp": 1704439435
},
{
"id": "39",
"message": "Read 8 user@host entries from 'server1' for service 'Read-Connection-Router'.",
"priority": "notice",
"timestamp": "2024-01-05 07:23:55",
"unix_timestamp": 1704439435
}
],
"log_source": "maxlog"
},
"id": "log_data",
"type": "log_data"
},
"links": {
"last": "http://localhost:8989/v1/maxscale/logs/data/?page%5Bsize%5D=3",
"prev": "http://localhost:8989/v1/maxscale/logs/data/?page%5Bcursor%5D=34&page%5Bsize%5D=3",
"self": "http://localhost:8989/v1/maxscale/logs/data/?page%5Bcursor%5D=40&page%5Bsize%5D=3"
}
}GET /v1/maxscale/logs/entries{
"data": [
{
"attributes": {
"log_source": "maxlog",
"message": "MaxScale started with 3 worker threads.",
"priority": "notice",
"timestamp": "2024-01-05 07:23:54",
"unix_timestamp": 1704439434
},
"id": "37",
"type": "log_entry"
},
{
"attributes": {
"log_source": "maxlog",
"message": "Read 8 user@host entries from 'server1' for service 'RW-Split-Router'.",
"priority": "notice",
"timestamp": "2024-01-05 07:23:55",
"unix_timestamp": 1704439435
},
"id": "38",
"type": "log_entry"
},
{
"attributes": {
"log_source": "maxlog",
"message": "Read 8 user@host entries from 'server1' for service 'Read-Connection-Router'.",
"priority": "notice",
"timestamp": "2024-01-05 07:23:55",
"unix_timestamp": 1704439435
},
"id": "39",
"type": "log_entry"
}
],
"links": {
"last": "http://localhost:8989/v1/maxscale/logs/entries/?page%5Bsize%5D=3",
"prev": "http://localhost:8989/v1/maxscale/logs/entries/?page%5Bcursor%5D=34&page%5Bsize%5D=3",
"self": "http://localhost:8989/v1/maxscale/logs/entries/?page%5Bcursor%5D=40&page%5Bsize%5D=3"
},
"meta": {
"total": 3
}
}GET /v1/maxscale/logs/stream{
"id": "572",
"message": "MaxScale started with 8 worker threads, each with a stack size of 8388608 bytes.",
"priority": "notice",
"timestamp": "2020-09-25 10:01:29"
}PATCH /v1/maxscale/logsPOST /v1/maxscale/logs/flushPOST /v1/maxscale/tls/reloadGET /v1/maxscale/modules/:name{
"data": {
"attributes": {
"api": "router",
"commands": [
{
"attributes": {
"arg_max": 1,
"arg_min": 1,
"description": "Reset global GTID state in readwritesplit.",
"method": "POST",
"parameters": [
{
"description": "Readwritesplit service",
"required": true,
"type": "SERVICE"
}
]
},
"id": "reset-gtid",
"links": {
"self": "http://localhost:8989/v1/modules/readwritesplit/reset-gtid/"
},
"type": "module_command"
}
],
"description": "A Read/Write splitting router for enhancement read scalability",
"maturity": "GA",
"module_type": "Router",
"parameters": [
{
"default_value": "none",
"description": "Causal reads mode",
"enum_values": [
"none",
"local",
"global",
"fast_global",
"fast",
"universal",
"fast_universal",
"false",
"off",
"0",
"true",
"on",
"1"
],
"mandatory": false,
"modifiable": true,
"name": "causal_reads",
"type": "enum"
},
{
"default_value": "10000ms",
"description": "Timeout for the slave synchronization",
"mandatory": false,
"modifiable": true,
"name": "causal_reads_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": false,
"description": "Retry failed writes outside of transactions",
"mandatory": false,
"modifiable": true,
"name": "delayed_retry",
"type": "bool"
},
{
"default_value": "10000ms",
"description": "Timeout for delayed_retry",
"mandatory": false,
"modifiable": true,
"name": "delayed_retry_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": false,
"description": "Create connections only when needed",
"mandatory": false,
"modifiable": true,
"name": "lazy_connect",
"type": "bool"
},
{
"default_value": false,
"description": "Use master for reads",
"mandatory": false,
"modifiable": true,
"name": "master_accept_reads",
"type": "bool"
},
{
"default_value": "fail_on_write",
"description": "Master failure mode behavior",
"enum_values": [
"fail_instantly",
"fail_on_write",
"error_on_write"
],
"mandatory": false,
"modifiable": true,
"name": "master_failure_mode",
"type": "enum"
},
{
"default_value": true,
"description": "Reconnect to master",
"mandatory": false,
"modifiable": true,
"name": "master_reconnection",
"type": "bool"
},
{
"default_value": "0ms",
"description": "Maximum replication lag",
"mandatory": false,
"modifiable": true,
"name": "max_replication_lag",
"type": "duration",
"unit": "ms"
},
{
"default_value": 255,
"description": "Maximum number of slave connections",
"mandatory": false,
"modifiable": true,
"name": "max_slave_connections",
"type": "count"
},
{
"deprecated": true,
"description": "Alias for 'max_replication_lag'",
"mandatory": false,
"modifiable": true,
"name": "max_slave_replication_lag",
"type": "duration"
},
{
"default_value": false,
"description": "Optimistically offload transactions to slaves",
"mandatory": false,
"modifiable": true,
"name": "optimistic_trx",
"type": "bool"
},
{
"default_value": true,
"description": "Automatically retry failed reads outside of transactions",
"mandatory": false,
"modifiable": true,
"name": "retry_failed_reads",
"type": "bool"
},
{
"default_value": false,
"description": "Reuse identical prepared statements inside the same connection",
"mandatory": false,
"modifiable": true,
"name": "reuse_prepared_statements",
"type": "bool"
},
{
"default_value": 255,
"description": "Starting number of slave connections",
"mandatory": false,
"modifiable": true,
"name": "slave_connections",
"type": "count"
},
{
"default_value": "least_current_operations",
"description": "Slave selection criteria",
"enum_values": [
"least_global_connections",
"least_router_connections",
"least_behind_master",
"least_current_operations",
"adaptive_routing",
"LEAST_GLOBAL_CONNECTIONS",
"LEAST_ROUTER_CONNECTIONS",
"LEAST_BEHIND_MASTER",
"LEAST_CURRENT_OPERATIONS",
"ADAPTIVE_ROUTING"
],
"mandatory": false,
"modifiable": true,
"name": "slave_selection_criteria",
"type": "enum"
},
{
"default_value": false,
"description": "Lock connection to master after multi-statement query",
"mandatory": false,
"modifiable": true,
"name": "strict_multi_stmt",
"type": "bool"
},
{
"default_value": false,
"description": "Lock connection to master after a stored procedure is executed",
"mandatory": false,
"modifiable": true,
"name": "strict_sp_calls",
"type": "bool"
},
{
"default_value": true,
"description": "Prevent reconnections if temporary tables exist",
"mandatory": false,
"modifiable": true,
"name": "strict_tmp_tables",
"type": "bool"
},
{
"default_value": false,
"description": "Retry failed transactions",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay",
"type": "bool"
},
{
"default_value": 5,
"description": "Maximum number of times to retry a transaction",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_attempts",
"type": "count"
},
{
"default_value": "full",
"description": "Type of checksum to calculate for results",
"enum_values": [
"full",
"result_only",
"no_insert_id"
],
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_checksum",
"type": "enum"
},
{
"default_value": 1048576,
"description": "Maximum size of transaction to retry",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_max_size",
"type": "size"
},
{
"default_value": false,
"description": "Retry transaction on deadlock",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_retry_on_deadlock",
"type": "bool"
},
{
"default_value": false,
"description": "Retry transaction on checksum mismatch",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_retry_on_mismatch",
"type": "bool"
},
{
"default_value": true,
"description": "Prevent replaying of about-to-commit transaction",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_safe_commit",
"type": "bool"
},
{
"default_value": "30000ms",
"description": "Timeout for transaction replay",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "all",
"description": "Whether to route SQL variable modifications to all servers or only to the master",
"enum_values": [
"all",
"master"
],
"mandatory": false,
"modifiable": true,
"name": "use_sql_variables_in",
"type": "enum"
},
{
"default_value": false,
"deprecated": true,
"description": "Retrieve users from all backend servers instead of only one",
"mandatory": false,
"modifiable": true,
"name": "auth_all_servers",
"type": "bool"
},
{
"default_value": "300000ms",
"description": "How often idle connections are pinged",
"mandatory": false,
"modifiable": true,
"name": "connection_keepalive",
"type": "duration",
"unit": "ms"
},
{
"deprecated": true,
"description": "Alias for 'wait_timeout'",
"mandatory": false,
"modifiable": true,
"name": "connection_timeout",
"type": "duration"
},
{
"default_value": false,
"description": "Disable session command history",
"mandatory": false,
"modifiable": true,
"name": "disable_sescmd_history",
"type": "bool"
},
{
"default_value": false,
"description": "Allow the root user to connect to this service",
"mandatory": false,
"modifiable": true,
"name": "enable_root_user",
"type": "bool"
},
{
"default_value": false,
"description": "Ping connections unconditionally",
"mandatory": false,
"modifiable": true,
"name": "force_connection_keepalive",
"type": "bool"
},
{
"default_value": "-1ms",
"description": "Put connections into pool after session has been idle for this long",
"mandatory": false,
"modifiable": true,
"name": "idle_session_pool_time",
"type": "duration",
"unit": "ms"
},
{
"default_value": true,
"description": "Match localhost to wildcard host",
"mandatory": false,
"modifiable": true,
"name": "localhost_match_wildcard_host",
"type": "bool"
},
{
"default_value": true,
"description": "Log a warning when client authentication fails",
"mandatory": false,
"modifiable": true,
"name": "log_auth_warnings",
"type": "bool"
},
{
"default_value": false,
"description": "Log debug messages for this service (debug builds only)",
"mandatory": false,
"modifiable": true,
"name": "log_debug",
"type": "bool"
},
{
"default_value": false,
"description": "Log info messages for this service",
"mandatory": false,
"modifiable": true,
"name": "log_info",
"type": "bool"
},
{
"default_value": false,
"description": "Log notice messages for this service",
"mandatory": false,
"modifiable": true,
"name": "log_notice",
"type": "bool"
},
{
"default_value": false,
"description": "Log warning messages for this service",
"mandatory": false,
"modifiable": true,
"name": "log_warning",
"type": "bool"
},
{
"default_value": 0,
"description": "Maximum number of connections",
"mandatory": false,
"modifiable": true,
"name": "max_connections",
"type": "count"
},
{
"default_value": 50,
"description": "Session command history size",
"mandatory": false,
"modifiable": true,
"name": "max_sescmd_history",
"type": "count"
},
{
"default_value": "60000ms",
"description": "How long a session can wait for a connection to become available",
"mandatory": false,
"modifiable": true,
"name": "multiplex_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "0ms",
"description": "Network write timeout",
"mandatory": false,
"modifiable": true,
"name": "net_write_timeout",
"type": "duration",
"unit": "ms"
},
{
"description": "Password for the user used to retrieve database users",
"mandatory": true,
"modifiable": true,
"name": "password",
"type": "password"
},
{
"default_value": true,
"description": "Prune old session command history if the limit is exceeded",
"mandatory": false,
"modifiable": true,
"name": "prune_sescmd_history",
"type": "bool"
},
{
"default_value": "primary",
"description": "Service rank",
"enum_values": [
"primary",
"secondary"
],
"mandatory": false,
"modifiable": true,
"name": "rank",
"type": "enum"
},
{
"default_value": -1,
"description": "Number of statements kept in memory",
"mandatory": false,
"modifiable": true,
"name": "retain_last_statements",
"type": "int"
},
{
"default_value": false,
"description": "Enable session tracing for this service",
"mandatory": false,
"modifiable": true,
"name": "session_trace",
"type": "bool"
},
{
"default_value": false,
"deprecated": true,
"description": "Track session state using server responses",
"mandatory": false,
"modifiable": true,
"name": "session_track_trx_state",
"type": "bool"
},
{
"default_value": true,
"deprecated": true,
"description": "Strip escape characters from database names",
"mandatory": false,
"modifiable": true,
"name": "strip_db_esc",
"type": "bool"
},
{
"description": "Username used to retrieve database users",
"mandatory": true,
"modifiable": true,
"name": "user",
"type": "string"
},
{
"description": "Load additional users from a file",
"mandatory": false,
"modifiable": false,
"name": "user_accounts_file",
"type": "path"
},
{
"default_value": "add_when_load_ok",
"description": "When and how the user accounts file is used",
"enum_values": [
"add_when_load_ok",
"file_only_always"
],
"mandatory": false,
"modifiable": false,
"name": "user_accounts_file_usage",
"type": "enum"
},
{
"description": "Custom version string to use",
"mandatory": false,
"modifiable": true,
"name": "version_string",
"type": "string"
},
{
"default_value": "0ms",
"description": "Connection idle timeout",
"mandatory": false,
"modifiable": true,
"name": "wait_timeout",
"type": "duration",
"unit": "ms"
}
],
"version": "V1.1.0"
},
"id": "readwritesplit",
"links": {
"self": "http://localhost:8989/v1/modules/readwritesplit/"
},
"type": "modules"
},
"links": {
"self": "http://localhost:8989/v1/maxscale/modules/"
}
}GET /v1/maxscale/modules{
"data": [
{
"attributes": {
"commands": [],
"description": "maxscale",
"maturity": "GA",
"module_type": "maxscale",
"parameters": [
{
"default_value": false,
"description": "Enable REST audit logging",
"mandatory": false,
"modifiable": true,
"name": "admin_audit",
"type": "bool"
},
{
"default_value": [],
"description": "List of HTTP methods to exclude from audit logging, e.g. \"GET\"",
"enum_values": [
"GET",
"PUT",
"POST",
"PATCH",
"DELETE",
"HEAD",
"CONNECT",
"OPTIONS",
"TRACE"
],
"mandatory": false,
"modifiable": true,
"name": "admin_audit_exclude_methods",
"type": "enum list"
},
{
"default_value": "/var/log/maxscale/admin_audit.csv",
"description": "Full path to admin audit file",
"mandatory": false,
"modifiable": true,
"name": "admin_audit_file",
"type": "string"
},
{
"default_value": true,
"description": "Admin interface authentication.",
"mandatory": false,
"modifiable": false,
"name": "admin_auth",
"type": "bool"
},
{
"default_value": true,
"description": "Admin interface is enabled.",
"mandatory": false,
"modifiable": false,
"name": "admin_enabled",
"type": "bool"
},
{
"default_value": true,
"description": "Enable admin GUI.",
"mandatory": false,
"modifiable": false,
"name": "admin_gui",
"type": "bool"
},
{
"default_value": "127.0.0.1",
"description": "Admin interface host.",
"mandatory": false,
"modifiable": false,
"name": "admin_host",
"type": "string"
},
{
"default_value": "auto",
"description": "JWT signature algorithm",
"enum_values": [
"auto",
"HS256",
"HS384",
"HS512",
"RS256",
"RS384",
"RS512",
"ES256",
"ES384",
"ES512",
"PS256",
"PS384",
"PS512",
"ED25519",
"ED448"
],
"mandatory": false,
"modifiable": false,
"name": "admin_jwt_algorithm",
"type": "enum"
},
{
"default_value": "maxscale",
"description": "The issuer claim for all JWTs generated by MaxScale.",
"mandatory": false,
"modifiable": false,
"name": "admin_jwt_issuer",
"type": "string"
},
{
"description": "Encryption key ID for symmetric signature algorithms. If left empty, MaxScale will generate a random key that is used to sign the JWT.",
"mandatory": false,
"modifiable": false,
"name": "admin_jwt_key",
"type": "string"
},
{
"default_value": "86400000ms",
"description": "Maximum age of the JWTs generated by MaxScale",
"mandatory": false,
"modifiable": true,
"name": "admin_jwt_max_age",
"type": "duration",
"unit": "ms"
},
{
"default_value": true,
"description": "Log admin interface authentication failures.",
"mandatory": false,
"modifiable": true,
"name": "admin_log_auth_failures",
"type": "bool"
},
{
"description": "Extra public certificates used to validate externally signed JWTs",
"mandatory": false,
"modifiable": true,
"name": "admin_oidc_url",
"type": "string"
},
{
"description": "PAM service for read-only users.",
"mandatory": false,
"modifiable": false,
"name": "admin_pam_readonly_service",
"type": "string"
},
{
"description": "PAM service for read-write users.",
"mandatory": false,
"modifiable": false,
"name": "admin_pam_readwrite_service",
"type": "string"
},
{
"default_value": 8989,
"description": "Admin interface port.",
"mandatory": false,
"modifiable": false,
"name": "admin_port",
"type": "int"
},
{
"default_value": "*",
"description": "Allowed hosts for read-only rest-api users.",
"mandatory": false,
"modifiable": false,
"name": "admin_readonly_hosts",
"type": "host pattern list"
},
{
"default_value": "*",
"description": "Allowed hosts for read-only rest-api users.",
"mandatory": false,
"modifiable": false,
"name": "admin_readwrite_hosts",
"type": "host pattern list"
},
{
"default_value": true,
"description": "Only serve GUI over HTTPS.",
"mandatory": false,
"modifiable": false,
"name": "admin_secure_gui",
"type": "bool"
},
{
"description": "Admin SSL CA cert",
"mandatory": false,
"modifiable": false,
"name": "admin_ssl_ca",
"type": "path"
},
{
"deprecated": true,
"description": "Alias for 'admin_ssl_ca'",
"mandatory": false,
"modifiable": false,
"name": "admin_ssl_ca_cert",
"type": "path"
},
{
"description": "Admin SSL cert",
"mandatory": false,
"modifiable": true,
"name": "admin_ssl_cert",
"type": "path"
},
{
"description": "Admin SSL key",
"mandatory": false,
"modifiable": true,
"name": "admin_ssl_key",
"type": "path"
},
{
"default_value": "MAX",
"description": "Minimum required TLS protocol version for the REST API",
"enum_values": [
"MAX",
"TLSv10",
"TLSv11",
"TLSv12",
"TLSv13"
],
"mandatory": false,
"modifiable": false,
"name": "admin_ssl_version",
"type": "enum"
},
{
"description": "URL for third-party verification of client tokens",
"mandatory": false,
"modifiable": false,
"name": "admin_verify_url",
"type": "string"
},
{
"default_value": "10000ms",
"description": "Connection timeout for fetching user accounts.",
"mandatory": false,
"modifiable": true,
"name": "auth_connect_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "10000ms",
"description": "Read timeout for fetching user accounts (deprecated).",
"mandatory": false,
"modifiable": true,
"name": "auth_read_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "10000ms",
"description": "Write timeout for fetching user accounts (deprecated).",
"mandatory": false,
"modifiable": true,
"name": "auth_write_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": [],
"description": "Specifies whether a MaxScale parameter whose value depends on a specific global server variable, should automatically be updated to match the variable's current value.",
"mandatory": false,
"modifiable": false,
"name": "auto_tune",
"type": "stringlist"
},
{
"description": "Cluster used for configuration synchronization. If left empty (i.e. value is \"\"), synchronization is not done.",
"mandatory": false,
"modifiable": true,
"name": "config_sync_cluster",
"type": "string"
},
{
"default_value": "mysql",
"description": "Database where the 'maxscale_config' table is created.",
"mandatory": false,
"modifiable": false,
"name": "config_sync_db",
"type": "string"
},
{
"default_value": "5000ms",
"description": "How often to synchronize the configuration.",
"mandatory": false,
"modifiable": true,
"name": "config_sync_interval",
"type": "duration",
"unit": "ms"
},
{
"description": "Password for the user used for configuration synchronization.",
"mandatory": false,
"modifiable": true,
"name": "config_sync_password",
"type": "password"
},
{
"default_value": "10000ms",
"description": "Timeout for the configuration synchronization operations.",
"mandatory": false,
"modifiable": true,
"name": "config_sync_timeout",
"type": "duration",
"unit": "ms"
},
{
"description": "User account used for configuration synchronization.",
"mandatory": false,
"modifiable": true,
"name": "config_sync_user",
"type": "string"
},
{
"description": "Debug options",
"mandatory": false,
"modifiable": false,
"name": "debug",
"type": "string"
},
{
"default_value": "never",
"description": "In what circumstances should the last statements that a client sent be dumped.",
"enum_values": [
"on_close",
"on_error",
"never"
],
"mandatory": false,
"modifiable": true,
"name": "dump_last_statements",
"type": "enum"
},
{
"default_value": "none",
"description": "Key manager type",
"enum_values": [
"none",
"file",
"kmip",
"vault"
],
"mandatory": false,
"modifiable": true,
"name": "key_manager",
"type": "enum"
},
{
"default_value": true,
"description": "Specifies whether persisted configuration files should be loaded on startup.",
"mandatory": false,
"modifiable": false,
"name": "load_persisted_configs",
"type": "bool"
},
{
"description": "Local address to use when connecting.",
"mandatory": false,
"modifiable": false,
"name": "local_address",
"type": "string"
},
{
"default_value": false,
"description": "Specifies whether debug messages should be logged (meaningful only with debug builds).",
"mandatory": false,
"modifiable": true,
"name": "log_debug",
"type": "bool"
},
{
"default_value": false,
"description": "Specifies whether info messages should be logged.",
"mandatory": false,
"modifiable": true,
"name": "log_info",
"type": "bool"
},
{
"default_value": true,
"description": "Specifies whether notice messages should be logged.",
"mandatory": false,
"modifiable": true,
"name": "log_notice",
"type": "bool"
},
{
"default_value": {
"count": 10,
"suppress": 10000,
"window": 1000
},
"description": "Limit the amount of identical log messages than can be logged during a certain time period.",
"mandatory": false,
"modifiable": true,
"name": "log_throttling",
"type": "throttling"
},
{
"default_value": false,
"description": "Log a warning when a user with super privilege logs in.",
"mandatory": false,
"modifiable": false,
"name": "log_warn_super_user",
"type": "bool"
},
{
"default_value": true,
"description": "Specifies whether warning messages should be logged.",
"mandatory": false,
"modifiable": true,
"name": "log_warning",
"type": "bool"
},
{
"default_value": 10,
"description": "The maximum number of authentication failures that are tolerated before a host is temporarily blocked.",
"mandatory": false,
"modifiable": true,
"name": "max_auth_errors_until_block",
"type": "int"
},
{
"default_value": 0,
"description": "Maximum amount of data read before return to epoll_wait.",
"mandatory": false,
"modifiable": false,
"name": "max_read_amount",
"type": "size"
},
{
"default_value": true,
"description": "Log to MaxScale's own log.",
"mandatory": false,
"modifiable": true,
"name": "maxlog",
"type": "bool"
},
{
"default_value": false,
"description": "Enable or disable high precision timestamps.",
"mandatory": false,
"modifiable": true,
"name": "ms_timestamp",
"type": "bool"
},
{
"default_value": false,
"description": "True if MaxScale is in passive mode.",
"mandatory": false,
"modifiable": true,
"name": "passive",
"type": "bool"
},
{
"default_value": true,
"description": "Persist configurations changes done at runtime.",
"mandatory": false,
"modifiable": false,
"name": "persist_runtime_changes",
"type": "bool"
},
{
"default_value": "qc_sqlite",
"deprecated": true,
"description": "The name of the query classifier to load.",
"mandatory": false,
"modifiable": false,
"name": "query_classifier",
"type": "string"
},
{
"deprecated": true,
"description": "Arguments for the query classifier.",
"mandatory": false,
"modifiable": false,
"name": "query_classifier_args",
"type": "string"
},
{
"default_value": 5003753472,
"description": "Maximum amount of memory used by query classifier cache.",
"mandatory": false,
"modifiable": true,
"name": "query_classifier_cache_size",
"type": "size"
},
{
"default_value": 1,
"description": "Number of times an interrupted query is retried.",
"mandatory": false,
"modifiable": false,
"name": "query_retries",
"type": "int"
},
{
"default_value": "5000ms",
"description": "The total timeout in seconds for any retried queries.",
"mandatory": false,
"modifiable": true,
"name": "query_retry_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "0ms",
"description": "How often should the load of the worker threads be checked and rebalancing be made.",
"mandatory": false,
"modifiable": true,
"name": "rebalance_period",
"type": "duration",
"unit": "ms"
},
{
"default_value": 20,
"description": "If the difference in load between the thread with the maximum load and the thread with the minimum load is larger than the value of this parameter, then work will be moved from the former to the latter.",
"mandatory": false,
"modifiable": true,
"name": "rebalance_threshold",
"type": "int"
},
{
"default_value": 10,
"description": "The load of how many seconds should be taken into account when rebalancing.",
"mandatory": false,
"modifiable": true,
"name": "rebalance_window",
"type": "count"
},
{
"default_value": 0,
"description": "How many statements should be retained for each session for debugging purposes.",
"mandatory": false,
"modifiable": true,
"name": "retain_last_statements",
"type": "count"
},
{
"default_value": 0,
"description": "How many log entries are stored in the session specific trace log.",
"mandatory": false,
"modifiable": true,
"name": "session_trace",
"type": "count"
},
{
"description": "Regular expression that is matched against the contents of the session trace log and if it matches the contents are logged when the session stops.",
"mandatory": false,
"modifiable": true,
"name": "session_trace_match",
"type": "regex"
},
{
"default_value": false,
"description": "Do not resolve client IP addresses to hostnames during authentication",
"mandatory": false,
"modifiable": true,
"name": "skip_name_resolve",
"type": "bool"
},
{
"default_value": false,
"deprecated": true,
"description": "Skip service and monitor permission checks.",
"mandatory": false,
"modifiable": true,
"name": "skip_permission_checks",
"type": "bool"
},
{
"default_value": "default",
"description": "The query classifier sql mode.",
"enum_values": [
"default",
"oracle"
],
"mandatory": false,
"modifiable": false,
"name": "sql_mode",
"type": "enum"
},
{
"default_value": false,
"description": "Log to syslog.",
"mandatory": false,
"modifiable": true,
"name": "syslog",
"type": "bool"
},
{
"default_value": 8,
"description": "This parameter specifies how many threads will be used for handling the routing.",
"mandatory": false,
"modifiable": true,
"name": "threads",
"type": "count"
},
{
"default_value": 256,
"description": "This parameter specifies a hard maximum for the number of routing threads.",
"mandatory": false,
"modifiable": false,
"name": "threads_max",
"type": "count"
},
{
"default_value": "0ms",
"description": "How often the users will be refreshed.",
"mandatory": false,
"modifiable": true,
"name": "users_refresh_interval",
"type": "duration",
"unit": "ms"
},
{
"default_value": "30000ms",
"description": "How often the users can be refreshed.",
"mandatory": false,
"modifiable": true,
"name": "users_refresh_time",
"type": "duration",
"unit": "ms"
},
{
"default_value": 65536,
"description": "High water mark of dcb write queue.",
"mandatory": false,
"modifiable": true,
"name": "writeq_high_water",
"type": "size"
},
{
"default_value": 1024,
"description": "Low water mark of dcb write queue.",
"mandatory": false,
"modifiable": true,
"name": "writeq_low_water",
"type": "size"
}
],
"version": "24.02.0"
},
"id": "maxscale",
"links": {
"self": "http://localhost:8989/v1/modules/maxscale/"
},
"type": "modules"
},
{
"attributes": {
"commands": [],
"description": "servers",
"maturity": "GA",
"module_type": "servers",
"parameters": [
{
"description": "Server address",
"mandatory": false,
"modifiable": true,
"name": "address",
"type": "string"
},
{
"description": "Server authenticator (deprecated)",
"mandatory": false,
"modifiable": false,
"name": "authenticator",
"type": "string"
},
{
"description": "Server disk space threshold",
"mandatory": false,
"modifiable": true,
"name": "disk_space_threshold",
"type": "disk_space_limits"
},
{
"default_value": 0,
"description": "Server extra port",
"mandatory": false,
"modifiable": true,
"name": "extra_port",
"type": "count"
},
{
"default_value": 0,
"description": "Maximum routing connections",
"mandatory": false,
"modifiable": true,
"name": "max_routing_connections",
"type": "count"
},
{
"description": "Monitor password",
"mandatory": false,
"modifiable": true,
"name": "monitorpw",
"type": "password"
},
{
"description": "Monitor user",
"mandatory": false,
"modifiable": true,
"name": "monitoruser",
"type": "string"
},
{
"default_value": "0ms",
"description": "Maximum time that a connection can be in the pool",
"mandatory": false,
"modifiable": true,
"name": "persistmaxtime",
"type": "duration",
"unit": "ms"
},
{
"default_value": 0,
"description": "Maximum size of the persistent connection pool",
"mandatory": false,
"modifiable": true,
"name": "persistpoolmax",
"type": "count"
},
{
"default_value": 3306,
"description": "Server port",
"mandatory": false,
"modifiable": true,
"name": "port",
"type": "count"
},
{
"default_value": 0,
"description": "Server priority",
"mandatory": false,
"modifiable": true,
"name": "priority",
"type": "int"
},
{
"description": "Server private address (replication)",
"mandatory": false,
"modifiable": true,
"name": "private_address",
"type": "string"
},
{
"description": "Server protocol (deprecated)",
"mandatory": false,
"modifiable": false,
"name": "protocol",
"type": "string"
},
{
"default_value": false,
"description": "Enable proxy protocol",
"mandatory": false,
"modifiable": true,
"name": "proxy_protocol",
"type": "bool"
},
{
"default_value": "primary",
"description": "Server rank",
"enum_values": [
"primary",
"secondary"
],
"mandatory": false,
"modifiable": true,
"name": "rank",
"type": "enum"
},
{
"description": "Custom CHANGE MASTER TO options",
"mandatory": false,
"modifiable": true,
"name": "replication_custom_options",
"type": "string"
},
{
"description": "Server UNIX socket",
"mandatory": false,
"modifiable": true,
"name": "socket",
"type": "string"
},
{
"default_value": false,
"description": "Enable TLS for server",
"mandatory": false,
"modifiable": true,
"name": "ssl",
"type": "bool"
},
{
"description": "TLS certificate authority",
"mandatory": false,
"modifiable": true,
"name": "ssl_ca",
"type": "path"
},
{
"deprecated": true,
"description": "Alias for 'ssl_ca'",
"mandatory": false,
"modifiable": true,
"name": "ssl_ca_cert",
"type": "path"
},
{
"description": "TLS public certificate",
"mandatory": false,
"modifiable": true,
"name": "ssl_cert",
"type": "path"
},
{
"default_value": 9,
"description": "TLS certificate verification depth",
"mandatory": false,
"modifiable": true,
"name": "ssl_cert_verify_depth",
"type": "count"
},
{
"description": "TLS cipher list",
"mandatory": false,
"modifiable": true,
"name": "ssl_cipher",
"type": "string"
},
{
"description": "TLS private key",
"mandatory": false,
"modifiable": true,
"name": "ssl_key",
"type": "path"
},
{
"default_value": false,
"description": "Verify TLS peer certificate",
"mandatory": false,
"modifiable": true,
"name": "ssl_verify_peer_certificate",
"type": "bool"
},
{
"default_value": false,
"description": "Verify TLS peer host",
"mandatory": false,
"modifiable": true,
"name": "ssl_verify_peer_host",
"type": "bool"
},
{
"default_value": "MAX",
"description": "Minimum TLS protocol version",
"enum_values": [
"MAX",
"TLSv10",
"TLSv11",
"TLSv12",
"TLSv13"
],
"mandatory": false,
"modifiable": true,
"name": "ssl_version",
"type": "enum"
},
{
"default_value": "server",
"description": "Object type",
"mandatory": false,
"modifiable": false,
"name": "type",
"type": "string"
}
],
"version": "24.02.0"
},
"id": "servers",
"links": {
"self": "http://localhost:8989/v1/modules/servers/"
},
"type": "modules"
},
{
"attributes": {
"api": "filter",
"commands": [],
"description": "A hint parsing filter",
"maturity": "Alpha",
"module_type": "Filter",
"parameters": [],
"version": "V1.0.0"
},
"id": "hintfilter",
"links": {
"self": "http://localhost:8989/v1/modules/hintfilter/"
},
"type": "modules"
},
{
"attributes": {
"api": "authenticator",
"commands": [],
"description": "Standard MySQL/MariaDB authentication (mysql_native_password)",
"maturity": "GA",
"module_type": "Authenticator",
"parameters": null,
"version": "V2.1.0"
},
"id": "MariaDBAuth",
"links": {
"self": "http://localhost:8989/v1/modules/MariaDBAuth/"
},
"type": "modules"
},
{
"attributes": {
"api": "monitor",
"commands": [
{
"attributes": {
"arg_max": 3,
"arg_min": 1,
"description": "Switch primary server with replica",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "New primary (optional)",
"required": false,
"type": "[SERVER]"
},
{
"description": "Current primary (optional)",
"required": false,
"type": "[SERVER]"
}
]
},
"id": "switchover",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/switchover/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 3,
"arg_min": 1,
"description": "Switch primary server with replica. Ignores most errors.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "New primary (optional)",
"required": false,
"type": "[SERVER]"
},
{
"description": "Current primary (optional)",
"required": false,
"type": "[SERVER]"
}
]
},
"id": "switchover-force",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/switchover-force/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 3,
"arg_min": 1,
"description": "Schedule primary switchover. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "New primary (optional)",
"required": false,
"type": "[SERVER]"
},
{
"description": "Current primary (optional)",
"required": false,
"type": "[SERVER]"
}
]
},
"id": "async-switchover",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-switchover/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 1,
"arg_min": 1,
"description": "Perform primary failover",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
}
]
},
"id": "failover",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/failover/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 1,
"arg_min": 1,
"description": "Schedule primary failover. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
}
]
},
"id": "async-failover",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-failover/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 2,
"arg_min": 2,
"description": "Rejoin server to a cluster",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Joining server",
"required": true,
"type": "SERVER"
}
]
},
"id": "rejoin",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/rejoin/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 2,
"arg_min": 2,
"description": "Rejoin server to a cluster. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Joining server",
"required": true,
"type": "SERVER"
}
]
},
"id": "async-rejoin",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-rejoin/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 2,
"arg_min": 1,
"description": "Delete replica connections, delete binary logs and set up replication (dangerous)",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Primary server (optional)",
"required": false,
"type": "[SERVER]"
}
]
},
"id": "reset-replication",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/reset-replication/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 2,
"arg_min": 1,
"description": "Delete replica connections, delete binary logs and set up replication (dangerous). Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Primary server (optional)",
"required": false,
"type": "[SERVER]"
}
]
},
"id": "async-reset-replication",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-reset-replication/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 1,
"arg_min": 1,
"description": "Release any held server locks for 1 minute.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
}
]
},
"id": "release-locks",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/release-locks/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 1,
"arg_min": 1,
"description": "Release any held server locks for 1 minute. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
}
]
},
"id": "async-release-locks",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-release-locks/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 1,
"arg_min": 1,
"description": "Fetch result of the last scheduled command.",
"method": "GET",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
}
]
},
"id": "fetch-cmd-result",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/fetch-cmd-result/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 1,
"arg_min": 1,
"description": "Cancel the last scheduled command.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
}
]
},
"id": "cancel-cmd",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/cancel-cmd/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 3,
"arg_min": 3,
"description": "Add a node to a ColumnStore cluster. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Hostname/IP of node to add to ColumnStore cluster",
"required": true,
"type": "STRING"
},
{
"description": "Timeout",
"required": true,
"type": "STRING"
}
]
},
"id": "async-cs-add-node",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-cs-add-node/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 3,
"arg_min": 3,
"description": "Remove a node from a ColumnStore cluster. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Hostname/IP of node to remove from ColumnStore cluster",
"required": true,
"type": "STRING"
},
{
"description": "Timeout",
"required": true,
"type": "STRING"
}
]
},
"id": "async-cs-remove-node",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-cs-remove-node/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 1,
"arg_min": 1,
"description": "Get ColumnStore cluster status.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
}
]
},
"id": "cs-get-status",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/cs-get-status/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 1,
"arg_min": 1,
"description": "Get ColumnStore cluster status. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
}
]
},
"id": "async-cs-get-status",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-cs-get-status/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 2,
"arg_min": 2,
"description": "Start ColumnStore cluster. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Timeout",
"required": true,
"type": "STRING"
}
]
},
"id": "async-cs-start-cluster",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-cs-start-cluster/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 2,
"arg_min": 2,
"description": "Stop ColumnStore cluster. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Timeout",
"required": true,
"type": "STRING"
}
]
},
"id": "async-cs-stop-cluster",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-cs-stop-cluster/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 2,
"arg_min": 2,
"description": "Set ColumnStore cluster read-only. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Timeout",
"required": true,
"type": "STRING"
}
]
},
"id": "async-cs-set-readonly",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-cs-set-readonly/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 2,
"arg_min": 2,
"description": "Set ColumnStore cluster readwrite. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Timeout",
"required": true,
"type": "STRING"
}
]
},
"id": "async-cs-set-readwrite",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-cs-set-readwrite/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 4,
"arg_min": 2,
"description": "Rebuild a server with mariadb-backup. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Target server",
"required": true,
"type": "SERVER"
},
{
"description": "Source server (optional)",
"required": false,
"type": "[SERVER]"
},
{
"description": "Target data directory (optional)",
"required": false,
"type": "[STRING]"
}
]
},
"id": "async-rebuild-server",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-rebuild-server/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 3,
"arg_min": 3,
"description": "Create a backup with mariadb-backup. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Source server",
"required": true,
"type": "SERVER"
},
{
"description": "Backup name",
"required": true,
"type": "STRING"
}
]
},
"id": "async-create-backup",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-create-backup/"
},
"type": "module_command"
},
{
"attributes": {
"arg_max": 4,
"arg_min": 3,
"description": "Restore a server from a backup. Does not wait for completion.",
"method": "POST",
"parameters": [
{
"description": "Monitor name",
"required": true,
"type": "MONITOR"
},
{
"description": "Target server",
"required": true,
"type": "SERVER"
},
{
"description": "Backup name",
"required": true,
"type": "STRING"
},
{
"description": "Target data directory (optional)",
"required": false,
"type": "[STRING]"
}
]
},
"id": "async-restore-from-backup",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/async-restore-from-backup/"
},
"type": "module_command"
}
],
"description": "A MariaDB Primary/Replica replication monitor",
"maturity": "GA",
"module_type": "Monitor",
"parameters": [
{
"default_value": true,
"description": "Assume that hostnames are unique",
"mandatory": false,
"modifiable": true,
"name": "assume_unique_hostnames",
"type": "bool"
},
{
"default_value": false,
"description": "Enable automatic server failover",
"mandatory": false,
"modifiable": true,
"name": "auto_failover",
"type": "bool"
},
{
"default_value": false,
"description": "Enable automatic server rejoin",
"mandatory": false,
"modifiable": true,
"name": "auto_rejoin",
"type": "bool"
},
{
"description": "Address of backup storage.",
"mandatory": false,
"modifiable": true,
"name": "backup_storage_address",
"type": "string"
},
{
"description": "Backup storage directory path.",
"mandatory": false,
"modifiable": true,
"name": "backup_storage_path",
"type": "string"
},
{
"default_value": "none",
"description": "Cooperative monitoring type",
"enum_values": [
"none",
"majority_of_running",
"majority_of_all"
],
"mandatory": false,
"modifiable": true,
"name": "cooperative_monitoring_locks",
"type": "enum"
},
{
"description": "The API key used in communication with the ColumnStore admin daemon.",
"mandatory": false,
"modifiable": false,
"name": "cs_admin_api_key",
"type": "string"
},
{
"default_value": "/cmapi/0.4.0",
"description": "The base path to be used when accessing the ColumnStore administrative daemon. If, for instance, a daemon URL is https://localhost:8640/cmapi/0.4.0/node/start then the admin_base_path is \"/cmapi/0.4.0\".",
"mandatory": false,
"modifiable": false,
"name": "cs_admin_base_path",
"type": "string"
},
{
"default_value": 8640,
"description": "Port of the ColumnStore administrative daemon.",
"mandatory": false,
"modifiable": false,
"name": "cs_admin_port",
"type": "count"
},
{
"description": "Path to SQL file that is executed during node demotion",
"mandatory": false,
"modifiable": true,
"name": "demotion_sql_file",
"type": "path"
},
{
"default_value": false,
"description": "Enable read_only on all slave servers",
"mandatory": false,
"modifiable": true,
"name": "enforce_read_only_slaves",
"type": "bool"
},
{
"default_value": false,
"description": "Enforce a simple topology",
"mandatory": false,
"modifiable": true,
"name": "enforce_simple_topology",
"type": "bool"
},
{
"default_value": false,
"description": "Disable read_only on the current master server",
"mandatory": false,
"modifiable": true,
"name": "enforce_writable_master",
"type": "bool"
},
{
"default_value": 5,
"description": "Number of failures to tolerate before failover occurs",
"mandatory": false,
"modifiable": true,
"name": "failcount",
"type": "count"
},
{
"default_value": "90000ms",
"description": "Timeout for failover",
"mandatory": false,
"modifiable": true,
"name": "failover_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": true,
"description": "Manage server-side events",
"mandatory": false,
"modifiable": true,
"name": "handle_events",
"type": "bool"
},
{
"default_value": true,
"description": "Put the server into maintenance mode when it runs out of disk space",
"mandatory": false,
"modifiable": true,
"name": "maintenance_on_low_disk_space",
"type": "bool"
},
{
"default_value": 1,
"description": "mariadb-backup thread count.",
"mandatory": false,
"modifiable": true,
"name": "mariadb-backup_parallel",
"type": "int"
},
{
"default_value": "1G",
"description": "mariadb-backup buffer pool size.",
"mandatory": false,
"modifiable": true,
"name": "mariadb-backup_use_memory",
"type": "string"
},
{
"default_value": "primary_monitor_master",
"description": "Conditions that the master servers must meet",
"enum_values": [
"none",
"connecting_slave",
"connected_slave",
"running_slave",
"primary_monitor_master"
],
"mandatory": false,
"modifiable": true,
"name": "master_conditions",
"type": "enum_mask"
},
{
"default_value": "10000ms",
"description": "Master failure timeout",
"mandatory": false,
"modifiable": true,
"name": "master_failure_timeout",
"type": "duration",
"unit": "ms"
},
{
"description": "Path to SQL file that is executed during node promotion",
"mandatory": false,
"modifiable": true,
"name": "promotion_sql_file",
"type": "path"
},
{
"default_value": 4444,
"description": "Listen port used for transferring server backup.",
"mandatory": false,
"modifiable": true,
"name": "rebuild_port",
"type": "count"
},
{
"description": "Custom CHANGE MASTER TO options",
"mandatory": false,
"modifiable": true,
"name": "replication_custom_options",
"type": "string"
},
{
"default_value": false,
"description": "Enable SSL when configuring replication",
"mandatory": false,
"modifiable": true,
"name": "replication_master_ssl",
"type": "bool"
},
{
"description": "Password for the user that is used for replication",
"mandatory": false,
"modifiable": true,
"name": "replication_password",
"type": "password"
},
{
"description": "User used for replication",
"mandatory": false,
"modifiable": true,
"name": "replication_user",
"type": "string"
},
{
"default_value": -1,
"description": "Replication lag limit at which the script is run",
"mandatory": false,
"modifiable": true,
"name": "script_max_replication_lag",
"type": "int"
},
{
"description": "List of servers that are never promoted",
"mandatory": false,
"modifiable": true,
"name": "servers_no_promotion",
"type": "serverlist"
},
{
"default_value": "",
"description": "Conditions that the slave servers must meet",
"enum_values": [
"linked_master",
"running_master",
"writable_master",
"primary_monitor_master",
"none"
],
"mandatory": false,
"modifiable": true,
"name": "slave_conditions",
"type": "enum_mask"
},
{
"default_value": true,
"description": "Is SSH host key check enabled.",
"mandatory": false,
"modifiable": true,
"name": "ssh_check_host_key",
"type": "bool"
},
{
"description": "SSH keyfile. Used for running remote commands on servers.",
"mandatory": false,
"modifiable": false,
"name": "ssh_keyfile",
"type": "path"
},
{
"default_value": 22,
"description": "SSH port. Used for running remote commands on servers.",
"mandatory": false,
"modifiable": true,
"name": "ssh_port",
"type": "count"
},
{
"default_value": "10000ms",
"description": "SSH connection and command timeout",
"mandatory": false,
"modifiable": true,
"name": "ssh_timeout",
"type": "duration",
"unit": "ms"
},
{
"description": "SSH username. Used for running remote commands on servers.",
"mandatory": false,
"modifiable": false,
"name": "ssh_user",
"type": "string"
},
{
"default_value": false,
"description": "Perform a switchover when a server runs out of disk space",
"mandatory": false,
"modifiable": true,
"name": "switchover_on_low_disk_space",
"type": "bool"
},
{
"default_value": "90000ms",
"description": "Timeout for switchover",
"mandatory": false,
"modifiable": true,
"name": "switchover_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": true,
"description": "Verify master failure",
"mandatory": false,
"modifiable": true,
"name": "verify_master_failure",
"type": "bool"
},
{
"default_value": 1,
"description": "Number of connection attempts to make to a server",
"mandatory": false,
"modifiable": true,
"name": "backend_connect_attempts",
"type": "count"
},
{
"default_value": "3000ms",
"description": "Connection timeout for monitor connections",
"mandatory": false,
"modifiable": true,
"name": "backend_connect_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "3000ms",
"description": "Read timeout for monitor connections",
"mandatory": false,
"modifiable": true,
"name": "backend_read_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "3000ms",
"description": "Write timeout for monitor connections",
"mandatory": false,
"modifiable": true,
"name": "backend_write_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "0ms",
"description": "How often the disk space is checked",
"mandatory": false,
"modifiable": true,
"name": "disk_space_check_interval",
"type": "duration",
"unit": "ms"
},
{
"description": "Disk space threshold",
"mandatory": false,
"modifiable": true,
"name": "disk_space_threshold",
"type": "string"
},
{
"default_value": "all,master_down,master_up,slave_down,slave_up,server_down,server_up,synced_down,synced_up,donor_down,donor_up,lost_master,lost_slave,lost_synced,lost_donor,new_master,new_slave,new_synced,new_donor",
"description": "Events that cause the script to be called",
"enum_values": [
"all",
"master_down",
"master_up",
"slave_down",
"slave_up",
"server_down",
"server_up",
"synced_down",
"synced_up",
"donor_down",
"donor_up",
"lost_master",
"lost_slave",
"lost_synced",
"lost_donor",
"new_master",
"new_slave",
"new_synced",
"new_donor"
],
"mandatory": false,
"modifiable": true,
"name": "events",
"type": "enum_mask"
},
{
"default_value": "28800000ms",
"description": "The time the on-disk cached server states are valid for",
"mandatory": false,
"modifiable": true,
"name": "journal_max_age",
"type": "duration",
"unit": "ms"
},
{
"default_value": "2000ms",
"description": "How often the servers are monitored",
"mandatory": false,
"modifiable": true,
"name": "monitor_interval",
"type": "duration",
"unit": "ms"
},
{
"description": "Password for the user used to monitor the servers",
"mandatory": true,
"modifiable": true,
"name": "password",
"type": "password"
},
{
"description": "Script to run whenever an event occurs",
"mandatory": false,
"modifiable": true,
"name": "script",
"type": "string"
},
{
"default_value": "90000ms",
"description": "Timeout for the script",
"mandatory": false,
"modifiable": true,
"name": "script_timeout",
"type": "duration",
"unit": "ms"
},
{
"description": "List of servers to use",
"mandatory": false,
"modifiable": true,
"name": "servers",
"type": "serverlist"
},
{
"description": "Username used to monitor the servers",
"mandatory": true,
"modifiable": true,
"name": "user",
"type": "string"
}
],
"version": "V1.5.0"
},
"id": "mariadbmon",
"links": {
"self": "http://localhost:8989/v1/modules/mariadbmon/"
},
"type": "modules"
},
{
"attributes": {
"api": "protocol",
"commands": [],
"description": "The client to MaxScale MySQL protocol implementation",
"maturity": "GA",
"module_type": "Protocol",
"parameters": [
{
"default_value": true,
"description": "Allow use of the replication protocol through this listener",
"mandatory": false,
"modifiable": false,
"name": "allow_replication",
"type": "bool"
},
{
"default_value": "::",
"description": "Listener address",
"mandatory": false,
"modifiable": false,
"name": "address",
"type": "string"
},
{
"description": "Listener authenticator",
"mandatory": false,
"modifiable": false,
"name": "authenticator",
"type": "string"
},
{
"description": "Authenticator options",
"mandatory": false,
"modifiable": false,
"name": "authenticator_options",
"type": "string"
},
{
"description": "Path to connection initialization SQL",
"mandatory": false,
"modifiable": true,
"name": "connection_init_sql_file",
"type": "path"
},
{
"default_value": [
"character_set_client=auto",
"character_set_connection=auto",
"character_set_results=auto",
"max_allowed_packet=auto",
"system_time_zone=auto",
"time_zone=auto",
"tx_isolation=auto",
"maxscale=auto"
],
"description": "Metadata that's sent to all connecting clients.",
"mandatory": false,
"modifiable": true,
"name": "connection_metadata",
"type": "stringlist"
},
{
"default_value": 0,
"description": "Listener port",
"mandatory": false,
"modifiable": false,
"name": "port",
"type": "count"
},
{
"default_value": "MariaDBProtocol",
"description": "Listener protocol to use",
"mandatory": false,
"modifiable": false,
"name": "protocol",
"type": "module"
},
{
"description": "Allowed (sub)networks for proxy protocol connections. Should be a comma-separated list of IPv4 or IPv6 addresses.",
"mandatory": false,
"modifiable": true,
"name": "proxy_protocol_networks",
"type": "string"
},
{
"description": "Service to which the listener connects to",
"mandatory": true,
"modifiable": false,
"name": "service",
"type": "service"
},
{
"description": "Listener UNIX socket",
"mandatory": false,
"modifiable": false,
"name": "socket",
"type": "string"
},
{
"default_value": "default",
"description": "SQL parsing mode",
"enum_values": [
"default",
"oracle"
],
"mandatory": false,
"modifiable": true,
"name": "sql_mode",
"type": "enum"
},
{
"default_value": false,
"description": "Enable TLS for server",
"mandatory": false,
"modifiable": true,
"name": "ssl",
"type": "bool"
},
{
"description": "TLS certificate authority",
"mandatory": false,
"modifiable": true,
"name": "ssl_ca",
"type": "path"
},
{
"deprecated": true,
"description": "Alias for 'ssl_ca'",
"mandatory": false,
"modifiable": true,
"name": "ssl_ca_cert",
"type": "path"
},
{
"description": "TLS public certificate",
"mandatory": false,
"modifiable": true,
"name": "ssl_cert",
"type": "path"
},
{
"default_value": 9,
"description": "TLS certificate verification depth",
"mandatory": false,
"modifiable": true,
"name": "ssl_cert_verify_depth",
"type": "count"
},
{
"description": "TLS cipher list",
"mandatory": false,
"modifiable": true,
"name": "ssl_cipher",
"type": "string"
},
{
"description": "TLS certificate revocation list",
"mandatory": false,
"modifiable": true,
"name": "ssl_crl",
"type": "string"
},
{
"description": "TLS private key",
"mandatory": false,
"modifiable": true,
"name": "ssl_key",
"type": "path"
},
{
"default_value": false,
"description": "Verify TLS peer certificate",
"mandatory": false,
"modifiable": true,
"name": "ssl_verify_peer_certificate",
"type": "bool"
},
{
"default_value": false,
"description": "Verify TLS peer host",
"mandatory": false,
"modifiable": true,
"name": "ssl_verify_peer_host",
"type": "bool"
},
{
"default_value": "MAX",
"description": "Minimum TLS protocol version",
"enum_values": [
"MAX",
"TLSv10",
"TLSv11",
"TLSv12",
"TLSv13"
],
"mandatory": false,
"modifiable": true,
"name": "ssl_version",
"type": "enum"
},
{
"description": "Path to user and group mapping file",
"mandatory": false,
"modifiable": true,
"name": "user_mapping_file",
"type": "path"
}
],
"version": "V1.1.0"
},
"id": "MariaDBProtocol",
"links": {
"self": "http://localhost:8989/v1/modules/MariaDBProtocol/"
},
"type": "modules"
},
{
"attributes": {
"api": "parser",
"commands": [],
"description": "MariaDB SQL parser using sqlite3.",
"maturity": "GA",
"module_type": "Parser",
"parameters": null,
"version": "V1.0.0"
},
"id": "pp_sqlite",
"links": {
"self": "http://localhost:8989/v1/modules/pp_sqlite/"
},
"type": "modules"
},
{
"attributes": {
"api": "filter",
"commands": [
{
"attributes": {
"arg_max": 3,
"arg_min": 1,
"description": "Show unified log file as a JSON array",
"method": "GET",
"parameters": [
{
"description": "Filter to read logs from",
"required": true,
"type": "FILTER"
},
{
"description": "Start reading from this line",
"required": false,
"type": "[STRING]"
},
{
"description": "Stop reading at this line (exclusive)",
"required": false,
"type": "[STRING]"
}
]
},
"id": "log",
"links": {
"self": "http://localhost:8989/v1/modules/qlafilter/log/"
},
"type": "module_command"
}
],
"description": "A simple query logging filter",
"maturity": "GA",
"module_type": "Filter",
"parameters": [
{
"default_value": true,
"description": "Append new entries to log files instead of overwriting them",
"mandatory": false,
"modifiable": true,
"name": "append",
"type": "bool"
},
{
"default_value": "ms",
"description": "Duration in milliseconds (ms) or microseconds (us)",
"enum_values": [
"ms",
"milliseconds",
"us",
"microseconds"
],
"mandatory": false,
"modifiable": true,
"name": "duration_unit",
"type": "enum"
},
{
"description": "Exclude queries matching this pattern from the log",
"mandatory": false,
"modifiable": true,
"name": "exclude",
"type": "regex"
},
{
"description": "The basename of the output file",
"mandatory": true,
"modifiable": true,
"name": "filebase",
"type": "string"
},
{
"default_value": false,
"description": "Flush log files after every write",
"mandatory": false,
"modifiable": true,
"name": "flush",
"type": "bool"
},
{
"default_value": "date,user,query",
"description": "Type of data to log in the log files",
"enum_values": [
"service",
"session",
"date",
"user",
"query",
"reply_time",
"total_reply_time",
"default_db",
"num_rows",
"reply_size",
"transaction",
"transaction_time",
"num_warnings",
"error_msg",
"server",
"command"
],
"mandatory": false,
"modifiable": true,
"name": "log_data",
"type": "enum_mask"
},
{
"default_value": "session",
"description": "The type of log file to use",
"enum_values": [
"session",
"unified",
"stdout"
],
"mandatory": false,
"modifiable": true,
"name": "log_type",
"type": "enum_mask"
},
{
"description": "Only log queries matching this pattern",
"mandatory": false,
"modifiable": true,
"name": "match",
"type": "regex"
},
{
"default_value": " ",
"description": "Value used to replace newlines",
"mandatory": false,
"modifiable": true,
"name": "newline_replacement",
"type": "string"
},
{
"default_value": "",
"description": "Regular expression options",
"enum_values": [
"case",
"ignorecase",
"extended"
],
"mandatory": false,
"modifiable": true,
"name": "options",
"type": "enum_mask"
},
{
"default_value": ",",
"description": "Defines the separator between elements of a log entry",
"mandatory": false,
"modifiable": true,
"name": "separator",
"type": "string"
},
{
"description": "Log queries only from this network address",
"mandatory": false,
"modifiable": true,
"name": "source",
"type": "string"
},
{
"description": "Exclude queries from hosts that match this pattern",
"mandatory": false,
"modifiable": true,
"name": "source_exclude",
"type": "regex"
},
{
"description": "Log queries only from hosts that match this pattern",
"mandatory": false,
"modifiable": true,
"name": "source_match",
"type": "regex"
},
{
"default_value": false,
"description": "Write queries in canonical form",
"mandatory": false,
"modifiable": true,
"name": "use_canonical_form",
"type": "bool"
},
{
"description": "Log queries only from this user",
"mandatory": false,
"modifiable": true,
"name": "user",
"type": "string"
},
{
"description": "Exclude queries from users that match this pattern",
"mandatory": false,
"modifiable": true,
"name": "user_exclude",
"type": "regex"
},
{
"description": "Log queries only from users that match this pattern",
"mandatory": false,
"modifiable": true,
"name": "user_match",
"type": "regex"
}
],
"version": "V1.1.1"
},
"id": "qlafilter",
"links": {
"self": "http://localhost:8989/v1/modules/qlafilter/"
},
"type": "modules"
},
{
"attributes": {
"api": "router",
"commands": [],
"description": "A connection based router to load balance based on connections",
"maturity": "GA",
"module_type": "Router",
"parameters": [
{
"default_value": true,
"description": "Use master for reads",
"mandatory": false,
"modifiable": true,
"name": "master_accept_reads",
"type": "bool"
},
{
"default_value": "0ms",
"description": "Maximum acceptable replication lag",
"mandatory": false,
"modifiable": true,
"name": "max_replication_lag",
"type": "duration",
"unit": "ms"
},
{
"default_value": "running",
"description": "A comma separated list of server roles",
"enum_values": [
"master",
"slave",
"running",
"synced"
],
"mandatory": false,
"modifiable": true,
"name": "router_options",
"type": "enum_mask"
},
{
"default_value": false,
"deprecated": true,
"description": "Retrieve users from all backend servers instead of only one",
"mandatory": false,
"modifiable": true,
"name": "auth_all_servers",
"type": "bool"
},
{
"default_value": "300000ms",
"description": "How often idle connections are pinged",
"mandatory": false,
"modifiable": true,
"name": "connection_keepalive",
"type": "duration",
"unit": "ms"
},
{
"deprecated": true,
"description": "Alias for 'wait_timeout'",
"mandatory": false,
"modifiable": true,
"name": "connection_timeout",
"type": "duration"
},
{
"default_value": false,
"description": "Disable session command history",
"mandatory": false,
"modifiable": true,
"name": "disable_sescmd_history",
"type": "bool"
},
{
"default_value": false,
"description": "Allow the root user to connect to this service",
"mandatory": false,
"modifiable": true,
"name": "enable_root_user",
"type": "bool"
},
{
"default_value": false,
"description": "Ping connections unconditionally",
"mandatory": false,
"modifiable": true,
"name": "force_connection_keepalive",
"type": "bool"
},
{
"default_value": "-1ms",
"description": "Put connections into pool after session has been idle for this long",
"mandatory": false,
"modifiable": true,
"name": "idle_session_pool_time",
"type": "duration",
"unit": "ms"
},
{
"default_value": true,
"description": "Match localhost to wildcard host",
"mandatory": false,
"modifiable": true,
"name": "localhost_match_wildcard_host",
"type": "bool"
},
{
"default_value": true,
"description": "Log a warning when client authentication fails",
"mandatory": false,
"modifiable": true,
"name": "log_auth_warnings",
"type": "bool"
},
{
"default_value": false,
"description": "Log debug messages for this service (debug builds only)",
"mandatory": false,
"modifiable": true,
"name": "log_debug",
"type": "bool"
},
{
"default_value": false,
"description": "Log info messages for this service",
"mandatory": false,
"modifiable": true,
"name": "log_info",
"type": "bool"
},
{
"default_value": false,
"description": "Log notice messages for this service",
"mandatory": false,
"modifiable": true,
"name": "log_notice",
"type": "bool"
},
{
"default_value": false,
"description": "Log warning messages for this service",
"mandatory": false,
"modifiable": true,
"name": "log_warning",
"type": "bool"
},
{
"default_value": 0,
"description": "Maximum number of connections",
"mandatory": false,
"modifiable": true,
"name": "max_connections",
"type": "count"
},
{
"default_value": 50,
"description": "Session command history size",
"mandatory": false,
"modifiable": true,
"name": "max_sescmd_history",
"type": "count"
},
{
"default_value": "60000ms",
"description": "How long a session can wait for a connection to become available",
"mandatory": false,
"modifiable": true,
"name": "multiplex_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "0ms",
"description": "Network write timeout",
"mandatory": false,
"modifiable": true,
"name": "net_write_timeout",
"type": "duration",
"unit": "ms"
},
{
"description": "Password for the user used to retrieve database users",
"mandatory": true,
"modifiable": true,
"name": "password",
"type": "password"
},
{
"default_value": true,
"description": "Prune old session command history if the limit is exceeded",
"mandatory": false,
"modifiable": true,
"name": "prune_sescmd_history",
"type": "bool"
},
{
"default_value": "primary",
"description": "Service rank",
"enum_values": [
"primary",
"secondary"
],
"mandatory": false,
"modifiable": true,
"name": "rank",
"type": "enum"
},
{
"default_value": -1,
"description": "Number of statements kept in memory",
"mandatory": false,
"modifiable": true,
"name": "retain_last_statements",
"type": "int"
},
{
"default_value": false,
"description": "Enable session tracing for this service",
"mandatory": false,
"modifiable": true,
"name": "session_trace",
"type": "bool"
},
{
"default_value": false,
"deprecated": true,
"description": "Track session state using server responses",
"mandatory": false,
"modifiable": true,
"name": "session_track_trx_state",
"type": "bool"
},
{
"default_value": true,
"deprecated": true,
"description": "Strip escape characters from database names",
"mandatory": false,
"modifiable": true,
"name": "strip_db_esc",
"type": "bool"
},
{
"description": "Username used to retrieve database users",
"mandatory": true,
"modifiable": true,
"name": "user",
"type": "string"
},
{
"description": "Load additional users from a file",
"mandatory": false,
"modifiable": false,
"name": "user_accounts_file",
"type": "path"
},
{
"default_value": "add_when_load_ok",
"description": "When and how the user accounts file is used",
"enum_values": [
"add_when_load_ok",
"file_only_always"
],
"mandatory": false,
"modifiable": false,
"name": "user_accounts_file_usage",
"type": "enum"
},
{
"description": "Custom version string to use",
"mandatory": false,
"modifiable": true,
"name": "version_string",
"type": "string"
},
{
"default_value": "0ms",
"description": "Connection idle timeout",
"mandatory": false,
"modifiable": true,
"name": "wait_timeout",
"type": "duration",
"unit": "ms"
}
],
"version": "V2.0.0"
},
"id": "readconnroute",
"links": {
"self": "http://localhost:8989/v1/modules/readconnroute/"
},
"type": "modules"
},
{
"attributes": {
"api": "router",
"commands": [
{
"attributes": {
"arg_max": 1,
"arg_min": 1,
"description": "Reset global GTID state in readwritesplit.",
"method": "POST",
"parameters": [
{
"description": "Readwritesplit service",
"required": true,
"type": "SERVICE"
}
]
},
"id": "reset-gtid",
"links": {
"self": "http://localhost:8989/v1/modules/readwritesplit/reset-gtid/"
},
"type": "module_command"
}
],
"description": "A Read/Write splitting router for enhancement read scalability",
"maturity": "GA",
"module_type": "Router",
"parameters": [
{
"default_value": "none",
"description": "Causal reads mode",
"enum_values": [
"none",
"local",
"global",
"fast_global",
"fast",
"universal",
"fast_universal",
"false",
"off",
"0",
"true",
"on",
"1"
],
"mandatory": false,
"modifiable": true,
"name": "causal_reads",
"type": "enum"
},
{
"default_value": "10000ms",
"description": "Timeout for the slave synchronization",
"mandatory": false,
"modifiable": true,
"name": "causal_reads_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": false,
"description": "Retry failed writes outside of transactions",
"mandatory": false,
"modifiable": true,
"name": "delayed_retry",
"type": "bool"
},
{
"default_value": "10000ms",
"description": "Timeout for delayed_retry",
"mandatory": false,
"modifiable": true,
"name": "delayed_retry_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": false,
"description": "Create connections only when needed",
"mandatory": false,
"modifiable": true,
"name": "lazy_connect",
"type": "bool"
},
{
"default_value": false,
"description": "Use master for reads",
"mandatory": false,
"modifiable": true,
"name": "master_accept_reads",
"type": "bool"
},
{
"default_value": "fail_on_write",
"description": "Master failure mode behavior",
"enum_values": [
"fail_instantly",
"fail_on_write",
"error_on_write"
],
"mandatory": false,
"modifiable": true,
"name": "master_failure_mode",
"type": "enum"
},
{
"default_value": true,
"description": "Reconnect to master",
"mandatory": false,
"modifiable": true,
"name": "master_reconnection",
"type": "bool"
},
{
"default_value": "0ms",
"description": "Maximum replication lag",
"mandatory": false,
"modifiable": true,
"name": "max_replication_lag",
"type": "duration",
"unit": "ms"
},
{
"default_value": 255,
"description": "Maximum number of slave connections",
"mandatory": false,
"modifiable": true,
"name": "max_slave_connections",
"type": "count"
},
{
"deprecated": true,
"description": "Alias for 'max_replication_lag'",
"mandatory": false,
"modifiable": true,
"name": "max_slave_replication_lag",
"type": "duration"
},
{
"default_value": false,
"description": "Optimistically offload transactions to slaves",
"mandatory": false,
"modifiable": true,
"name": "optimistic_trx",
"type": "bool"
},
{
"default_value": true,
"description": "Automatically retry failed reads outside of transactions",
"mandatory": false,
"modifiable": true,
"name": "retry_failed_reads",
"type": "bool"
},
{
"default_value": false,
"description": "Reuse identical prepared statements inside the same connection",
"mandatory": false,
"modifiable": true,
"name": "reuse_prepared_statements",
"type": "bool"
},
{
"default_value": 255,
"description": "Starting number of slave connections",
"mandatory": false,
"modifiable": true,
"name": "slave_connections",
"type": "count"
},
{
"default_value": "least_current_operations",
"description": "Slave selection criteria",
"enum_values": [
"least_global_connections",
"least_router_connections",
"least_behind_master",
"least_current_operations",
"adaptive_routing",
"LEAST_GLOBAL_CONNECTIONS",
"LEAST_ROUTER_CONNECTIONS",
"LEAST_BEHIND_MASTER",
"LEAST_CURRENT_OPERATIONS",
"ADAPTIVE_ROUTING"
],
"mandatory": false,
"modifiable": true,
"name": "slave_selection_criteria",
"type": "enum"
},
{
"default_value": false,
"description": "Lock connection to master after multi-statement query",
"mandatory": false,
"modifiable": true,
"name": "strict_multi_stmt",
"type": "bool"
},
{
"default_value": false,
"description": "Lock connection to master after a stored procedure is executed",
"mandatory": false,
"modifiable": true,
"name": "strict_sp_calls",
"type": "bool"
},
{
"default_value": true,
"description": "Prevent reconnections if temporary tables exist",
"mandatory": false,
"modifiable": true,
"name": "strict_tmp_tables",
"type": "bool"
},
{
"default_value": false,
"description": "Retry failed transactions",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay",
"type": "bool"
},
{
"default_value": 5,
"description": "Maximum number of times to retry a transaction",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_attempts",
"type": "count"
},
{
"default_value": "full",
"description": "Type of checksum to calculate for results",
"enum_values": [
"full",
"result_only",
"no_insert_id"
],
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_checksum",
"type": "enum"
},
{
"default_value": 1048576,
"description": "Maximum size of transaction to retry",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_max_size",
"type": "size"
},
{
"default_value": false,
"description": "Retry transaction on deadlock",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_retry_on_deadlock",
"type": "bool"
},
{
"default_value": false,
"description": "Retry transaction on checksum mismatch",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_retry_on_mismatch",
"type": "bool"
},
{
"default_value": true,
"description": "Prevent replaying of about-to-commit transaction",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_safe_commit",
"type": "bool"
},
{
"default_value": "30000ms",
"description": "Timeout for transaction replay",
"mandatory": false,
"modifiable": true,
"name": "transaction_replay_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "all",
"description": "Whether to route SQL variable modifications to all servers or only to the master",
"enum_values": [
"all",
"master"
],
"mandatory": false,
"modifiable": true,
"name": "use_sql_variables_in",
"type": "enum"
},
{
"default_value": false,
"deprecated": true,
"description": "Retrieve users from all backend servers instead of only one",
"mandatory": false,
"modifiable": true,
"name": "auth_all_servers",
"type": "bool"
},
{
"default_value": "300000ms",
"description": "How often idle connections are pinged",
"mandatory": false,
"modifiable": true,
"name": "connection_keepalive",
"type": "duration",
"unit": "ms"
},
{
"deprecated": true,
"description": "Alias for 'wait_timeout'",
"mandatory": false,
"modifiable": true,
"name": "connection_timeout",
"type": "duration"
},
{
"default_value": false,
"description": "Disable session command history",
"mandatory": false,
"modifiable": true,
"name": "disable_sescmd_history",
"type": "bool"
},
{
"default_value": false,
"description": "Allow the root user to connect to this service",
"mandatory": false,
"modifiable": true,
"name": "enable_root_user",
"type": "bool"
},
{
"default_value": false,
"description": "Ping connections unconditionally",
"mandatory": false,
"modifiable": true,
"name": "force_connection_keepalive",
"type": "bool"
},
{
"default_value": "-1ms",
"description": "Put connections into pool after session has been idle for this long",
"mandatory": false,
"modifiable": true,
"name": "idle_session_pool_time",
"type": "duration",
"unit": "ms"
},
{
"default_value": true,
"description": "Match localhost to wildcard host",
"mandatory": false,
"modifiable": true,
"name": "localhost_match_wildcard_host",
"type": "bool"
},
{
"default_value": true,
"description": "Log a warning when client authentication fails",
"mandatory": false,
"modifiable": true,
"name": "log_auth_warnings",
"type": "bool"
},
{
"default_value": false,
"description": "Log debug messages for this service (debug builds only)",
"mandatory": false,
"modifiable": true,
"name": "log_debug",
"type": "bool"
},
{
"default_value": false,
"description": "Log info messages for this service",
"mandatory": false,
"modifiable": true,
"name": "log_info",
"type": "bool"
},
{
"default_value": false,
"description": "Log notice messages for this service",
"mandatory": false,
"modifiable": true,
"name": "log_notice",
"type": "bool"
},
{
"default_value": false,
"description": "Log warning messages for this service",
"mandatory": false,
"modifiable": true,
"name": "log_warning",
"type": "bool"
},
{
"default_value": 0,
"description": "Maximum number of connections",
"mandatory": false,
"modifiable": true,
"name": "max_connections",
"type": "count"
},
{
"default_value": 50,
"description": "Session command history size",
"mandatory": false,
"modifiable": true,
"name": "max_sescmd_history",
"type": "count"
},
{
"default_value": "60000ms",
"description": "How long a session can wait for a connection to become available",
"mandatory": false,
"modifiable": true,
"name": "multiplex_timeout",
"type": "duration",
"unit": "ms"
},
{
"default_value": "0ms",
"description": "Network write timeout",
"mandatory": false,
"modifiable": true,
"name": "net_write_timeout",
"type": "duration",
"unit": "ms"
},
{
"description": "Password for the user used to retrieve database users",
"mandatory": true,
"modifiable": true,
"name": "password",
"type": "password"
},
{
"default_value": true,
"description": "Prune old session command history if the limit is exceeded",
"mandatory": false,
"modifiable": true,
"name": "prune_sescmd_history",
"type": "bool"
},
{
"default_value": "primary",
"description": "Service rank",
"enum_values": [
"primary",
"secondary"
],
"mandatory": false,
"modifiable": true,
"name": "rank",
"type": "enum"
},
{
"default_value": -1,
"description": "Number of statements kept in memory",
"mandatory": false,
"modifiable": true,
"name": "retain_last_statements",
"type": "int"
},
{
"default_value": false,
"description": "Enable session tracing for this service",
"mandatory": false,
"modifiable": true,
"name": "session_trace",
"type": "bool"
},
{
"default_value": false,
"deprecated": true,
"description": "Track session state using server responses",
"mandatory": false,
"modifiable": true,
"name": "session_track_trx_state",
"type": "bool"
},
{
"default_value": true,
"deprecated": true,
"description": "Strip escape characters from database names",
"mandatory": false,
"modifiable": true,
"name": "strip_db_esc",
"type": "bool"
},
{
"description": "Username used to retrieve database users",
"mandatory": true,
"modifiable": true,
"name": "user",
"type": "string"
},
{
"description": "Load additional users from a file",
"mandatory": false,
"modifiable": false,
"name": "user_accounts_file",
"type": "path"
},
{
"default_value": "add_when_load_ok",
"description": "When and how the user accounts file is used",
"enum_values": [
"add_when_load_ok",
"file_only_always"
],
"mandatory": false,
"modifiable": false,
"name": "user_accounts_file_usage",
"type": "enum"
},
{
"description": "Custom version string to use",
"mandatory": false,
"modifiable": true,
"name": "version_string",
"type": "string"
},
{
"default_value": "0ms",
"description": "Connection idle timeout",
"mandatory": false,
"modifiable": true,
"name": "wait_timeout",
"type": "duration",
"unit": "ms"
}
],
"version": "V1.1.0"
},
"id": "readwritesplit",
"links": {
"self": "http://localhost:8989/v1/modules/readwritesplit/"
},
"type": "modules"
}
],
"links": {
"self": "http://localhost:8989/v1/maxscale/modules/"
}
}GET /v1/maxscale/modules/:module/:commandPOST /v1/maxscale/modules/:module/:commandPOST /v1/maxscale/modules/mariadbmon/reset-replication?MariaDB-Monitor&server1{
"links": {
"self": "http://localhost:8989/v1/maxscale/modules/mariadbmon/reset-replication"
},
"meta": [ // Output of module command (module dependent)
{
"name": "value"
}
]
}GET /v1/maxscale/query_classifier/classify?sql=<statement>GET /v1/maxscale/query_classifier/classify?sql=SELECT+1{
"data": {
"attributes": {
"canonical": "SELECT ?",
"fields": [],
"functions": [],
"operation": "sql::OP_SELECT",
"parse_result": "Parser::Result::PARSED",
"type_mask": "sql::TYPE_READ"
},
"id": "classify",
"type": "classify"
},
"links": {
"self": "http://localhost:8989/v1/maxscale/query_classifier/classify/"
}
}