@berthojoris/mcp-mysql-server 1.38.0 → 1.40.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +82 -0
- package/DOCUMENTATIONS.md +4 -37
- package/README.md +3 -7
- package/dist/config/featureConfig.d.ts +1 -5
- package/dist/config/featureConfig.js +2 -90
- package/dist/index.d.ts +0 -245
- package/dist/index.js +1 -246
- package/dist/mcp-server.js +0 -583
- package/package.json +2 -2
package/dist/mcp-server.js
CHANGED
|
@@ -980,70 +980,6 @@ const TOOLS = [
|
|
|
980
980
|
required: ["query"],
|
|
981
981
|
},
|
|
982
982
|
},
|
|
983
|
-
// Cache Management Tools
|
|
984
|
-
{
|
|
985
|
-
name: "get_cache_stats",
|
|
986
|
-
description: "📊 Returns query cache performance metrics: hit rate, miss rate, size, memory usage, and entry count. Use to monitor cache effectiveness and tune cache settings.",
|
|
987
|
-
inputSchema: {
|
|
988
|
-
type: "object",
|
|
989
|
-
properties: {},
|
|
990
|
-
},
|
|
991
|
-
},
|
|
992
|
-
{
|
|
993
|
-
name: "get_cache_config",
|
|
994
|
-
description: "Get current cache configuration settings.",
|
|
995
|
-
inputSchema: {
|
|
996
|
-
type: "object",
|
|
997
|
-
properties: {},
|
|
998
|
-
},
|
|
999
|
-
},
|
|
1000
|
-
{
|
|
1001
|
-
name: "configure_cache",
|
|
1002
|
-
description: "Configure cache settings including TTL, max size, and enable/disable.",
|
|
1003
|
-
inputSchema: {
|
|
1004
|
-
type: "object",
|
|
1005
|
-
properties: {
|
|
1006
|
-
enabled: {
|
|
1007
|
-
type: "boolean",
|
|
1008
|
-
description: "Enable or disable the query cache",
|
|
1009
|
-
},
|
|
1010
|
-
ttlMs: {
|
|
1011
|
-
type: "number",
|
|
1012
|
-
description: "Cache time-to-live in milliseconds (default: 60000)",
|
|
1013
|
-
},
|
|
1014
|
-
maxSize: {
|
|
1015
|
-
type: "number",
|
|
1016
|
-
description: "Maximum number of cached entries (default: 100)",
|
|
1017
|
-
},
|
|
1018
|
-
maxMemoryMB: {
|
|
1019
|
-
type: "number",
|
|
1020
|
-
description: "Maximum memory usage in MB (default: 50)",
|
|
1021
|
-
},
|
|
1022
|
-
},
|
|
1023
|
-
},
|
|
1024
|
-
},
|
|
1025
|
-
{
|
|
1026
|
-
name: "clear_cache",
|
|
1027
|
-
description: "Clear all entries from the query cache.",
|
|
1028
|
-
inputSchema: {
|
|
1029
|
-
type: "object",
|
|
1030
|
-
properties: {},
|
|
1031
|
-
},
|
|
1032
|
-
},
|
|
1033
|
-
{
|
|
1034
|
-
name: "invalidate_table_cache",
|
|
1035
|
-
description: "Invalidate all cached queries related to a specific table.",
|
|
1036
|
-
inputSchema: {
|
|
1037
|
-
type: "object",
|
|
1038
|
-
properties: {
|
|
1039
|
-
table_name: {
|
|
1040
|
-
type: "string",
|
|
1041
|
-
description: "Name of the table to invalidate cache for",
|
|
1042
|
-
},
|
|
1043
|
-
},
|
|
1044
|
-
required: ["table_name"],
|
|
1045
|
-
},
|
|
1046
|
-
},
|
|
1047
983
|
// Query Optimization Tools
|
|
1048
984
|
{
|
|
1049
985
|
name: "analyze_query",
|
|
@@ -1872,130 +1808,6 @@ const TOOLS = [
|
|
|
1872
1808
|
},
|
|
1873
1809
|
},
|
|
1874
1810
|
},
|
|
1875
|
-
// Process Management Tools
|
|
1876
|
-
{
|
|
1877
|
-
name: "show_process_list",
|
|
1878
|
-
description: "Shows all running MySQL processes/connections.",
|
|
1879
|
-
inputSchema: {
|
|
1880
|
-
type: "object",
|
|
1881
|
-
properties: {
|
|
1882
|
-
full: { type: "boolean", description: "Show full query text" },
|
|
1883
|
-
},
|
|
1884
|
-
},
|
|
1885
|
-
},
|
|
1886
|
-
{
|
|
1887
|
-
name: "kill_process",
|
|
1888
|
-
description: "Kills a MySQL process/connection by ID.",
|
|
1889
|
-
inputSchema: {
|
|
1890
|
-
type: "object",
|
|
1891
|
-
properties: {
|
|
1892
|
-
process_id: { type: "number", description: "Process ID to kill" },
|
|
1893
|
-
type: {
|
|
1894
|
-
type: "string",
|
|
1895
|
-
enum: ["CONNECTION", "QUERY"],
|
|
1896
|
-
description: "Kill connection or just query",
|
|
1897
|
-
},
|
|
1898
|
-
},
|
|
1899
|
-
required: ["process_id"],
|
|
1900
|
-
},
|
|
1901
|
-
},
|
|
1902
|
-
{
|
|
1903
|
-
name: "show_status",
|
|
1904
|
-
description: "Shows MySQL server status variables.",
|
|
1905
|
-
inputSchema: {
|
|
1906
|
-
type: "object",
|
|
1907
|
-
properties: {
|
|
1908
|
-
like: {
|
|
1909
|
-
type: "string",
|
|
1910
|
-
description: "Optional: filter pattern (e.g., 'Thread%')",
|
|
1911
|
-
},
|
|
1912
|
-
global: {
|
|
1913
|
-
type: "boolean",
|
|
1914
|
-
description: "Show global status instead of session",
|
|
1915
|
-
},
|
|
1916
|
-
},
|
|
1917
|
-
},
|
|
1918
|
-
},
|
|
1919
|
-
{
|
|
1920
|
-
name: "show_variables",
|
|
1921
|
-
description: "Shows MySQL server configuration variables.",
|
|
1922
|
-
inputSchema: {
|
|
1923
|
-
type: "object",
|
|
1924
|
-
properties: {
|
|
1925
|
-
like: {
|
|
1926
|
-
type: "string",
|
|
1927
|
-
description: "Optional: filter pattern (e.g., 'max_%')",
|
|
1928
|
-
},
|
|
1929
|
-
global: {
|
|
1930
|
-
type: "boolean",
|
|
1931
|
-
description: "Show global variables instead of session",
|
|
1932
|
-
},
|
|
1933
|
-
},
|
|
1934
|
-
},
|
|
1935
|
-
},
|
|
1936
|
-
{
|
|
1937
|
-
name: "explain_query",
|
|
1938
|
-
description: "Shows the execution plan for a query (EXPLAIN).",
|
|
1939
|
-
inputSchema: {
|
|
1940
|
-
type: "object",
|
|
1941
|
-
properties: {
|
|
1942
|
-
query: { type: "string", description: "SQL query to explain" },
|
|
1943
|
-
format: {
|
|
1944
|
-
type: "string",
|
|
1945
|
-
enum: ["TRADITIONAL", "JSON", "TREE"],
|
|
1946
|
-
description: "Output format",
|
|
1947
|
-
},
|
|
1948
|
-
analyze: {
|
|
1949
|
-
type: "boolean",
|
|
1950
|
-
description: "Actually execute the query and show real statistics",
|
|
1951
|
-
},
|
|
1952
|
-
},
|
|
1953
|
-
required: ["query"],
|
|
1954
|
-
},
|
|
1955
|
-
},
|
|
1956
|
-
{
|
|
1957
|
-
name: "show_engine_status",
|
|
1958
|
-
description: "Shows storage engine status (InnoDB by default).",
|
|
1959
|
-
inputSchema: {
|
|
1960
|
-
type: "object",
|
|
1961
|
-
properties: {
|
|
1962
|
-
engine: {
|
|
1963
|
-
type: "string",
|
|
1964
|
-
description: "Engine name (INNODB, PERFORMANCE_SCHEMA, etc.)",
|
|
1965
|
-
},
|
|
1966
|
-
},
|
|
1967
|
-
},
|
|
1968
|
-
},
|
|
1969
|
-
{
|
|
1970
|
-
name: "get_server_info",
|
|
1971
|
-
description: "Gets comprehensive MySQL server information including version, uptime, and statistics.",
|
|
1972
|
-
inputSchema: {
|
|
1973
|
-
type: "object",
|
|
1974
|
-
properties: {},
|
|
1975
|
-
},
|
|
1976
|
-
},
|
|
1977
|
-
{
|
|
1978
|
-
name: "show_binary_logs",
|
|
1979
|
-
description: "Shows binary log files on the server.",
|
|
1980
|
-
inputSchema: {
|
|
1981
|
-
type: "object",
|
|
1982
|
-
properties: {},
|
|
1983
|
-
},
|
|
1984
|
-
},
|
|
1985
|
-
{
|
|
1986
|
-
name: "show_replication_status",
|
|
1987
|
-
description: "Shows replication status (master or replica).",
|
|
1988
|
-
inputSchema: {
|
|
1989
|
-
type: "object",
|
|
1990
|
-
properties: {
|
|
1991
|
-
type: {
|
|
1992
|
-
type: "string",
|
|
1993
|
-
enum: ["MASTER", "REPLICA", "SLAVE"],
|
|
1994
|
-
description: "Which status to show",
|
|
1995
|
-
},
|
|
1996
|
-
},
|
|
1997
|
-
},
|
|
1998
|
-
},
|
|
1999
1811
|
// Backup and Restore Tools
|
|
2000
1812
|
{
|
|
2001
1813
|
name: "backup_table",
|
|
@@ -2118,319 +1930,6 @@ const TOOLS = [
|
|
|
2118
1930
|
},
|
|
2119
1931
|
},
|
|
2120
1932
|
},
|
|
2121
|
-
// Schema Versioning and Migrations Tools
|
|
2122
|
-
{
|
|
2123
|
-
name: "init_migrations_table",
|
|
2124
|
-
description: "Initialize the migrations tracking table (_schema_migrations) for schema versioning. Creates the table if it doesn't exist.",
|
|
2125
|
-
inputSchema: {
|
|
2126
|
-
type: "object",
|
|
2127
|
-
properties: {
|
|
2128
|
-
database: {
|
|
2129
|
-
type: "string",
|
|
2130
|
-
description: "Optional: specific database name",
|
|
2131
|
-
},
|
|
2132
|
-
},
|
|
2133
|
-
},
|
|
2134
|
-
},
|
|
2135
|
-
{
|
|
2136
|
-
name: "create_migration",
|
|
2137
|
-
description: "Create a new migration entry with up and down SQL. The migration will be stored as pending until applied. Requires 'ddl' permission.",
|
|
2138
|
-
inputSchema: {
|
|
2139
|
-
type: "object",
|
|
2140
|
-
properties: {
|
|
2141
|
-
name: {
|
|
2142
|
-
type: "string",
|
|
2143
|
-
description: "Name of the migration (e.g., 'add_users_table', 'add_email_column')",
|
|
2144
|
-
},
|
|
2145
|
-
up_sql: {
|
|
2146
|
-
type: "string",
|
|
2147
|
-
description: "SQL statements to apply the migration (can contain multiple statements separated by semicolons)",
|
|
2148
|
-
},
|
|
2149
|
-
down_sql: {
|
|
2150
|
-
type: "string",
|
|
2151
|
-
description: "SQL statements to rollback the migration (optional but recommended)",
|
|
2152
|
-
},
|
|
2153
|
-
description: {
|
|
2154
|
-
type: "string",
|
|
2155
|
-
description: "Optional description of what this migration does",
|
|
2156
|
-
},
|
|
2157
|
-
version: {
|
|
2158
|
-
type: "string",
|
|
2159
|
-
description: "Optional: custom version string (14 chars, e.g., '20240115120000'). Auto-generated if not provided.",
|
|
2160
|
-
},
|
|
2161
|
-
database: {
|
|
2162
|
-
type: "string",
|
|
2163
|
-
description: "Optional: specific database name",
|
|
2164
|
-
},
|
|
2165
|
-
},
|
|
2166
|
-
required: ["name", "up_sql"],
|
|
2167
|
-
},
|
|
2168
|
-
},
|
|
2169
|
-
{
|
|
2170
|
-
name: "apply_migrations",
|
|
2171
|
-
description: "Apply all pending migrations or up to a specific version. Executes migrations in version order. Requires 'ddl' permission.",
|
|
2172
|
-
inputSchema: {
|
|
2173
|
-
type: "object",
|
|
2174
|
-
properties: {
|
|
2175
|
-
target_version: {
|
|
2176
|
-
type: "string",
|
|
2177
|
-
description: "Optional: apply migrations up to this version (inclusive)",
|
|
2178
|
-
},
|
|
2179
|
-
dry_run: {
|
|
2180
|
-
type: "boolean",
|
|
2181
|
-
description: "If true, show what would be applied without executing (default: false)",
|
|
2182
|
-
},
|
|
2183
|
-
database: {
|
|
2184
|
-
type: "string",
|
|
2185
|
-
description: "Optional: specific database name",
|
|
2186
|
-
},
|
|
2187
|
-
},
|
|
2188
|
-
},
|
|
2189
|
-
},
|
|
2190
|
-
{
|
|
2191
|
-
name: "rollback_migration",
|
|
2192
|
-
description: "Rollback applied migrations. Can rollback by steps or to a specific version. Requires 'ddl' permission.",
|
|
2193
|
-
inputSchema: {
|
|
2194
|
-
type: "object",
|
|
2195
|
-
properties: {
|
|
2196
|
-
target_version: {
|
|
2197
|
-
type: "string",
|
|
2198
|
-
description: "Optional: rollback to this version (exclusive - this version will remain applied)",
|
|
2199
|
-
},
|
|
2200
|
-
steps: {
|
|
2201
|
-
type: "number",
|
|
2202
|
-
description: "Number of migrations to rollback (default: 1). Ignored if target_version is specified.",
|
|
2203
|
-
},
|
|
2204
|
-
dry_run: {
|
|
2205
|
-
type: "boolean",
|
|
2206
|
-
description: "If true, show what would be rolled back without executing (default: false)",
|
|
2207
|
-
},
|
|
2208
|
-
database: {
|
|
2209
|
-
type: "string",
|
|
2210
|
-
description: "Optional: specific database name",
|
|
2211
|
-
},
|
|
2212
|
-
},
|
|
2213
|
-
},
|
|
2214
|
-
},
|
|
2215
|
-
{
|
|
2216
|
-
name: "get_migration_status",
|
|
2217
|
-
description: "Get migration history and status. Shows all migrations with their current status, execution times, and any errors.",
|
|
2218
|
-
inputSchema: {
|
|
2219
|
-
type: "object",
|
|
2220
|
-
properties: {
|
|
2221
|
-
version: {
|
|
2222
|
-
type: "string",
|
|
2223
|
-
description: "Optional: get status of a specific version",
|
|
2224
|
-
},
|
|
2225
|
-
status: {
|
|
2226
|
-
type: "string",
|
|
2227
|
-
enum: ["pending", "applied", "failed", "rolled_back"],
|
|
2228
|
-
description: "Optional: filter by status",
|
|
2229
|
-
},
|
|
2230
|
-
limit: {
|
|
2231
|
-
type: "number",
|
|
2232
|
-
description: "Maximum number of migrations to return (default: 50)",
|
|
2233
|
-
},
|
|
2234
|
-
database: {
|
|
2235
|
-
type: "string",
|
|
2236
|
-
description: "Optional: specific database name",
|
|
2237
|
-
},
|
|
2238
|
-
},
|
|
2239
|
-
},
|
|
2240
|
-
},
|
|
2241
|
-
{
|
|
2242
|
-
name: "get_schema_version",
|
|
2243
|
-
description: "Get the current schema version (the last successfully applied migration).",
|
|
2244
|
-
inputSchema: {
|
|
2245
|
-
type: "object",
|
|
2246
|
-
properties: {
|
|
2247
|
-
database: {
|
|
2248
|
-
type: "string",
|
|
2249
|
-
description: "Optional: specific database name",
|
|
2250
|
-
},
|
|
2251
|
-
},
|
|
2252
|
-
},
|
|
2253
|
-
},
|
|
2254
|
-
{
|
|
2255
|
-
name: "validate_migrations",
|
|
2256
|
-
description: "Validate all migrations for issues such as duplicate versions, missing down_sql, checksum mismatches, or blocked migrations.",
|
|
2257
|
-
inputSchema: {
|
|
2258
|
-
type: "object",
|
|
2259
|
-
properties: {
|
|
2260
|
-
database: {
|
|
2261
|
-
type: "string",
|
|
2262
|
-
description: "Optional: specific database name",
|
|
2263
|
-
},
|
|
2264
|
-
},
|
|
2265
|
-
},
|
|
2266
|
-
},
|
|
2267
|
-
{
|
|
2268
|
-
name: "reset_failed_migration",
|
|
2269
|
-
description: "Reset a failed migration back to pending status so it can be retried. Only works for migrations in 'failed' status.",
|
|
2270
|
-
inputSchema: {
|
|
2271
|
-
type: "object",
|
|
2272
|
-
properties: {
|
|
2273
|
-
version: {
|
|
2274
|
-
type: "string",
|
|
2275
|
-
description: "Version of the failed migration to reset",
|
|
2276
|
-
},
|
|
2277
|
-
database: {
|
|
2278
|
-
type: "string",
|
|
2279
|
-
description: "Optional: specific database name",
|
|
2280
|
-
},
|
|
2281
|
-
},
|
|
2282
|
-
required: ["version"],
|
|
2283
|
-
},
|
|
2284
|
-
},
|
|
2285
|
-
{
|
|
2286
|
-
name: "generate_migration_from_diff",
|
|
2287
|
-
description: "Generate a migration by comparing two table structures. Creates up_sql to transform table2 to match table1, and down_sql to revert. Requires 'ddl' permission.",
|
|
2288
|
-
inputSchema: {
|
|
2289
|
-
type: "object",
|
|
2290
|
-
properties: {
|
|
2291
|
-
table1: {
|
|
2292
|
-
type: "string",
|
|
2293
|
-
description: "Source table (the structure to match)",
|
|
2294
|
-
},
|
|
2295
|
-
table2: {
|
|
2296
|
-
type: "string",
|
|
2297
|
-
description: "Target table (the table to be modified)",
|
|
2298
|
-
},
|
|
2299
|
-
migration_name: {
|
|
2300
|
-
type: "string",
|
|
2301
|
-
description: "Name for the generated migration",
|
|
2302
|
-
},
|
|
2303
|
-
database: {
|
|
2304
|
-
type: "string",
|
|
2305
|
-
description: "Optional: specific database name",
|
|
2306
|
-
},
|
|
2307
|
-
},
|
|
2308
|
-
required: ["table1", "table2", "migration_name"],
|
|
2309
|
-
},
|
|
2310
|
-
},
|
|
2311
|
-
// Performance Monitoring Tools
|
|
2312
|
-
{
|
|
2313
|
-
name: "get_performance_metrics",
|
|
2314
|
-
description: "📊 COMPREHENSIVE MONITORING: Returns complete MySQL performance dashboard including query stats, connection pool, buffer pool efficiency, InnoDB metrics, and disk I/O. Use for performance troubleshooting or health checks.",
|
|
2315
|
-
inputSchema: {
|
|
2316
|
-
type: "object",
|
|
2317
|
-
properties: {},
|
|
2318
|
-
},
|
|
2319
|
-
},
|
|
2320
|
-
{
|
|
2321
|
-
name: "get_top_queries_by_time",
|
|
2322
|
-
description: "Get the top queries ordered by total execution time. Useful for identifying slow queries.",
|
|
2323
|
-
inputSchema: {
|
|
2324
|
-
type: "object",
|
|
2325
|
-
properties: {
|
|
2326
|
-
limit: {
|
|
2327
|
-
type: "number",
|
|
2328
|
-
description: "Maximum number of queries to return (default: 10, max: 100)",
|
|
2329
|
-
},
|
|
2330
|
-
},
|
|
2331
|
-
},
|
|
2332
|
-
},
|
|
2333
|
-
{
|
|
2334
|
-
name: "get_top_queries_by_count",
|
|
2335
|
-
description: "Get the top queries ordered by execution count. Useful for identifying frequently executed queries.",
|
|
2336
|
-
inputSchema: {
|
|
2337
|
-
type: "object",
|
|
2338
|
-
properties: {
|
|
2339
|
-
limit: {
|
|
2340
|
-
type: "number",
|
|
2341
|
-
description: "Maximum number of queries to return (default: 10, max: 100)",
|
|
2342
|
-
},
|
|
2343
|
-
},
|
|
2344
|
-
},
|
|
2345
|
-
},
|
|
2346
|
-
{
|
|
2347
|
-
name: "get_slow_queries",
|
|
2348
|
-
description: "Get queries that exceed a specified execution time threshold.",
|
|
2349
|
-
inputSchema: {
|
|
2350
|
-
type: "object",
|
|
2351
|
-
properties: {
|
|
2352
|
-
limit: {
|
|
2353
|
-
type: "number",
|
|
2354
|
-
description: "Maximum number of queries to return (default: 10, max: 100)",
|
|
2355
|
-
},
|
|
2356
|
-
threshold_seconds: {
|
|
2357
|
-
type: "number",
|
|
2358
|
-
description: "Execution time threshold in seconds (default: 1)",
|
|
2359
|
-
},
|
|
2360
|
-
},
|
|
2361
|
-
},
|
|
2362
|
-
},
|
|
2363
|
-
{
|
|
2364
|
-
name: "get_table_io_stats",
|
|
2365
|
-
description: "Get I/O statistics for tables including read/write operations and timings.",
|
|
2366
|
-
inputSchema: {
|
|
2367
|
-
type: "object",
|
|
2368
|
-
properties: {
|
|
2369
|
-
limit: {
|
|
2370
|
-
type: "number",
|
|
2371
|
-
description: "Maximum number of tables to return (default: 20, max: 100)",
|
|
2372
|
-
},
|
|
2373
|
-
table_schema: {
|
|
2374
|
-
type: "string",
|
|
2375
|
-
description: "Filter by specific database schema",
|
|
2376
|
-
},
|
|
2377
|
-
},
|
|
2378
|
-
},
|
|
2379
|
-
},
|
|
2380
|
-
{
|
|
2381
|
-
name: "get_index_usage_stats",
|
|
2382
|
-
description: "Get index usage statistics showing how often each index is used.",
|
|
2383
|
-
inputSchema: {
|
|
2384
|
-
type: "object",
|
|
2385
|
-
properties: {
|
|
2386
|
-
limit: {
|
|
2387
|
-
type: "number",
|
|
2388
|
-
description: "Maximum number of indexes to return (default: 20, max: 100)",
|
|
2389
|
-
},
|
|
2390
|
-
table_schema: {
|
|
2391
|
-
type: "string",
|
|
2392
|
-
description: "Filter by specific database schema",
|
|
2393
|
-
},
|
|
2394
|
-
},
|
|
2395
|
-
},
|
|
2396
|
-
},
|
|
2397
|
-
{
|
|
2398
|
-
name: "get_unused_indexes",
|
|
2399
|
-
description: "Identify indexes that are not being used by queries. These may be candidates for removal to improve write performance.",
|
|
2400
|
-
inputSchema: {
|
|
2401
|
-
type: "object",
|
|
2402
|
-
properties: {
|
|
2403
|
-
table_schema: {
|
|
2404
|
-
type: "string",
|
|
2405
|
-
description: "Filter by specific database schema",
|
|
2406
|
-
},
|
|
2407
|
-
},
|
|
2408
|
-
},
|
|
2409
|
-
},
|
|
2410
|
-
{
|
|
2411
|
-
name: "get_connection_pool_stats",
|
|
2412
|
-
description: "Get connection pool statistics including current connections, max usage, configuration, and health indicators.",
|
|
2413
|
-
inputSchema: {
|
|
2414
|
-
type: "object",
|
|
2415
|
-
properties: {},
|
|
2416
|
-
},
|
|
2417
|
-
},
|
|
2418
|
-
{
|
|
2419
|
-
name: "get_database_health_check",
|
|
2420
|
-
description: "Perform a comprehensive health check of the database including connection usage, buffer pool efficiency, aborted connections, and slow queries.",
|
|
2421
|
-
inputSchema: {
|
|
2422
|
-
type: "object",
|
|
2423
|
-
properties: {},
|
|
2424
|
-
},
|
|
2425
|
-
},
|
|
2426
|
-
{
|
|
2427
|
-
name: "reset_performance_stats",
|
|
2428
|
-
description: "Reset performance schema statistics. This clears query digest statistics, table I/O stats, and index usage stats. Requires 'utility' permission.",
|
|
2429
|
-
inputSchema: {
|
|
2430
|
-
type: "object",
|
|
2431
|
-
properties: {},
|
|
2432
|
-
},
|
|
2433
|
-
},
|
|
2434
1933
|
{
|
|
2435
1934
|
name: "create_fulltext_index",
|
|
2436
1935
|
description: "Creates a FULLTEXT index on one or more text columns in a table. Supports ngram and mecab parsers for advanced text search capabilities (useful for languages like Chinese, Japanese, Korean). Use this to enable full-text search on text columns.",
|
|
@@ -2767,22 +2266,6 @@ server.setRequestHandler(types_js_1.CallToolRequestSchema, async (request) => {
|
|
|
2767
2266
|
case "export_table_to_csv":
|
|
2768
2267
|
result = await mysqlMCP.exportTableToCSV((args || {}));
|
|
2769
2268
|
break;
|
|
2770
|
-
// Cache Management Tools
|
|
2771
|
-
case "get_cache_stats":
|
|
2772
|
-
result = mysqlMCP.getCacheStats();
|
|
2773
|
-
break;
|
|
2774
|
-
case "get_cache_config":
|
|
2775
|
-
result = mysqlMCP.getCacheConfig();
|
|
2776
|
-
break;
|
|
2777
|
-
case "configure_cache":
|
|
2778
|
-
result = mysqlMCP.configureCacheSettings((args || {}));
|
|
2779
|
-
break;
|
|
2780
|
-
case "clear_cache":
|
|
2781
|
-
result = mysqlMCP.clearCache();
|
|
2782
|
-
break;
|
|
2783
|
-
case "invalidate_table_cache":
|
|
2784
|
-
result = mysqlMCP.invalidateCacheForTable((args || {}));
|
|
2785
|
-
break;
|
|
2786
2269
|
// Query Optimization Tools
|
|
2787
2270
|
case "analyze_query":
|
|
2788
2271
|
result = mysqlMCP.analyzeQuery((args || {}));
|
|
@@ -2907,72 +2390,6 @@ server.setRequestHandler(types_js_1.CallToolRequestSchema, async (request) => {
|
|
|
2907
2390
|
case "get_table_size":
|
|
2908
2391
|
result = await mysqlMCP.getTableSize((args || {}));
|
|
2909
2392
|
break;
|
|
2910
|
-
// Process Management Tools
|
|
2911
|
-
case "show_process_list":
|
|
2912
|
-
result = await mysqlMCP.showProcessList((args || {}));
|
|
2913
|
-
break;
|
|
2914
|
-
case "kill_process":
|
|
2915
|
-
result = await mysqlMCP.killProcess((args || {}));
|
|
2916
|
-
break;
|
|
2917
|
-
case "show_status":
|
|
2918
|
-
result = await mysqlMCP.showStatus((args || {}));
|
|
2919
|
-
break;
|
|
2920
|
-
case "show_variables":
|
|
2921
|
-
result = await mysqlMCP.showVariables((args || {}));
|
|
2922
|
-
break;
|
|
2923
|
-
case "explain_query":
|
|
2924
|
-
result = await mysqlMCP.explainQuery((args || {}));
|
|
2925
|
-
break;
|
|
2926
|
-
// Schema Versioning and Migrations Tools
|
|
2927
|
-
case "init_migrations_table":
|
|
2928
|
-
result = await mysqlMCP.initMigrationsTable((args || {}));
|
|
2929
|
-
break;
|
|
2930
|
-
case "create_migration":
|
|
2931
|
-
result = await mysqlMCP.createMigration((args || {}));
|
|
2932
|
-
break;
|
|
2933
|
-
case "apply_migrations":
|
|
2934
|
-
result = await mysqlMCP.applyMigrations((args || {}));
|
|
2935
|
-
break;
|
|
2936
|
-
case "rollback_migration":
|
|
2937
|
-
result = await mysqlMCP.rollbackMigration((args || {}));
|
|
2938
|
-
break;
|
|
2939
|
-
case "get_migration_status":
|
|
2940
|
-
result = await mysqlMCP.getMigrationStatus((args || {}));
|
|
2941
|
-
break;
|
|
2942
|
-
case "get_schema_version":
|
|
2943
|
-
result = await mysqlMCP.getSchemaVersion((args || {}));
|
|
2944
|
-
break;
|
|
2945
|
-
case "validate_migrations":
|
|
2946
|
-
result = await mysqlMCP.validateMigrations((args || {}));
|
|
2947
|
-
break;
|
|
2948
|
-
case "reset_failed_migration":
|
|
2949
|
-
result = await mysqlMCP.resetFailedMigration((args || {}));
|
|
2950
|
-
break;
|
|
2951
|
-
case "generate_migration_from_diff":
|
|
2952
|
-
result = await mysqlMCP.generateMigrationFromDiff((args || {}));
|
|
2953
|
-
break;
|
|
2954
|
-
// Performance Monitoring Tools
|
|
2955
|
-
case "get_performance_metrics":
|
|
2956
|
-
result = await mysqlMCP.getPerformanceMetrics();
|
|
2957
|
-
break;
|
|
2958
|
-
case "get_table_io_stats":
|
|
2959
|
-
result = await mysqlMCP.getTableIOStats((args || {}));
|
|
2960
|
-
break;
|
|
2961
|
-
case "get_index_usage_stats":
|
|
2962
|
-
result = await mysqlMCP.getIndexUsageStats((args || {}));
|
|
2963
|
-
break;
|
|
2964
|
-
case "get_unused_indexes":
|
|
2965
|
-
result = await mysqlMCP.getUnusedIndexes((args || {}));
|
|
2966
|
-
break;
|
|
2967
|
-
case "get_connection_pool_stats":
|
|
2968
|
-
result = await mysqlMCP.getConnectionPoolStats();
|
|
2969
|
-
break;
|
|
2970
|
-
case "get_database_health_check":
|
|
2971
|
-
result = await mysqlMCP.getDatabaseHealthCheck();
|
|
2972
|
-
break;
|
|
2973
|
-
case "reset_performance_stats":
|
|
2974
|
-
result = await mysqlMCP.resetPerformanceStats();
|
|
2975
|
-
break;
|
|
2976
2393
|
case "repair_query":
|
|
2977
2394
|
result = await mysqlMCP.repairQuery((args || {}));
|
|
2978
2395
|
break;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@berthojoris/mcp-mysql-server",
|
|
3
|
-
"version": "1.
|
|
4
|
-
"description": "Model Context Protocol server for MySQL database integration with dynamic per-project permissions, backup/restore
|
|
3
|
+
"version": "1.40.0",
|
|
4
|
+
"description": "Model Context Protocol server for MySQL database integration with dynamic per-project permissions, backup/restore capabilities",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
7
7
|
"type": "commonjs",
|