| 1 | { |
| 2 | "jsonSchema": { |
| 3 | "$schema": "http://json-schema.org/draft-07/schema#", |
| 4 | "title": "MySQL collector configuration.", |
| 5 | "type": "object", |
| 6 | "properties": { |
| 7 | "update_every": { |
| 8 | "title": "Update every", |
| 9 | "description": "Data collection interval, measured in seconds.", |
| 10 | "type": "integer", |
| 11 | "minimum": 1, |
| 12 | "default": 1 |
| 13 | }, |
| 14 | "autodetection_retry": { |
| 15 | "title": "Detection retry", |
| 16 | "description": "Recheck interval in seconds. Zero means no recheck will be scheduled.", |
| 17 | "type": "integer", |
| 18 | "minimum": 0, |
| 19 | "default": 60 |
| 20 | }, |
| 21 | "dsn": { |
| 22 | "title": "DSN", |
| 23 | "description": "MySQL server [Data Source Name (DSN)](https://github.com/go-sql-driver/mysql#dsn-data-source-name) specifying the connection details.", |
| 24 | "type": "string", |
| 25 | "default": "netdata@tcp(localhost:3306)/" |
| 26 | }, |
| 27 | "timeout": { |
| 28 | "title": "Timeout", |
| 29 | "description": "Timeout for queries, in seconds.", |
| 30 | "type": "number", |
| 31 | "minimum": 0.5, |
| 32 | "default": 1 |
| 33 | }, |
| 34 | "my.cnf": { |
| 35 | "title": "my.cnf path", |
| 36 | "description": "Optional. Specifies the path to the my.cnf file containing connection settings under the [client] section.", |
| 37 | "type": "string" |
| 38 | }, |
| 39 | "vnode": { |
| 40 | "title": "Vnode", |
| 41 | "description": "Associates this data collection job with a [Virtual Node](https://learn.netdata.cloud/docs/netdata-agent/configuration/organize-systems-metrics-and-alerts#virtual-nodes).", |
| 42 | "type": "string" |
| 43 | }, |
| 44 | "functions": { |
| 45 | "title": "Functions", |
| 46 | "description": "Configuration for Netdata functions exposed by this collector.", |
| 47 | "type": "object", |
| 48 | "properties": { |
| 49 | "top_queries": { |
| 50 | "title": "Top Queries", |
| 51 | "description": "Configuration for the top-queries function.", |
| 52 | "type": "object", |
| 53 | "properties": { |
| 54 | "disabled": { |
| 55 | "title": "Disabled", |
| 56 | "description": "Disable the top-queries function.", |
| 57 | "type": "boolean", |
| 58 | "default": false |
| 59 | }, |
| 60 | "timeout": { |
| 61 | "title": "Timeout", |
| 62 | "description": "Query timeout in seconds. Set to 0 to use the collector's timeout.", |
| 63 | "type": "number", |
| 64 | "minimum": 0 |
| 65 | }, |
| 66 | "limit": { |
| 67 | "title": "Limit", |
| 68 | "description": "Maximum number of queries to return. Set to 0 to use the default (500).", |
| 69 | "type": "integer", |
| 70 | "minimum": 0, |
| 71 | "maximum": 5000, |
| 72 | "default": 500 |
| 73 | } |
| 74 | } |
| 75 | }, |
| 76 | "deadlock_info": { |
| 77 | "title": "Deadlock Info", |
| 78 | "description": "Configuration for the deadlock-info function.", |
| 79 | "type": "object", |
| 80 | "properties": { |
| 81 | "disabled": { |
| 82 | "title": "Disabled", |
| 83 | "description": "Disable the deadlock-info function.", |
| 84 | "type": "boolean", |
| 85 | "default": false |
| 86 | }, |
| 87 | "timeout": { |
| 88 | "title": "Timeout", |
| 89 | "description": "Query timeout in seconds. Set to 0 to use the collector's timeout.", |
| 90 | "type": "number", |
| 91 | "minimum": 0 |
| 92 | } |
| 93 | } |
| 94 | }, |
| 95 | "error_info": { |
| 96 | "title": "Error Info", |
| 97 | "description": "Configuration for the error-info function.", |
| 98 | "type": "object", |
| 99 | "properties": { |
| 100 | "disabled": { |
| 101 | "title": "Disabled", |
| 102 | "description": "Disable the error-info function.", |
| 103 | "type": "boolean", |
| 104 | "default": false |
| 105 | }, |
| 106 | "timeout": { |
| 107 | "title": "Timeout", |
| 108 | "description": "Query timeout in seconds. Set to 0 to use the collector's timeout.", |
| 109 | "type": "number", |
| 110 | "minimum": 0 |
| 111 | } |
| 112 | } |
| 113 | } |
| 114 | } |
| 115 | } |
| 116 | }, |
| 117 | "required": [ |
| 118 | "dsn" |
| 119 | ] |
| 120 | }, |
| 121 | "uiSchema": { |
| 122 | "uiOptions": { |
| 123 | "fullPage": true |
| 124 | }, |
| 125 | "vnode": { |
| 126 | "ui:placeholder": "To use this option, first create a Virtual Node and then reference its name here." |
| 127 | }, |
| 128 | "autodetection_retry": { |
| 129 | "ui:help": "This option determines how frequently (in seconds) Netdata will retry data collection jobs that failed initially, with the value of 60 meaning it retries to start data collection jobs every 60 seconds, while setting it to 0 disables this retry mechanism entirely." |
| 130 | }, |
| 131 | "dsn": { |
| 132 | "ui:placeholder": "username:password@protocol(address)/dbname" |
| 133 | }, |
| 134 | "timeout": { |
| 135 | "ui:help": "Accepts decimals for precise control (e.g., type 1.5 for 1.5 seconds)." |
| 136 | }, |
| 137 | "functions": { |
| 138 | "top_queries": { |
| 139 | "disabled": { |
| 140 | "ui:help": "WARNING: Query text may contain unmasked sensitive literals (PII)." |
| 141 | } |
| 142 | }, |
| 143 | "deadlock_info": { |
| 144 | "disabled": { |
| 145 | "ui:help": "WARNING: Query text may contain unmasked sensitive literals. Requires PROCESS privilege." |
| 146 | } |
| 147 | }, |
| 148 | "error_info": { |
| 149 | "disabled": { |
| 150 | "ui:help": "WARNING: Error messages and query text may contain unmasked sensitive literals." |
| 151 | } |
| 152 | } |
| 153 | }, |
| 154 | "ui:flavour": "tabs", |
| 155 | "ui:options": { |
| 156 | "tabs": [ |
| 157 | { |
| 158 | "title": "Base", |
| 159 | "fields": [ |
| 160 | "update_every", |
| 161 | "dsn", |
| 162 | "timeout", |
| 163 | "my.cnf", |
| 164 | "vnode", |
| 165 | "autodetection_retry" |
| 166 | ] |
| 167 | }, |
| 168 | { |
| 169 | "title": "Functions", |
| 170 | "fields": [ |
| 171 | "functions" |
| 172 | ] |
| 173 | } |
| 174 | ] |
| 175 | } |
| 176 | } |
| 177 | } |