github.com/whtcorpsinc/MilevaDB-Prod@v0.0.0-20211104133533-f57f4be3b597/schemareplicant/metric_table_def.go (about)

     1  // Copyright 2020 WHTCORPS INC, Inc.
     2  //
     3  // Licensed under the Apache License, Version 2.0 (the "License");
     4  // you may not use this file except in compliance with the License.
     5  // You may obtain a copy of the License at
     6  //
     7  //     http://www.apache.org/licenses/LICENSE-2.0
     8  //
     9  // Unless required by applicable law or agreed to in writing, software
    10  // distributed under the License is distributed on an "AS IS" BASIS,
    11  // See the License for the specific language governing permissions and
    12  // limitations under the License.
    13  
    14  package schemareplicant
    15  
    16  // MetricBlockMap records the metric causet definition, export for test.
    17  // TODO: read from system causet.
    18  var MetricBlockMap = map[string]MetricBlockDef{
    19  	"milevadb_query_duration": {
    20  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(milevadb_server_handle_query_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,sql_type,instance))`,
    21  		Labels:   []string{"instance", "sql_type"},
    22  		Quantile: 0.90,
    23  		Comment:  "The quantile of MilevaDB query durations(second)",
    24  	},
    25  	"milevadb_qps": {
    26  		PromQL:  `sum(rate(milevadb_server_query_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (result,type,instance)`,
    27  		Labels:  []string{"instance", "type", "result"},
    28  		Comment: "MilevaDB query processing numbers per second",
    29  	},
    30  	"milevadb_qps_ideal": {
    31  		PromQL: `sum(milevadb_server_connections) * sum(rate(milevadb_server_handle_query_duration_seconds_count[$RANGE_DURATION])) / sum(rate(milevadb_server_handle_query_duration_seconds_sum[$RANGE_DURATION]))`,
    32  	},
    33  	"milevadb_ops_memex": {
    34  		PromQL:  `sum(rate(milevadb_interlock_memex_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)`,
    35  		Labels:  []string{"instance", "type"},
    36  		Comment: "MilevaDB memex statistics",
    37  	},
    38  	"milevadb_failed_query_opm": {
    39  		PromQL:  `sum(increase(milevadb_server_execute_error_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type, instance)`,
    40  		Labels:  []string{"instance", "type"},
    41  		Comment: "MilevaDB failed query opm",
    42  	},
    43  	"milevadb_slow_query_duration": {
    44  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_server_slow_query_process_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
    45  		Labels:   []string{"instance"},
    46  		Quantile: 0.90,
    47  		Comment:  "The quantile of MilevaDB slow query statistics with slow query time(second)",
    48  	},
    49  	"milevadb_slow_query_cop_process_duration": {
    50  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_server_slow_query_cop_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
    51  		Labels:   []string{"instance"},
    52  		Quantile: 0.90,
    53  		Comment:  "The quantile of MilevaDB slow query statistics with slow query total cop process time(second)",
    54  	},
    55  	"milevadb_slow_query_cop_wait_duration": {
    56  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_server_slow_query_wait_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
    57  		Labels:   []string{"instance"},
    58  		Quantile: 0.90,
    59  		Comment:  "The quantile of MilevaDB slow query statistics with slow query total cop wait time(second)",
    60  	},
    61  	"milevadb_ops_internal": {
    62  		PromQL:  "sum(rate(milevadb_stochastik_restricted_sql_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
    63  		Labels:  []string{"instance"},
    64  		Comment: "MilevaDB internal ALLEGROALLEGROSQL is used by MilevaDB itself.",
    65  	},
    66  	"milevadb_process_mem_usage": {
    67  		PromQL:  "process_resident_memory_bytes{$LABEL_CONDITIONS}",
    68  		Labels:  []string{"instance", "job"},
    69  		Comment: "process rss memory usage",
    70  	},
    71  	"go_heap_mem_usage": {
    72  		PromQL:  "go_memstats_heap_alloc_bytes{$LABEL_CONDITIONS}",
    73  		Labels:  []string{"instance", "job"},
    74  		Comment: "MilevaDB heap memory size in use",
    75  	},
    76  	"process_cpu_usage": {
    77  		PromQL: "rate(process_cpu_seconds_total{$LABEL_CONDITIONS}[$RANGE_DURATION])",
    78  		Labels: []string{"instance", "job"},
    79  	},
    80  	"milevadb_connection_count": {
    81  		PromQL:  "milevadb_server_connections{$LABEL_CONDITIONS}",
    82  		Labels:  []string{"instance"},
    83  		Comment: "MilevaDB current connection counts",
    84  	},
    85  	"node_process_open_fd_count": {
    86  		PromQL:  "process_open_fds{$LABEL_CONDITIONS}",
    87  		Labels:  []string{"instance", "job"},
    88  		Comment: "Process opened file descriptors count",
    89  	},
    90  	"goroutines_count": {
    91  		PromQL:  " go_goroutines{$LABEL_CONDITIONS}",
    92  		Labels:  []string{"instance", "job"},
    93  		Comment: "Process current goroutines count)",
    94  	},
    95  	"go_gc_duration": {
    96  		PromQL:  "rate(go_gc_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])",
    97  		Labels:  []string{"instance", "job"},
    98  		Comment: "Go garbage defCauslection STW pause duration(second)",
    99  	},
   100  	"go_threads": {
   101  		PromQL:  "go_threads{$LABEL_CONDITIONS}",
   102  		Labels:  []string{"instance", "job"},
   103  		Comment: "Total threads MilevaDB/FIDel process created currently",
   104  	},
   105  	"go_gc_count": {
   106  		PromQL:  " rate(go_gc_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])",
   107  		Labels:  []string{"instance", "job"},
   108  		Comment: "The Go garbage defCauslection counts per second",
   109  	},
   110  	"go_gc_cpu_usage": {
   111  		PromQL:  "go_memstats_gc_cpu_fraction{$LABEL_CONDITIONS}",
   112  		Labels:  []string{"instance", "job"},
   113  		Comment: "The fraction of MilevaDB/FIDel available CPU time used by the GC since the program started.",
   114  	},
   115  	"milevadb_event_opm": {
   116  		PromQL:  "increase(milevadb_server_event_total{$LABEL_CONDITIONS}[$RANGE_DURATION])",
   117  		Labels:  []string{"instance", "type"},
   118  		Comment: "MilevaDB Server critical events total, including start/close/shutdown/hang etc",
   119  	},
   120  	"milevadb_keep_alive_opm": {
   121  		PromQL:  "sum(increase(milevadb_monitor_keep_alive_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   122  		Labels:  []string{"instance"},
   123  		Comment: "MilevaDB instance monitor average keep alive times",
   124  	},
   125  	"milevadb_prepared_memex_count": {
   126  		PromQL:  "milevadb_server_prepared_stmts{$LABEL_CONDITIONS}",
   127  		Labels:  []string{"instance"},
   128  		Comment: "MilevaDB prepare memexs count",
   129  	},
   130  	"milevadb_time_jump_back_ops": {
   131  		PromQL:  "sum(increase(milevadb_monitor_time_jump_back_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   132  		Labels:  []string{"instance"},
   133  		Comment: "MilevaDB monitor time jump back count",
   134  	},
   135  	"milevadb_panic_count": {
   136  		Comment: "MilevaDB instance panic count",
   137  		PromQL:  "increase(milevadb_server_panic_total{$LABEL_CONDITIONS}[$RANGE_DURATION])",
   138  		Labels:  []string{"instance"},
   139  	},
   140  	"milevadb_panic_count_total_count": {
   141  		Comment: "The total count of MilevaDB instance panic",
   142  		PromQL:  "sum(increase(milevadb_server_panic_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   143  		Labels:  []string{"instance"},
   144  	},
   145  	"milevadb_binlog_error_count": {
   146  		Comment: "MilevaDB write binlog error, skip binlog count",
   147  		PromQL:  "milevadb_server_critical_error_total{$LABEL_CONDITIONS}",
   148  		Labels:  []string{"instance"},
   149  	},
   150  	"milevadb_binlog_error_total_count": {
   151  		PromQL:  "sum(increase(milevadb_server_critical_error_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   152  		Labels:  []string{"instance"},
   153  		Comment: "The total count of MilevaDB write binlog error and skip binlog",
   154  	},
   155  	"milevadb_get_token_duration": {
   156  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_server_get_token_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
   157  		Labels:   []string{"instance"},
   158  		Quantile: 0.99,
   159  		Comment:  " The quantile of Duration (us) for getting token, it should be small until concurrency limit is reached(microsecond)",
   160  	},
   161  	"milevadb_handshake_error_opm": {
   162  		PromQL:  "sum(increase(milevadb_server_handshake_error_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   163  		Labels:  []string{"instance"},
   164  		Comment: "The OPM of MilevaDB processing handshake error",
   165  	},
   166  	"milevadb_handshake_error_total_count": {
   167  		PromQL:  "sum(increase(milevadb_server_handshake_error_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   168  		Labels:  []string{"instance"},
   169  		Comment: "The total count of MilevaDB processing handshake error",
   170  	},
   171  
   172  	"milevadb_transaction_ops": {
   173  		PromQL:  "sum(rate(milevadb_stochastik_transaction_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,sql_type,instance)",
   174  		Labels:  []string{"instance", "type", "sql_type"},
   175  		Comment: "MilevaDB transaction processing counts by type and source. Internal means MilevaDB inner transaction calls",
   176  	},
   177  	"milevadb_transaction_duration": {
   178  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_stochastik_transaction_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,sql_type,instance))",
   179  		Labels:   []string{"instance", "type", "sql_type"},
   180  		Quantile: 0.95,
   181  		Comment:  "The quantile of transaction execution durations, including retry(second)",
   182  	},
   183  	"milevadb_transaction_retry_num": {
   184  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_stochastik_retry_num_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
   185  		Labels:   []string{"instance"},
   186  		Comment:  "The quantile of MilevaDB transaction retry num",
   187  		Quantile: 0.95,
   188  	},
   189  	"milevadb_transaction_memex_num": {
   190  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_stochastik_transaction_memex_num_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,sql_type))",
   191  		Labels:   []string{"instance", "sql_type"},
   192  		Comment:  "The quantile of MilevaDB memexs numbers within one transaction. Internal means MilevaDB inner transaction",
   193  		Quantile: 0.95,
   194  	},
   195  	"milevadb_transaction_retry_error_ops": {
   196  		PromQL:  "sum(rate(milevadb_stochastik_retry_error_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,sql_type,instance)",
   197  		Labels:  []string{"instance", "type", "sql_type"},
   198  		Comment: "Error numbers of transaction retry",
   199  	},
   200  	"milevadb_transaction_retry_error_total_count": {
   201  		PromQL:  "sum(increase(milevadb_stochastik_retry_error_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,sql_type,instance)",
   202  		Labels:  []string{"instance", "type", "sql_type"},
   203  		Comment: "The total count of transaction retry",
   204  	},
   205  	"milevadb_transaction_local_latch_wait_duration": {
   206  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_local_latch_wait_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
   207  		Labels:   []string{"instance"},
   208  		Comment:  "The quantile of MilevaDB transaction latch wait time on key value storage(second)",
   209  		Quantile: 0.95,
   210  	},
   211  	"milevadb_parse_duration": {
   212  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_stochastik_parse_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,sql_type,instance))",
   213  		Labels:   []string{"instance", "sql_type"},
   214  		Quantile: 0.95,
   215  		Comment:  "The quantile time cost of parsing ALLEGROALLEGROSQL to AST(second)",
   216  	},
   217  	"milevadb_compile_duration": {
   218  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_stochastik_compile_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, sql_type,instance))",
   219  		Labels:   []string{"instance", "sql_type"},
   220  		Quantile: 0.95,
   221  		Comment:  "The quantile time cost of building the query plan(second)",
   222  	},
   223  	"milevadb_execute_duration": {
   224  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_stochastik_execute_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, sql_type, instance))",
   225  		Labels:   []string{"instance", "sql_type"},
   226  		Quantile: 0.95,
   227  		Comment:  "The quantile time cost of executing the ALLEGROALLEGROSQL which does not include the time to get the results of the query(second)",
   228  	},
   229  	"milevadb_expensive_interlocks_ops": {
   230  		Comment: "MilevaDB interlocks using more cpu and memory resources",
   231  		PromQL:  "sum(rate(milevadb_interlock_expensive_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   232  		Labels:  []string{"instance", "type"},
   233  	},
   234  	"milevadb_query_using_plan_cache_ops": {
   235  		PromQL:  "sum(rate(milevadb_server_plan_cache_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   236  		Labels:  []string{"instance", "type"},
   237  		Comment: "MilevaDB plan cache hit ops",
   238  	},
   239  	"milevadb_allegrosql_execution_duration": {
   240  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_allegrosql_handle_query_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, type, instance))",
   241  		Labels:   []string{"instance", "type"},
   242  		Quantile: 0.95,
   243  		Comment:  "The quantile durations of allegrosql execution(second)",
   244  	},
   245  	"milevadb_allegrosql_qps": {
   246  		PromQL:  "sum(rate(milevadb_allegrosql_handle_query_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))",
   247  		Labels:  []string{"instance", "type"},
   248  		Comment: "allegrosql query handling durations per second",
   249  	},
   250  	"milevadb_allegrosql_partial_qps": {
   251  		PromQL:  "sum(rate(milevadb_allegrosql_scan_keys_partial_num_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))",
   252  		Labels:  []string{"instance"},
   253  		Comment: "the numebr of allegrosql partial scan numbers",
   254  	},
   255  	"milevadb_allegrosql_scan_key_num": {
   256  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_allegrosql_scan_keys_num_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
   257  		Labels:   []string{"instance"},
   258  		Quantile: 0.95,
   259  		Comment:  "The quantile numebr of allegrosql scan numbers",
   260  	},
   261  	"milevadb_allegrosql_partial_scan_key_num": {
   262  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_allegrosql_scan_keys_partial_num_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
   263  		Labels:   []string{"instance"},
   264  		Quantile: 0.95,
   265  		Comment:  "The quantile numebr of allegrosql partial scan key numbers",
   266  	},
   267  	"milevadb_allegrosql_partial_num": {
   268  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_allegrosql_partial_num_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
   269  		Labels:   []string{"instance"},
   270  		Quantile: 0.95,
   271  		Comment:  "The quantile of allegrosql partial numbers per query",
   272  	},
   273  	"milevadb_cop_duration": {
   274  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_cop_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance))",
   275  		Labels:   []string{"instance"},
   276  		Quantile: 0.95,
   277  		Comment:  "The quantile of ekv storage interlock processing durations",
   278  	},
   279  	"milevadb_ekv_backoff_duration": {
   280  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_backoff_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,instance))",
   281  		Labels:   []string{"instance", "type"},
   282  		Quantile: 0.95,
   283  		Comment:  "The quantile of ekv backoff time durations(second)",
   284  	},
   285  	"milevadb_ekv_backoff_ops": {
   286  		PromQL:  "sum(rate(milevadb_einsteindbclient_backoff_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   287  		Labels:  []string{"instance", "type"},
   288  		Comment: "ekv storage backoff times",
   289  	},
   290  	"milevadb_ekv_region_error_ops": {
   291  		PromQL:  "sum(rate(milevadb_einsteindbclient_region_err_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   292  		Labels:  []string{"instance", "type"},
   293  		Comment: "ekv region error times",
   294  	},
   295  	"milevadb_ekv_region_error_total_count": {
   296  		PromQL:  "sum(increase(milevadb_einsteindbclient_region_err_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   297  		Labels:  []string{"instance", "type"},
   298  		Comment: "The total count of ekv region error",
   299  	},
   300  	"milevadb_lock_resolver_ops": {
   301  		PromQL:  "sum(rate(milevadb_einsteindbclient_lock_resolver_actions_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   302  		Labels:  []string{"instance", "type"},
   303  		Comment: "dagger resolve times",
   304  	},
   305  	"milevadb_lock_resolver_total_num": {
   306  		PromQL:  "sum(increase(milevadb_einsteindbclient_lock_resolver_actions_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   307  		Labels:  []string{"instance", "type"},
   308  		Comment: "The total number of dagger resolve",
   309  	},
   310  	"milevadb_lock_cleanup_fail_ops": {
   311  		PromQL:  "sum(rate(milevadb_einsteindbclient_lock_cleanup_task_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   312  		Labels:  []string{"instance", "type"},
   313  		Comment: "dagger cleanup failed ops",
   314  	},
   315  	"milevadb_load_safepoint_fail_ops": {
   316  		PromQL:  "sum(rate(milevadb_einsteindbclient_load_safepoint_total{$LABEL_CONDITIONS}[$RANGE_DURATION]))",
   317  		Labels:  []string{"instance", "type"},
   318  		Comment: "safe point uFIDelate ops",
   319  	},
   320  	"milevadb_ekv_request_ops": {
   321  		Comment: "ekv request total by instance and command type",
   322  		PromQL:  "sum(rate(milevadb_einsteindbclient_request_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, type)",
   323  		Labels:  []string{"instance", "type"},
   324  	},
   325  	"milevadb_ekv_request_duration": {
   326  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_request_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,causetstore,instance))",
   327  		Labels:   []string{"instance", "type", "causetstore"},
   328  		Quantile: 0.95,
   329  		Comment:  "The quantile of ekv requests durations by causetstore",
   330  	},
   331  	"milevadb_ekv_txn_ops": {
   332  		Comment: "MilevaDB total ekv transaction counts",
   333  		PromQL:  "sum(rate(milevadb_einsteindbclient_txn_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   334  		Labels:  []string{"instance"},
   335  	},
   336  	"milevadb_ekv_write_num": {
   337  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_txn_write_ekv_num_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance))",
   338  		Labels:   []string{"instance"},
   339  		Quantile: 1,
   340  		Comment:  "The quantile of ekv write count per transaction execution",
   341  	},
   342  	"milevadb_ekv_write_size": {
   343  		Comment:  "The quantile of ekv write size per transaction execution",
   344  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_txn_write_size_bytes_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance))",
   345  		Labels:   []string{"instance"},
   346  		Quantile: 1,
   347  	},
   348  	"milevadb_txn_region_num": {
   349  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_txn_regions_num_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance))",
   350  		Labels:   []string{"instance"},
   351  		Comment:  "The quantile of regions transaction operates on count",
   352  		Quantile: 0.95,
   353  	},
   354  	"milevadb_load_safepoint_ops": {
   355  		PromQL:  "sum(rate(milevadb_einsteindbclient_load_safepoint_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
   356  		Labels:  []string{"instance", "type"},
   357  		Comment: "The OPS of load safe point loading",
   358  	},
   359  	"milevadb_load_safepoint_total_num": {
   360  		PromQL:  "sum(increase(milevadb_einsteindbclient_load_safepoint_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
   361  		Labels:  []string{"instance", "type"},
   362  		Comment: "The total count of safe point loading",
   363  	},
   364  	"milevadb_ekv_snapshot_ops": {
   365  		Comment: "using snapshots total",
   366  		PromQL:  "sum(rate(milevadb_einsteindbclient_snapshot_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   367  		Labels:  []string{"instance"},
   368  	},
   369  	"FIDel_client_cmd_ops": {
   370  		PromQL:  "sum(rate(FIDel_client_cmd_handle_cmds_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   371  		Labels:  []string{"instance", "type"},
   372  		Comment: "fidel client command ops",
   373  	},
   374  	"FIDel_client_cmd_duration": {
   375  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(FIDel_client_cmd_handle_cmds_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, type,instance))",
   376  		Labels:   []string{"instance", "type"},
   377  		Quantile: 0.95,
   378  		Comment:  "The quantile of fidel client command durations",
   379  	},
   380  	"FIDel_cmd_fail_ops": {
   381  		PromQL:  "sum(rate(FIDel_client_cmd_handle_failed_cmds_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   382  		Labels:  []string{"instance", "type"},
   383  		Comment: "fidel client command fail count",
   384  	},
   385  	"FIDel_cmd_fail_total_count": {
   386  		PromQL:  "sum(increase(FIDel_client_cmd_handle_failed_cmds_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   387  		Labels:  []string{"instance", "type"},
   388  		Comment: "The total count of fidel client command fail",
   389  	},
   390  	"FIDel_request_rpc_ops": {
   391  		PromQL:  "sum(rate(FIDel_client_request_handle_requests_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))",
   392  		Labels:  []string{"instance", "type"},
   393  		Comment: "fidel client handle request operation per second",
   394  	},
   395  	"FIDel_request_rpc_duration": {
   396  		Comment:  "The quantile of fidel client handle request duration(second)",
   397  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(FIDel_client_request_handle_requests_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,instance))",
   398  		Labels:   []string{"instance", "type"},
   399  		Quantile: 0.999,
   400  	},
   401  	"FIDel_tso_wait_duration": {
   402  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(FIDel_client_cmd_handle_cmds_duration_seconds_bucket{type=\"wait\"}[$RANGE_DURATION])) by (le,instance))",
   403  		Labels:   []string{"instance"},
   404  		Quantile: 0.999,
   405  		Comment:  "The quantile duration of a client starting to wait for the TS until received the TS result.",
   406  	},
   407  	"FIDel_tso_rpc_duration": {
   408  		Comment:  "The quantile duration of a client sending TSO request until received the response.",
   409  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(FIDel_client_request_handle_requests_duration_seconds_bucket{type=\"tso\"}[$RANGE_DURATION])) by (le,instance))",
   410  		Labels:   []string{"instance"},
   411  		Quantile: 0.999,
   412  	},
   413  	"FIDel_start_tso_wait_duration": {
   414  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_FIDelclient_ts_future_wait_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
   415  		Labels:   []string{"instance"},
   416  		Quantile: 0.999,
   417  		Comment:  "The quantile duration of the waiting time for getting the start timestamp oracle",
   418  	},
   419  	"milevadb_load_schema_duration": {
   420  		Comment:  "The quantile of MilevaDB loading schemaReplicant time durations by instance",
   421  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_petri_load_schema_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance))",
   422  		Labels:   []string{"instance"},
   423  		Quantile: 0.99,
   424  	},
   425  	"milevadb_load_schema_ops": {
   426  		Comment: "MilevaDB loading schemaReplicant times including both failed and successful ones",
   427  		PromQL:  "sum(rate(milevadb_petri_load_schema_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
   428  		Labels:  []string{"instance", "type"},
   429  	},
   430  	"milevadb_schema_lease_error_opm": {
   431  		Comment: "MilevaDB schemaReplicant lease error counts",
   432  		PromQL:  "sum(increase(milevadb_stochastik_schema_lease_error_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   433  		Labels:  []string{"instance"},
   434  	},
   435  	"milevadb_schema_lease_error_total_count": {
   436  		Comment: "The total count of MilevaDB schemaReplicant lease error",
   437  		PromQL:  "sum(increase(milevadb_stochastik_schema_lease_error_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   438  		Labels:  []string{"instance"},
   439  	},
   440  	"milevadb_load_privilege_ops": {
   441  		Comment: "MilevaDB load privilege counts",
   442  		PromQL:  "sum(rate(milevadb_petri_load_privilege_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
   443  		Labels:  []string{"instance", "type"},
   444  	},
   445  	"milevadb_dbs_duration": {
   446  		Comment:  "The quantile of MilevaDB DBS duration statistics",
   447  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_dbs_handle_job_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, type,instance))",
   448  		Labels:   []string{"instance", "type"},
   449  		Quantile: 0.95,
   450  	},
   451  	"milevadb_dbs_batch_add_index_duration": {
   452  		Comment:  "The quantile of MilevaDB batch add index durations by histogram buckets",
   453  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_dbs_batch_add_idx_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, type, instance))",
   454  		Labels:   []string{"instance", "type"},
   455  		Quantile: 0.95,
   456  	},
   457  	"milevadb_dbs_add_index_speed": {
   458  		Comment: "MilevaDB add index speed",
   459  		PromQL:  "sum(rate(milevadb_dbs_add_index_total[$RANGE_DURATION])) by (type)",
   460  	},
   461  	"milevadb_dbs_waiting_jobs_num": {
   462  		Comment: "MilevaDB dbs request in queue",
   463  		PromQL:  "milevadb_dbs_waiting_jobs{$LABEL_CONDITIONS}",
   464  		Labels:  []string{"instance", "type"},
   465  	},
   466  	"milevadb_dbs_spacetime_opm": {
   467  		Comment: "MilevaDB different dbs worker numbers",
   468  		PromQL:  "increase(milevadb_dbs_worker_operation_total{$LABEL_CONDITIONS}[$RANGE_DURATION])",
   469  		Labels:  []string{"instance", "type"},
   470  	},
   471  	"milevadb_dbs_worker_duration": {
   472  		Comment:  "The quantile of MilevaDB dbs worker duration",
   473  		PromQL:   "histogram_quantile($QUANTILE, sum(increase(milevadb_dbs_worker_operation_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, type, action, result,instance))",
   474  		Labels:   []string{"instance", "type", "result", "action"},
   475  		Quantile: 0.95,
   476  	},
   477  	"milevadb_dbs_deploy_syncer_duration": {
   478  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_dbs_deploy_syncer_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, type, result,instance))",
   479  		Labels:   []string{"instance", "type", "result"},
   480  		Quantile: 0.95,
   481  		Comment:  "The quantile of MilevaDB dbs schemaReplicant syncer statistics, including init, start, watch, clear function call time cost",
   482  	},
   483  	"milevadb_tenant_handle_syncer_duration": {
   484  		Comment:  "The quantile of MilevaDB dbs tenant time operations on etcd duration statistics ",
   485  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_dbs_tenant_handle_syncer_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, type, result,instance))",
   486  		Labels:   []string{"instance", "type", "result"},
   487  		Quantile: 0.95,
   488  	},
   489  	"milevadb_dbs_uFIDelate_self_version_duration": {
   490  		Comment:  "The quantile of MilevaDB schemaReplicant syncer version uFIDelate time duration",
   491  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_dbs_uFIDelate_self_ver_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, result,instance))",
   492  		Labels:   []string{"instance", "result"},
   493  		Quantile: 0.95,
   494  	},
   495  	"milevadb_dbs_opm": {
   496  		Comment: "The quantile of executed DBS jobs per minute",
   497  		PromQL:  "sum(rate(milevadb_dbs_handle_job_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   498  		Labels:  []string{"instance", "type"},
   499  	},
   500  	"milevadb_statistics_auto_analyze_duration": {
   501  		Comment:  "The quantile of MilevaDB auto analyze time durations within 95 percent histogram buckets",
   502  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_statistics_auto_analyze_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
   503  		Labels:   []string{"instance"},
   504  		Quantile: 0.95,
   505  	},
   506  	"milevadb_statistics_auto_analyze_ops": {
   507  		Comment: "MilevaDB auto analyze query per second",
   508  		PromQL:  "sum(rate(milevadb_statistics_auto_analyze_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   509  		Labels:  []string{"instance", "type"},
   510  	},
   511  	"milevadb_statistics_stats_inaccuracy_rate": {
   512  		Comment:  "The quantile of MilevaDB statistics inaccurate rate",
   513  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_statistics_stats_inaccuracy_rate_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
   514  		Labels:   []string{"instance"},
   515  		Quantile: 0.95,
   516  	},
   517  	"milevadb_statistics_pseudo_estimation_ops": {
   518  		Comment: "MilevaDB optimizer using pseudo estimation counts",
   519  		PromQL:  "sum(rate(milevadb_statistics_pseudo_estimation_total{$LABEL_CONDITIONS}[$RANGE_DURATION]))",
   520  		Labels:  []string{"instance"},
   521  	},
   522  	"milevadb_statistics_pseudo_estimation_total_count": {
   523  		Comment: "The total count of MilevaDB optimizer using pseudo estimation",
   524  		PromQL:  "sum(increase(milevadb_statistics_pseudo_estimation_total{$LABEL_CONDITIONS}[$RANGE_DURATION]))",
   525  		Labels:  []string{"instance"},
   526  	},
   527  	"milevadb_statistics_dump_feedback_ops": {
   528  		Comment: "MilevaDB dumping statistics back to ekv storage times",
   529  		PromQL:  "sum(rate(milevadb_statistics_dump_feedback_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   530  		Labels:  []string{"instance", "type"},
   531  	},
   532  	"milevadb_statistics_dump_feedback_total_count": {
   533  		Comment: "The total count of operations that MilevaDB dumping statistics back to ekv storage",
   534  		PromQL:  "sum(increase(milevadb_statistics_dump_feedback_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   535  		Labels:  []string{"instance", "type"},
   536  	},
   537  	"milevadb_statistics_store_query_feedback_qps": {
   538  		Comment: "MilevaDB causetstore quering feedback counts",
   539  		PromQL:  "sum(rate(milevadb_statistics_store_query_feedback_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance) ",
   540  		Labels:  []string{"instance", "type"},
   541  	},
   542  	"milevadb_statistics_store_query_feedback_total_count": {
   543  		Comment: "The total count of MilevaDB causetstore quering feedback",
   544  		PromQL:  "sum(increase(milevadb_statistics_store_query_feedback_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance) ",
   545  		Labels:  []string{"instance", "type"},
   546  	},
   547  	"milevadb_statistics_significant_feedback": {
   548  		Comment: "Counter of query feedback whose actual count is much different than calculated by current statistics",
   549  		PromQL:  "sum(rate(milevadb_statistics_high_error_rate_feedback_total{$LABEL_CONDITIONS}[$RANGE_DURATION]))",
   550  		Labels:  []string{"instance"},
   551  	},
   552  	"milevadb_statistics_uFIDelate_stats_ops": {
   553  		Comment: "MilevaDB uFIDelating statistics using feed back counts",
   554  		PromQL:  "sum(rate(milevadb_statistics_uFIDelate_stats_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   555  		Labels:  []string{"instance", "type"},
   556  	},
   557  	"milevadb_statistics_uFIDelate_stats_total_count": {
   558  		Comment: "The total count of MilevaDB uFIDelating statistics using feed back",
   559  		PromQL:  "sum(increase(milevadb_statistics_uFIDelate_stats_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   560  		Labels:  []string{"instance", "type"},
   561  	},
   562  	"milevadb_statistics_fast_analyze_status": {
   563  		Comment:  "The quantile of MilevaDB fast analyze statistics ",
   564  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_statistics_fast_analyze_status_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, type,instance))",
   565  		Labels:   []string{"instance", "type"},
   566  		Quantile: 0.95,
   567  	},
   568  	"milevadb_new_etcd_stochastik_duration": {
   569  		Comment:  "The quantile of MilevaDB new stochastik durations for new etcd stochastik",
   570  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_tenant_new_stochastik_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,result, instance))",
   571  		Labels:   []string{"instance", "type", "result"},
   572  		Quantile: 0.95,
   573  	},
   574  	"milevadb_tenant_watcher_ops": {
   575  		Comment: "MilevaDB tenant watcher counts",
   576  		PromQL:  "sum(rate(milevadb_tenant_watch_tenant_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type, result, instance)",
   577  		Labels:  []string{"instance", "type", "result"},
   578  	},
   579  	"milevadb_auto_id_qps": {
   580  		Comment: "MilevaDB auto id requests per second including single causet/global auto id processing and single causet auto id rebase processing",
   581  		PromQL:  "sum(rate(milevadb_autoid_operation_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))",
   582  		Labels:  []string{"instance"},
   583  	},
   584  	"milevadb_auto_id_request_duration": {
   585  		Comment:  "The quantile of MilevaDB auto id requests durations",
   586  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_autoid_operation_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, type,instance))",
   587  		Labels:   []string{"instance", "type"},
   588  		Quantile: 0.95,
   589  	},
   590  	"milevadb_region_cache_ops": {
   591  		Comment: "MilevaDB region cache operations count",
   592  		PromQL:  "sum(rate(milevadb_einsteindbclient_region_cache_operations_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,result,instance)",
   593  		Labels:  []string{"instance", "type", "result"},
   594  	},
   595  	"milevadb_spacetime_operation_duration": {
   596  		Comment:  "The quantile of MilevaDB spacetime operation durations including get/set schemaReplicant and dbs jobs",
   597  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_spacetime_operation_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, type,result,instance))",
   598  		Labels:   []string{"instance", "type", "result"},
   599  		Quantile: 0.95,
   600  	},
   601  	"milevadb_gc_worker_action_opm": {
   602  		Comment: "ekv storage garbage defCauslection counts by type",
   603  		PromQL:  "sum(increase(milevadb_einsteindbclient_gc_worker_actions_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   604  		Labels:  []string{"instance", "type"},
   605  	},
   606  	"milevadb_gc_duration": {
   607  		Comment:  "The quantile of ekv storage garbage defCauslection time durations",
   608  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_gc_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))",
   609  		Labels:   []string{"instance"},
   610  		Quantile: 0.95,
   611  	},
   612  	"milevadb_gc_config": {
   613  		Comment: "ekv storage garbage defCauslection config including gc_life_time and gc_run_interval",
   614  		PromQL:  "milevadb_einsteindbclient_gc_config{$LABEL_CONDITIONS}",
   615  		Labels:  []string{"instance", "type"},
   616  	},
   617  	"milevadb_gc_fail_opm": {
   618  		Comment: "ekv storage garbage defCauslection failing counts",
   619  		PromQL:  "sum(increase(milevadb_einsteindbclient_gc_failure{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   620  		Labels:  []string{"instance", "type"},
   621  	},
   622  	"milevadb_gc_delete_range_fail_opm": {
   623  		Comment: "ekv storage unsafe destroy range failed counts",
   624  		PromQL:  "sum(increase(milevadb_einsteindbclient_gc_unsafe_destroy_range_failures{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   625  		Labels:  []string{"instance", "type"},
   626  	},
   627  	"milevadb_gc_too_many_locks_opm": {
   628  		Comment: "ekv storage region garbage defCauslection clean too many locks count",
   629  		PromQL:  "sum(increase(milevadb_einsteindbclient_gc_region_too_many_locks[$RANGE_DURATION]))",
   630  	},
   631  	"milevadb_gc_action_result_opm": {
   632  		Comment: "ekv storage garbage defCauslection results including failed and successful ones",
   633  		PromQL:  "sum(increase(milevadb_einsteindbclient_gc_action_result{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)",
   634  		Labels:  []string{"instance", "type"},
   635  	},
   636  	"milevadb_gc_delete_range_task_status": {
   637  		Comment: "ekv storage delete range task execution status by type",
   638  		PromQL:  "sum(milevadb_einsteindbclient_range_task_stats{$LABEL_CONDITIONS}) by (type, result,instance)",
   639  		Labels:  []string{"instance", "type", "result"},
   640  	},
   641  	"milevadb_gc_push_task_duration": {
   642  		Comment:  "The quantile of ekv storage range worker processing one task duration",
   643  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_range_task_push_duration_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,instance))",
   644  		Labels:   []string{"instance", "type"},
   645  		Quantile: 0.95,
   646  	},
   647  	"milevadb_batch_client_pending_req_count": {
   648  		Comment: "ekv storage batch requests in queue",
   649  		PromQL:  "sum(milevadb_einsteindbclient_pending_batch_requests{$LABEL_CONDITIONS}) by (causetstore,instance)",
   650  		Labels:  []string{"instance", "causetstore"},
   651  	},
   652  	"milevadb_batch_client_wait_duration": {
   653  		Comment:  "The quantile of ekv storage batch processing durations",
   654  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_batch_wait_duration_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance))",
   655  		Labels:   []string{"instance"},
   656  		Quantile: 0.95,
   657  	},
   658  	"milevadb_batch_client_wait_conn_duration": {
   659  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_batch_client_wait_connection_establish_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance))",
   660  		Labels:   []string{"instance"},
   661  		Quantile: 0.95,
   662  		Comment:  "The quantile of batch client wait new connection establish durations",
   663  	},
   664  	"milevadb_batch_client_wait_conn_total_count": {
   665  		PromQL:  "sum(increase(milevadb_einsteindbclient_batch_client_wait_connection_establish_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   666  		Labels:  []string{"instance"},
   667  		Comment: "The total count of batch client wait new connection establish",
   668  	},
   669  	"milevadb_batch_client_wait_conn_total_time": {
   670  		PromQL:  "sum(increase(milevadb_einsteindbclient_batch_client_wait_connection_establish_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
   671  		Labels:  []string{"instance"},
   672  		Comment: "The total time of batch client wait new connection establish",
   673  	},
   674  	"milevadb_batch_client_unavailable_duration": {
   675  		Comment:  "The quantile of ekv storage batch processing unvailable durations",
   676  		PromQL:   "histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_batch_client_unavailable_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance))",
   677  		Labels:   []string{"instance"},
   678  		Quantile: 0.95,
   679  	},
   680  	"uptime": {
   681  		PromQL:  "(time() - process_start_time_seconds{$LABEL_CONDITIONS})",
   682  		Labels:  []string{"instance", "job"},
   683  		Comment: "MilevaDB uptime since last restart(second)",
   684  	},
   685  	"up": {
   686  		PromQL:  `up{$LABEL_CONDITIONS}`,
   687  		Labels:  []string{"instance", "job"},
   688  		Comment: "whether the instance is up. 1 is up, 0 is down(off-line)",
   689  	},
   690  	"FIDel_role": {
   691  		PromQL:  `delta(FIDel_tso_events{type="save"}[$RANGE_DURATION]) > bool 0`,
   692  		Labels:  []string{"instance"},
   693  		Comment: "It indicates whether the current FIDel is the leader or a follower.",
   694  	},
   695  	"normal_stores": {
   696  		PromQL:  `sum(FIDel_cluster_status{type="store_up_count"}) by (instance)`,
   697  		Labels:  []string{"instance"},
   698  		Comment: "The count of healthy stores",
   699  	},
   700  	"abnormal_stores": {
   701  		PromQL: `sum(FIDel_cluster_status{ type=~"store_disconnected_count|store_unhealth_count|store_low_space_count|store_down_count|store_offline_count|store_tombstone_count"})`,
   702  		Labels: []string{"instance", "type"},
   703  	},
   704  	"FIDel_scheduler_config": {
   705  		PromQL: `FIDel_config_status{$LABEL_CONDITIONS}`,
   706  		Labels: []string{"type"},
   707  	},
   708  	"FIDel_region_label_isolation_level": {
   709  		PromQL: `FIDel_regions_label_level{$LABEL_CONDITIONS}`,
   710  		Labels: []string{"instance", "type"},
   711  	},
   712  	"FIDel_label_distribution": {
   713  		PromQL: `FIDel_cluster_memristed_status{$LABEL_CONDITIONS}`,
   714  		Labels: []string{"name"},
   715  	},
   716  	"FIDel_cluster_status": {
   717  		PromQL: `sum(FIDel_cluster_status{$LABEL_CONDITIONS}) by (instance, type)`,
   718  		Labels: []string{"instance", "type"},
   719  	},
   720  	"FIDel_cluster_spacetimedata": {
   721  		PromQL: `FIDel_cluster_spacetimedata{$LABEL_CONDITIONS}`,
   722  		Labels: []string{"instance", "type"},
   723  	},
   724  	"FIDel_region_health": {
   725  		PromQL:  `sum(FIDel_regions_status{$LABEL_CONDITIONS}) by (instance, type)`,
   726  		Labels:  []string{"instance", "type"},
   727  		Comment: "It records the unusual Regions' count which may include pending peers, down peers, extra peers, offline peers, missing peers or learner peers",
   728  	},
   729  	"FIDel_schedule_operator": {
   730  		PromQL:  `sum(delta(FIDel_schedule_operators_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,event,instance)`,
   731  		Labels:  []string{"instance", "type", "event"},
   732  		Comment: "The number of different operators",
   733  	},
   734  	"FIDel_schedule_operator_total_num": {
   735  		PromQL:  `sum(increase(FIDel_schedule_operators_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,event,instance)`,
   736  		Labels:  []string{"instance", "type", "event"},
   737  		Comment: "The total number of different operators",
   738  	},
   739  	"FIDel_operator_finish_duration": {
   740  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(FIDel_schedule_finish_operators_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type))`,
   741  		Labels:   []string{"type"},
   742  		Quantile: 0.99,
   743  		Comment:  "The quantile time consumed when the operator is finished",
   744  	},
   745  	"FIDel_operator_step_finish_duration": {
   746  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(FIDel_schedule_finish_operator_steps_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type))`,
   747  		Labels:   []string{"type"},
   748  		Quantile: 0.99,
   749  		Comment:  "The quantile time consumed when the operator step is finished",
   750  	},
   751  	"FIDel_scheduler_store_status": {
   752  		PromQL: `FIDel_scheduler_store_status{$LABEL_CONDITIONS}`,
   753  		Labels: []string{"instance", "address", "causetstore", "type"},
   754  	},
   755  	"store_available_ratio": {
   756  		PromQL:  `sum(FIDel_scheduler_store_status{type="store_available"}) by (address, causetstore) / sum(FIDel_scheduler_store_status{type="store_capacity"}) by (address, causetstore)`,
   757  		Labels:  []string{"address", "causetstore"},
   758  		Comment: "It is equal to CausetStore available capacity size over CausetStore capacity size for each EinsteinDB instance",
   759  	},
   760  	"store_size_amplification": {
   761  		PromQL:  `sum(FIDel_scheduler_store_status{type="region_size"}) by (address, causetstore) / sum(FIDel_scheduler_store_status{type="store_used"}) by (address, causetstore) * 2^20`,
   762  		Labels:  []string{"address", "causetstore"},
   763  		Comment: "The size amplification, which is equal to CausetStore Region size over CausetStore used capacity size, of each EinsteinDB instance",
   764  	},
   765  	"FIDel_scheduler_op_influence": {
   766  		PromQL: `FIDel_scheduler_op_influence{$LABEL_CONDITIONS}`,
   767  		Labels: []string{"instance", "scheduler", "causetstore", "type"},
   768  	},
   769  	"FIDel_scheduler_tolerant_resource": {
   770  		PromQL: `FIDel_scheduler_tolerant_resource{$LABEL_CONDITIONS}`,
   771  		Labels: []string{"instance", "scheduler", "source", "target"},
   772  	},
   773  	"FIDel_hotspot_status": {
   774  		PromQL: `FIDel_hotspot_status{$LABEL_CONDITIONS}`,
   775  		Labels: []string{"instance", "address", "causetstore", "type"},
   776  	},
   777  	"FIDel_scheduler_status": {
   778  		PromQL: `FIDel_scheduler_status{$LABEL_CONDITIONS}`,
   779  		Labels: []string{"instance", "HoTT", "type"},
   780  	},
   781  	"FIDel_scheduler_balance_leader": {
   782  		PromQL:  `sum(delta(FIDel_scheduler_balance_leader{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (address,causetstore,instance,type)`,
   783  		Labels:  []string{"instance", "address", "causetstore", "type"},
   784  		Comment: "The leader movement details among EinsteinDB instances",
   785  	},
   786  	"FIDel_scheduler_balance_region": {
   787  		PromQL:  `sum(delta(FIDel_scheduler_balance_region{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (address,causetstore,instance,type)`,
   788  		Labels:  []string{"instance", "address", "causetstore", "type"},
   789  		Comment: "The Region movement details among EinsteinDB instances",
   790  	},
   791  	"FIDel_balance_scheduler_status": {
   792  		PromQL:  `sum(delta(FIDel_scheduler_event_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,name)`,
   793  		Labels:  []string{"instance", "name", "type"},
   794  		Comment: "The inner status of balance leader scheduler",
   795  	},
   796  	"FIDel_checker_event_count": {
   797  		PromQL:  `sum(delta(FIDel_checker_event_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (name,instance,type)`,
   798  		Labels:  []string{"instance", "name", "type"},
   799  		Comment: "The replica/region checker's status",
   800  	},
   801  	"FIDel_schedule_filter": {
   802  		PromQL: `sum(delta(FIDel_schedule_filter{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (causetstore, type, scope, instance)`,
   803  		Labels: []string{"instance", "scope", "causetstore", "type"},
   804  	},
   805  	"FIDel_scheduler_balance_direction": {
   806  		PromQL: `sum(delta(FIDel_scheduler_balance_direction{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,source,target,instance)`,
   807  		Labels: []string{"instance", "source", "target", "type"},
   808  	},
   809  	"FIDel_schedule_store_limit": {
   810  		PromQL: `FIDel_schedule_store_limit{$LABEL_CONDITIONS}`,
   811  		Labels: []string{"instance", "causetstore", "type"},
   812  	},
   813  
   814  	"FIDel_grpc_completed_commands_rate": {
   815  		PromQL:  `sum(rate(grpc_server_handling_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (grpc_method,instance)`,
   816  		Labels:  []string{"instance", "grpc_method"},
   817  		Comment: "The rate of completing each HoTT of gRPC commands",
   818  	},
   819  	"FIDel_grpc_completed_commands_duration": {
   820  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(grpc_server_handling_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,grpc_method,instance))`,
   821  		Labels:   []string{"instance", "grpc_method"},
   822  		Quantile: 0.99,
   823  		Comment:  "The quantile time consumed of completing each HoTT of gRPC commands",
   824  	},
   825  	"FIDel_handle_transactions_rate": {
   826  		PromQL:  `sum(rate(FIDel_txn_handle_txns_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, result)`,
   827  		Labels:  []string{"instance", "result"},
   828  		Comment: "The rate of handling etcd transactions",
   829  	},
   830  	"FIDel_handle_transactions_duration": {
   831  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(FIDel_txn_handle_txns_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance, result))`,
   832  		Labels:   []string{"instance", "result"},
   833  		Quantile: 0.99,
   834  		Comment:  "The quantile time consumed of handling etcd transactions",
   835  	},
   836  	"etcd_wal_fsync_duration": {
   837  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(etcd_disk_wal_fsync_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
   838  		Labels:   []string{"instance"},
   839  		Quantile: 0.99,
   840  		Comment:  "The quantile time consumed of writing WAL into the persistent storage",
   841  	},
   842  	"FIDel_peer_round_trip_duration": {
   843  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(etcd_network_peer_round_trip_time_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,To))`,
   844  		Labels:   []string{"instance", "To"},
   845  		Quantile: 0.99,
   846  		Comment:  "The quantile latency of the network in .99",
   847  	},
   848  	"etcd_disk_wal_fsync_rate": {
   849  		PromQL:  `delta(etcd_disk_wal_fsync_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
   850  		Labels:  []string{"instance"},
   851  		Comment: "The rate of writing WAL into the persistent storage",
   852  	},
   853  	"FIDel_server_etcd_state": {
   854  		PromQL:  `FIDel_server_etcd_state{$LABEL_CONDITIONS}`,
   855  		Labels:  []string{"instance", "type"},
   856  		Comment: "The current term of Raft",
   857  	},
   858  	"FIDel_request_rpc_duration_avg": {
   859  		PromQL: `avg(rate(FIDel_client_request_handle_requests_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type) / avg(rate(FIDel_client_request_handle_requests_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type)`,
   860  		Labels: []string{"type"},
   861  	},
   862  	"FIDel_region_heartbeat_duration": {
   863  		PromQL:   `round(histogram_quantile($QUANTILE, sum(rate(FIDel_scheduler_region_heartbeat_latency_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,address, causetstore)), 1000)`,
   864  		Labels:   []string{"address", "causetstore"},
   865  		Quantile: 0.99,
   866  		Comment:  "The quantile of heartbeat latency of each EinsteinDB instance in",
   867  	},
   868  	"FIDel_scheduler_region_heartbeat": {
   869  		PromQL: `sum(rate(FIDel_scheduler_region_heartbeat{$LABEL_CONDITIONS}[$RANGE_DURATION])*60) by (address,instance, causetstore, status,type)`,
   870  		Labels: []string{"instance", "address", "status", "causetstore", "type"},
   871  	},
   872  	"FIDel_region_syncer_status": {
   873  		PromQL: `FIDel_region_syncer_status{$LABEL_CONDITIONS}`,
   874  		Labels: []string{"instance", "type"},
   875  	},
   876  	"einsteindb_engine_size": {
   877  		PromQL:  `sum(einsteindb_engine_size_bytes{$LABEL_CONDITIONS}) by (instance, type, EDB)`,
   878  		Labels:  []string{"instance", "type", "EDB"},
   879  		Comment: "The storage size per EinsteinDB instance",
   880  	},
   881  	"einsteindb_store_size": {
   882  		PromQL:  `sum(einsteindb_store_size_bytes{$LABEL_CONDITIONS}) by (instance,type)`,
   883  		Labels:  []string{"instance", "type"},
   884  		Comment: "The available or capacity size of each EinsteinDB instance",
   885  	},
   886  	"einsteindb_thread_cpu": {
   887  		PromQL:  `sum(rate(einsteindb_thread_cpu_seconds_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,name)`,
   888  		Labels:  []string{"instance", "name"},
   889  		Comment: "The CPU usage of each EinsteinDB instance",
   890  	},
   891  	"einsteindb_memory": {
   892  		PromQL:  `avg(process_resident_memory_bytes{$LABEL_CONDITIONS}) by (instance)`,
   893  		Labels:  []string{"instance"},
   894  		Comment: "The memory usage per EinsteinDB instance",
   895  	},
   896  	"einsteindb_io_utilization": {
   897  		PromQL:  `rate(node_disk_io_time_seconds_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
   898  		Labels:  []string{"instance", "device"},
   899  		Comment: "The I/O utilization per EinsteinDB instance",
   900  	},
   901  	"einsteindb_flow_mbps": {
   902  		PromQL:  `sum(rate(einsteindb_engine_flow_bytes{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,EDB)`,
   903  		Labels:  []string{"instance", "type", "EDB"},
   904  		Comment: "The total bytes of read and write in each EinsteinDB instance",
   905  	},
   906  	"einsteindb_grpc_qps": {
   907  		PromQL:  `sum(rate(einsteindb_grpc_msg_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)`,
   908  		Labels:  []string{"instance", "type"},
   909  		Comment: "The QPS per command in each EinsteinDB instance",
   910  	},
   911  	"einsteindb_grpc_errors": {
   912  		PromQL:  `sum(rate(einsteindb_grpc_msg_fail_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)`,
   913  		Labels:  []string{"instance", "type"},
   914  		Comment: "The OPS of the gRPC message failures",
   915  	},
   916  	"einsteindb_grpc_error_total_count": {
   917  		PromQL:  `sum(increase(einsteindb_grpc_msg_fail_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)`,
   918  		Labels:  []string{"instance", "type"},
   919  		Comment: "The total count of the gRPC message failures",
   920  	},
   921  	"einsteindb_critical_error": {
   922  		PromQL:  `sum(rate(einsteindb_critical_error_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, type)`,
   923  		Labels:  []string{"instance", "type"},
   924  		Comment: "The OPS of the EinsteinDB critical error",
   925  	},
   926  	"einsteindb_critical_error_total_count": {
   927  		PromQL:  `sum(increase(einsteindb_critical_error_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, type)`,
   928  		Labels:  []string{"instance", "type"},
   929  		Comment: "The total number of the EinsteinDB critical error",
   930  	},
   931  	"einsteindb_FIDel_heartbeat": {
   932  		PromQL:  `sum(delta(einsteindb_FIDel_heartbeat_message_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)`,
   933  		Labels:  []string{"instance", "type"},
   934  		Comment: "The total number of the gRPC message failures",
   935  	},
   936  	"einsteindb_region_count": {
   937  		PromQL:  `sum(einsteindb_raftstore_region_count{$LABEL_CONDITIONS}) by (instance,type)`,
   938  		Labels:  []string{"instance", "type"},
   939  		Comment: "The number of regions on each EinsteinDB instance",
   940  	},
   941  	"einsteindb_scheduler_is_busy": {
   942  		PromQL:  `sum(rate(einsteindb_scheduler_too_busy_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,EDB,type,stage)`,
   943  		Labels:  []string{"instance", "EDB", "type", "stage"},
   944  		Comment: "Indicates occurrences of Scheduler Busy events that make the EinsteinDB instance unavailable temporarily",
   945  	},
   946  	"einsteindb_scheduler_is_busy_total_count": {
   947  		PromQL:  `sum(increase(einsteindb_scheduler_too_busy_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,EDB,type,stage)`,
   948  		Labels:  []string{"instance", "EDB", "type", "stage"},
   949  		Comment: "The total count of Scheduler Busy events that make the EinsteinDB instance unavailable temporarily",
   950  	},
   951  	"einsteindb_channel_full": {
   952  		PromQL:  `sum(rate(einsteindb_channel_full_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,EDB)`,
   953  		Labels:  []string{"instance", "EDB", "type"},
   954  		Comment: "The ops of channel full errors on each EinsteinDB instance, it will make the EinsteinDB instance unavailable temporarily",
   955  	},
   956  	"einsteindb_channel_full_total_count": {
   957  		PromQL:  `sum(increase(einsteindb_channel_full_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,EDB)`,
   958  		Labels:  []string{"instance", "EDB", "type"},
   959  		Comment: "The total number of channel full errors on each EinsteinDB instance, it will make the EinsteinDB instance unavailable temporarily",
   960  	},
   961  	"einsteindb_coprocessor_is_busy": {
   962  		PromQL:  `sum(rate(einsteindb_coprocessor_request_error{type='full'}[$RANGE_DURATION])) by (instance,EDB,type)`,
   963  		Labels:  []string{"instance", "EDB"},
   964  		Comment: "The ops of Coprocessor Full events that make the EinsteinDB instance unavailable temporarily",
   965  	},
   966  	"einsteindb_coprocessor_is_busy_total_count": {
   967  		PromQL:  `sum(increase(einsteindb_coprocessor_request_error{type='full'}[$RANGE_DURATION])) by (instance,EDB,type)`,
   968  		Labels:  []string{"instance", "EDB"},
   969  		Comment: "The total count of Coprocessor Full events that make the EinsteinDB instance unavailable temporarily",
   970  	},
   971  	"einsteindb_engine_write_stall": {
   972  		PromQL:  `avg(einsteindb_engine_write_stall{type="write_stall_percentile99"}) by (instance, EDB)`,
   973  		Labels:  []string{"instance", "EDB"},
   974  		Comment: "Indicates occurrences of Write Stall events that make the EinsteinDB instance unavailable temporarily",
   975  	},
   976  	"einsteindb_server_report_failures": {
   977  		PromQL:  `sum(rate(einsteindb_server_report_failure_msg_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance,store_id)`,
   978  		Labels:  []string{"instance", "store_id", "type"},
   979  		Comment: "The total number of reported failure messages",
   980  	},
   981  	"einsteindb_server_report_failures_total_count": {
   982  		PromQL:  `sum(increase(einsteindb_server_report_failure_msg_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance,store_id)`,
   983  		Labels:  []string{"instance", "store_id", "type"},
   984  		Comment: "The total number of reported failure messages",
   985  	},
   986  	"einsteindb_storage_async_requests": {
   987  		PromQL:  `sum(rate(einsteindb_storage_engine_async_request_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, status, type)`,
   988  		Labels:  []string{"instance", "status", "type"},
   989  		Comment: "The number of different raftstore errors on each EinsteinDB instance",
   990  	},
   991  	"einsteindb_storage_async_requests_total_count": {
   992  		PromQL:  `sum(increase(einsteindb_storage_engine_async_request_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, status, type)`,
   993  		Labels:  []string{"instance", "status", "type"},
   994  		Comment: "The total number of different raftstore errors on each EinsteinDB instance",
   995  	},
   996  	"einsteindb_scheduler_stage": {
   997  		PromQL:  `sum(rate(einsteindb_scheduler_stage_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, stage,type)`,
   998  		Labels:  []string{"instance", "stage", "type"},
   999  		Comment: "The number of scheduler state on each EinsteinDB instance",
  1000  	},
  1001  	"einsteindb_scheduler_stage_total_num": {
  1002  		PromQL:  `sum(increase(einsteindb_scheduler_stage_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, stage,type)`,
  1003  		Labels:  []string{"instance", "stage", "type"},
  1004  		Comment: "The total number of scheduler state on each EinsteinDB instance",
  1005  	},
  1006  
  1007  	"einsteindb_coprocessor_request_error": {
  1008  		PromQL:  `sum(rate(einsteindb_coprocessor_request_error{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, reason)`,
  1009  		Labels:  []string{"instance", "reason"},
  1010  		Comment: "The number of different interlock errors on each EinsteinDB instance",
  1011  	},
  1012  	"einsteindb_coprocessor_request_error_total_count": {
  1013  		PromQL:  `sum(increase(einsteindb_coprocessor_request_error{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, reason)`,
  1014  		Labels:  []string{"instance", "reason"},
  1015  		Comment: "The total number of different interlock errors on each EinsteinDB instance",
  1016  	},
  1017  	"einsteindb_region_change": {
  1018  		PromQL:  `sum(delta(einsteindb_raftstore_region_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)`,
  1019  		Labels:  []string{"instance", "type"},
  1020  		Comment: "The count of region change per EinsteinDB instance",
  1021  	},
  1022  	"einsteindb_leader_missing": {
  1023  		PromQL:  `sum(einsteindb_raftstore_leader_missing{$LABEL_CONDITIONS}) by (instance)`,
  1024  		Labels:  []string{"instance"},
  1025  		Comment: "The count of missing leaders per EinsteinDB instance",
  1026  	},
  1027  	"einsteindb_active_written_leaders": {
  1028  		PromQL:  `sum(rate(einsteindb_region_written_keys_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1029  		Labels:  []string{"instance"},
  1030  		Comment: "The number of leaders being written on each EinsteinDB instance",
  1031  	},
  1032  	"einsteindb_approximate_region_size": {
  1033  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_region_size_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1034  		Labels:   []string{"instance"},
  1035  		Quantile: 0.99,
  1036  		Comment:  "The quantile of approximate Region size, the default value is P99",
  1037  	},
  1038  	"einsteindb_approximate_avg_region_size": {
  1039  		PromQL:  `sum(rate(einsteindb_raftstore_region_size_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_raftstore_region_size_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) `,
  1040  		Labels:  []string{"instance"},
  1041  		Comment: "The avg approximate Region size",
  1042  	},
  1043  	"einsteindb_approximate_region_size_histogram": {
  1044  		PromQL: `sum(rate(einsteindb_raftstore_region_size_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1045  		Labels: []string{"instance"},
  1046  	},
  1047  	"einsteindb_region_average_written_bytes": {
  1048  		PromQL:  `sum(rate(einsteindb_region_written_bytes_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance) / sum(rate(einsteindb_region_written_bytes_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1049  		Labels:  []string{"instance"},
  1050  		Comment: "The average rate of writing bytes to Regions per EinsteinDB instance",
  1051  	},
  1052  	"einsteindb_region_written_bytes": {
  1053  		PromQL: `sum(rate(einsteindb_region_written_bytes_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1054  		Labels: []string{"instance"},
  1055  	},
  1056  	"einsteindb_region_average_written_keys": {
  1057  		PromQL:  `sum(rate(einsteindb_region_written_keys_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance) / sum(rate(einsteindb_region_written_keys_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1058  		Labels:  []string{"instance"},
  1059  		Comment: "The average rate of written keys to Regions per EinsteinDB instance",
  1060  	},
  1061  	"einsteindb_region_written_keys": {
  1062  		PromQL: `sum(rate(einsteindb_region_written_keys_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1063  		Labels: []string{"instance"},
  1064  	},
  1065  	"einsteindb_request_batch_avg": {
  1066  		PromQL:  `sum(rate(einsteindb_server_request_batch_ratio_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance) / sum(rate(einsteindb_server_request_batch_ratio_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1067  		Labels:  []string{"instance", "type"},
  1068  		Comment: "The ratio of request batch output to input per EinsteinDB instance",
  1069  	},
  1070  	"einsteindb_request_batch_ratio": {
  1071  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_server_request_batch_ratio_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,instance))`,
  1072  		Labels:   []string{"instance", "type"},
  1073  		Quantile: 0.99,
  1074  		Comment:  "The quantile ratio of request batch output to input per EinsteinDB instance",
  1075  	},
  1076  	"einsteindb_request_batch_size_avg": {
  1077  		PromQL:  `sum(rate(einsteindb_server_request_batch_size_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance) / sum(rate(einsteindb_server_request_batch_size_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1078  		Labels:  []string{"instance", "type"},
  1079  		Comment: "The avg size of requests into request batch per EinsteinDB instance",
  1080  	},
  1081  	"einsteindb_request_batch_size": {
  1082  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_server_request_batch_size_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,instance))`,
  1083  		Labels:   []string{"instance", "type"},
  1084  		Quantile: 0.99,
  1085  		Comment:  "The quantile size of requests into request batch per EinsteinDB instance",
  1086  	},
  1087  
  1088  	"einsteindb_grpc_message_duration": {
  1089  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_grpc_msg_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,instance))`,
  1090  		Labels:   []string{"instance", "type"},
  1091  		Quantile: 0.99,
  1092  		Comment:  "The quantile execution time of gRPC message",
  1093  	},
  1094  	"einsteindb_average_grpc_messge_duration": {
  1095  		PromQL: `sum(rate(einsteindb_grpc_msg_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance) / sum(rate(einsteindb_grpc_msg_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1096  		Labels: []string{"instance", "type"},
  1097  	},
  1098  	"einsteindb_grpc_req_batch_size": {
  1099  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_server_grpc_req_batch_size_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1100  		Labels:   []string{"instance"},
  1101  		Quantile: 0.99,
  1102  	},
  1103  	"einsteindb_grpc_resp_batch_size": {
  1104  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_server_grpc_resp_batch_size_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1105  		Labels:   []string{"instance"},
  1106  		Quantile: 0.99,
  1107  	},
  1108  	"einsteindb_grpc_avg_req_batch_size": {
  1109  		PromQL: `sum(rate(einsteindb_server_grpc_req_batch_size_sum[$RANGE_DURATION])) / sum(rate(einsteindb_server_grpc_req_batch_size_count[$RANGE_DURATION]))`,
  1110  	},
  1111  	"einsteindb_grpc_avg_resp_batch_size": {
  1112  		PromQL: `sum(rate(einsteindb_server_grpc_resp_batch_size_sum[$RANGE_DURATION])) / sum(rate(einsteindb_server_grpc_resp_batch_size_count[$RANGE_DURATION]))`,
  1113  	},
  1114  	"einsteindb_raft_message_batch_size": {
  1115  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_server_raft_message_batch_size_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1116  		Labels:   []string{"instance"},
  1117  		Quantile: 0.99,
  1118  	},
  1119  	"einsteindb_raft_message_avg_batch_size": {
  1120  		PromQL: `sum(rate(einsteindb_server_raft_message_batch_size_sum[$RANGE_DURATION])) / sum(rate(einsteindb_server_raft_message_batch_size_count[$RANGE_DURATION]))`,
  1121  	},
  1122  	"einsteindb_FIDel_request_ops": {
  1123  		PromQL:  `sum(rate(einsteindb_FIDel_request_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1124  		Labels:  []string{"instance", "type"},
  1125  		Comment: "The OPS of requests that EinsteinDB sends to FIDel",
  1126  	},
  1127  	"einsteindb_FIDel_request_duration": {
  1128  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_FIDel_request_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,type))`,
  1129  		Labels:   []string{"instance", "type"},
  1130  		Quantile: 0.99,
  1131  	},
  1132  	"einsteindb_FIDel_request_total_count": {
  1133  		PromQL:  `sum(increase(einsteindb_FIDel_request_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1134  		Labels:  []string{"instance", "type"},
  1135  		Comment: "The count of requests that EinsteinDB sends to FIDel",
  1136  	},
  1137  	"einsteindb_FIDel_request_total_time": {
  1138  		PromQL:  `sum(increase(einsteindb_FIDel_request_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1139  		Labels:  []string{"instance", "type"},
  1140  		Comment: "The count of requests that EinsteinDB sends to FIDel",
  1141  	},
  1142  	"einsteindb_FIDel_request_avg_duration": {
  1143  		PromQL:  `sum(rate(einsteindb_FIDel_request_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type ,instance) / sum(rate(einsteindb_FIDel_request_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1144  		Labels:  []string{"instance", "type"},
  1145  		Comment: "The time consumed by requests that EinsteinDB sends to FIDel",
  1146  	},
  1147  	"einsteindb_FIDel_heartbeats": {
  1148  		PromQL:  `sum(rate(einsteindb_FIDel_heartbeat_message_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type ,instance)`,
  1149  		Labels:  []string{"instance", "type"},
  1150  		Comment: " The total number of FIDel heartbeat messages",
  1151  	},
  1152  	"einsteindb_FIDel_validate_peers": {
  1153  		PromQL:  `sum(rate(einsteindb_FIDel_validate_peer_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type ,instance)`,
  1154  		Labels:  []string{"instance", "type"},
  1155  		Comment: "The total number of peers validated by the FIDel worker",
  1156  	},
  1157  	"einsteindb_raftstore_apply_log_avg_duration": {
  1158  		PromQL:  `sum(rate(einsteindb_raftstore_apply_log_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_raftstore_apply_log_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) `,
  1159  		Labels:  []string{"instance"},
  1160  		Comment: "The average time consumed when Raft applies log",
  1161  	},
  1162  	"einsteindb_raftstore_apply_log_duration": {
  1163  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_apply_log_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1164  		Labels:   []string{"instance"},
  1165  		Quantile: 0.99,
  1166  		Comment:  "The quantile time consumed when Raft applies log",
  1167  	},
  1168  	"einsteindb_raftstore_append_log_avg_duration": {
  1169  		PromQL:  `sum(rate(einsteindb_raftstore_append_log_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_raftstore_append_log_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1170  		Labels:  []string{"instance"},
  1171  		Comment: "The avg time consumed when Raft appends log",
  1172  	},
  1173  	"einsteindb_raftstore_append_log_duration": {
  1174  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_append_log_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1175  		Labels:   []string{"instance"},
  1176  		Quantile: 0.99,
  1177  		Comment:  "The quantile time consumed when Raft appends log",
  1178  	},
  1179  	"einsteindb_raftstore_commit_log_avg_duration": {
  1180  		PromQL:  `sum(rate(einsteindb_raftstore_commit_log_duration_seconds_sum[$RANGE_DURATION])) / sum(rate(einsteindb_raftstore_commit_log_duration_seconds_count[$RANGE_DURATION]))`,
  1181  		Comment: "The time consumed when Raft commits log",
  1182  	},
  1183  	"einsteindb_raftstore_commit_log_duration": {
  1184  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_commit_log_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1185  		Labels:   []string{"instance"},
  1186  		Quantile: 0.99,
  1187  		Comment:  "The quantile time consumed when Raft commits log",
  1188  	},
  1189  	"einsteindb_ready_handled": {
  1190  		PromQL:  `sum(rate(einsteindb_raftstore_raft_ready_handled_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1191  		Labels:  []string{"instance"},
  1192  		Comment: "The count of ready handled of Raft",
  1193  	},
  1194  	"einsteindb_raftstore_process_handled": {
  1195  		PromQL:  `sum(rate(einsteindb_raftstore_raft_process_duration_secs_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1196  		Labels:  []string{"instance", "type"},
  1197  		Comment: "The count of different process type of Raft",
  1198  	},
  1199  	"einsteindb_raftstore_process_duration": {
  1200  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_raft_process_duration_secs_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,type))`,
  1201  		Labels:   []string{"instance", "type"},
  1202  		Quantile: 0.99,
  1203  		Comment:  "The quantile time consumed for peer processes in Raft",
  1204  	},
  1205  	"einsteindb_raft_store_events_duration": {
  1206  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_event_duration_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,instance))`,
  1207  		Labels:   []string{"instance", "type"},
  1208  		Quantile: 0.99,
  1209  		Comment:  "The quantile time consumed by raftstore events (P99).99",
  1210  	},
  1211  	"einsteindb_raft_sent_messages": {
  1212  		PromQL:  `sum(rate(einsteindb_raftstore_raft_sent_message_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)`,
  1213  		Labels:  []string{"instance", "type"},
  1214  		Comment: "The number of Raft messages sent by each EinsteinDB instance",
  1215  	},
  1216  	"einsteindb_raft_sent_messages_total_num": {
  1217  		PromQL:  `sum(increase(einsteindb_raftstore_raft_sent_message_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)`,
  1218  		Labels:  []string{"instance", "type"},
  1219  		Comment: "The total number of Raft messages sent by each EinsteinDB instance",
  1220  	},
  1221  	"einsteindb_flush_messages": {
  1222  		PromQL:  `sum(rate(einsteindb_server_raft_message_flush_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1223  		Labels:  []string{"instance"},
  1224  		Comment: "The number of Raft messages flushed by each EinsteinDB instance",
  1225  	},
  1226  	"einsteindb_flush_messages_total_num": {
  1227  		PromQL:  `sum(increase(einsteindb_server_raft_message_flush_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1228  		Labels:  []string{"instance"},
  1229  		Comment: "The total number of Raft messages flushed by each EinsteinDB instance",
  1230  	},
  1231  
  1232  	"einsteindb_receive_messages": {
  1233  		PromQL:  `sum(rate(einsteindb_server_raft_message_recv_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1234  		Labels:  []string{"instance"},
  1235  		Comment: "The number of Raft messages received by each EinsteinDB instance",
  1236  	},
  1237  	"einsteindb_receive_messages_total_num": {
  1238  		PromQL:  `sum(increase(einsteindb_server_raft_message_recv_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1239  		Labels:  []string{"instance"},
  1240  		Comment: "The total number of Raft messages received by each EinsteinDB instance",
  1241  	},
  1242  	"einsteindb_raft_dropped_messages": {
  1243  		PromQL:  `sum(rate(einsteindb_raftstore_raft_dropped_message_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1244  		Labels:  []string{"instance", "type"},
  1245  		Comment: "The number of dropped Raft messages per type",
  1246  	},
  1247  	"einsteindb_raft_dropped_messages_total": {
  1248  		PromQL:  `sum(increase(einsteindb_raftstore_raft_dropped_message_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1249  		Labels:  []string{"instance", "type"},
  1250  		Comment: "The total number of dropped Raft messages per type",
  1251  	},
  1252  	"einsteindb_raft_proposals_per_ready": {
  1253  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_apply_proposal_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance))`,
  1254  		Labels:   []string{"instance"},
  1255  		Quantile: 0.99,
  1256  		Comment:  "The quantile proposal count of all Regions in a mio tick",
  1257  	},
  1258  	"einsteindb_raft_proposals": {
  1259  		PromQL:  `sum(rate(einsteindb_raftstore_proposal_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1260  		Labels:  []string{"instance", "type"},
  1261  		Comment: "The number of proposals per type in raft",
  1262  	},
  1263  	"einsteindb_raft_proposals_total_num": {
  1264  		PromQL:  `sum(increase(einsteindb_raftstore_proposal_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1265  		Labels:  []string{"instance", "type"},
  1266  		Comment: "The total number of proposals per type in raft",
  1267  	},
  1268  	"einsteindb_raftstore_propose_wait_duration": {
  1269  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_request_wait_time_duration_secs_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1270  		Labels:   []string{"instance"},
  1271  		Quantile: 0.99,
  1272  		Comment:  "The quantile wait time of each proposal",
  1273  	},
  1274  	"einsteindb_propose_avg_wait_duration": {
  1275  		PromQL:  `sum(rate(einsteindb_raftstore_request_wait_time_duration_secs_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_raftstore_request_wait_time_duration_secs_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1276  		Labels:  []string{"instance"},
  1277  		Comment: "The average wait time of each proposal",
  1278  	},
  1279  	"einsteindb_raftstore_apply_wait_duration": {
  1280  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_apply_wait_time_duration_secs_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1281  		Labels:   []string{"instance"},
  1282  		Quantile: 0.99,
  1283  	},
  1284  	"einsteindb_apply_avg_wait_duration": {
  1285  		PromQL: `sum(rate(einsteindb_raftstore_apply_wait_time_duration_secs_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_raftstore_apply_wait_time_duration_secs_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1286  		Labels: []string{"instance"},
  1287  	},
  1288  	"einsteindb_raft_log_speed": {
  1289  		PromQL:  `avg(rate(einsteindb_raftstore_propose_log_size_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1290  		Labels:  []string{"instance"},
  1291  		Comment: "The rate at which peers propose logs",
  1292  	},
  1293  	"einsteindb_admin_apply": {
  1294  		PromQL:  `sum(rate(einsteindb_raftstore_admin_cmd_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,status,instance)`,
  1295  		Labels:  []string{"instance", "type", "status"},
  1296  		Comment: "The number of the processed apply command",
  1297  	},
  1298  	"einsteindb_check_split": {
  1299  		PromQL:  `sum(rate(einsteindb_raftstore_check_split_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1300  		Labels:  []string{"instance", "type"},
  1301  		Comment: "The number of raftstore split checks",
  1302  	},
  1303  	"einsteindb_check_split_duration": {
  1304  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_check_split_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le, instance))`,
  1305  		Labels:   []string{"instance"},
  1306  		Quantile: 0.9999,
  1307  		Comment:  "The quantile of time consumed when running split check in .9999",
  1308  	},
  1309  	"einsteindb_local_reader_reject_requests": {
  1310  		PromQL:  `sum(rate(einsteindb_raftstore_local_read_reject_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, reason)`,
  1311  		Labels:  []string{"instance", "reason"},
  1312  		Comment: "The number of rejections from the local read thread",
  1313  	},
  1314  	"einsteindb_local_reader_execute_requests": {
  1315  		PromQL:  `sum(rate(einsteindb_raftstore_local_read_executed_requests{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1316  		Labels:  []string{"instance"},
  1317  		Comment: "The number of total requests from the local read thread",
  1318  	},
  1319  	"einsteindb_storage_command_ops": {
  1320  		PromQL:  `sum(rate(einsteindb_storage_command_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1321  		Labels:  []string{"instance", "type"},
  1322  		Comment: "The total count of different HoTTs of commands received per seconds",
  1323  	},
  1324  	"einsteindb_storage_async_request_duration": {
  1325  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_storage_engine_async_request_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,type))`,
  1326  		Labels:   []string{"instance", "type"},
  1327  		Quantile: 0.99,
  1328  		Comment:  "The quantile of time consumed by processing asynchronous snapshot requests",
  1329  	},
  1330  	"einsteindb_storage_async_request_avg_duration": {
  1331  		PromQL:  `sum(rate(einsteindb_storage_engine_async_request_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_storage_engine_async_request_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1332  		Labels:  []string{"instance", "type"},
  1333  		Comment: "The time consumed by processing asynchronous snapshot requests",
  1334  	},
  1335  	"einsteindb_scheduler_writing_bytes": {
  1336  		PromQL:  `sum(einsteindb_scheduler_writing_bytes{$LABEL_CONDITIONS}) by (instance)`,
  1337  		Labels:  []string{"instance"},
  1338  		Comment: "The total writing bytes of commands on each stage",
  1339  	},
  1340  	"einsteindb_scheduler_priority_commands": {
  1341  		PromQL:  `sum(rate(einsteindb_scheduler_commands_pri_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (priority,instance)`,
  1342  		Labels:  []string{"instance", "priority"},
  1343  		Comment: "The count of different priority commands",
  1344  	},
  1345  
  1346  	"einsteindb_scheduler_pending_commands": {
  1347  		PromQL:  `sum(einsteindb_scheduler_contex_total{$LABEL_CONDITIONS}) by (instance)`,
  1348  		Labels:  []string{"instance"},
  1349  		Comment: "The count of pending commands per EinsteinDB instance",
  1350  	},
  1351  	"einsteindb_scheduler_command_duration": {
  1352  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_scheduler_command_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,type))`,
  1353  		Labels:   []string{"instance", "type"},
  1354  		Quantile: 0.99,
  1355  		Comment:  "The quantile of time consumed when executing command",
  1356  	},
  1357  	"einsteindb_scheduler_command_avg_duration": {
  1358  		PromQL:  `sum(rate(einsteindb_scheduler_command_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_scheduler_command_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) `,
  1359  		Labels:  []string{"instance", "type"},
  1360  		Comment: "The average time consumed when executing command",
  1361  	},
  1362  	"einsteindb_scheduler_latch_wait_duration": {
  1363  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_scheduler_latch_wait_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,type))`,
  1364  		Labels:   []string{"instance", "type"},
  1365  		Quantile: 0.99,
  1366  		Comment:  "The quantile time which is caused by latch wait in command",
  1367  	},
  1368  	"einsteindb_scheduler_latch_wait_avg_duration": {
  1369  		PromQL:  `sum(rate(einsteindb_scheduler_latch_wait_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_scheduler_latch_wait_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) `,
  1370  		Labels:  []string{"instance", "type"},
  1371  		Comment: "The average time which is caused by latch wait in command",
  1372  	},
  1373  	"einsteindb_scheduler_processing_read_duration": {
  1374  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_scheduler_processing_read_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,type))`,
  1375  		Labels:   []string{"instance", "type"},
  1376  		Quantile: 0.99,
  1377  		Comment:  "The quantile time of scheduler processing read in command",
  1378  	},
  1379  	"einsteindb_scheduler_processing_read_total_count": {
  1380  		PromQL:  "sum(increase(einsteindb_scheduler_processing_read_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  1381  		Labels:  []string{"instance", "type"},
  1382  		Comment: "The total count of scheduler processing read in command",
  1383  	},
  1384  	"einsteindb_scheduler_processing_read_total_time": {
  1385  		PromQL:  "sum(increase(einsteindb_scheduler_processing_read_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  1386  		Labels:  []string{"instance", "type"},
  1387  		Comment: "The total time of scheduler processing read in command",
  1388  	},
  1389  
  1390  	"einsteindb_scheduler_keys_read": {
  1391  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_scheduler_ekv_command_key_read_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,type))`,
  1392  		Labels:   []string{"instance", "type"},
  1393  		Quantile: 0.99,
  1394  		Comment:  "The quantile count of keys read by command",
  1395  	},
  1396  	"einsteindb_scheduler_keys_read_avg": {
  1397  		PromQL:  `sum(rate(einsteindb_scheduler_ekv_command_key_read_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_scheduler_ekv_command_key_read_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) `,
  1398  		Labels:  []string{"instance", "type"},
  1399  		Comment: "The average count of keys read by command",
  1400  	},
  1401  	"einsteindb_scheduler_keys_written": {
  1402  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_scheduler_ekv_command_key_write_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,type))`,
  1403  		Labels:   []string{"instance", "type"},
  1404  		Quantile: 0.99,
  1405  		Comment:  "The quantile of count of keys written by a command",
  1406  	},
  1407  	"einsteindb_scheduler_keys_written_avg": {
  1408  		PromQL:  `sum(rate(einsteindb_scheduler_ekv_command_key_write_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_scheduler_ekv_command_key_write_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) `,
  1409  		Labels:  []string{"instance", "type"},
  1410  		Comment: "The average count of keys written by a command",
  1411  	},
  1412  	"einsteindb_scheduler_scan_details": {
  1413  		PromQL:  `sum(rate(einsteindb_scheduler_ekv_scan_details{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (tag,instance,req,cf)`,
  1414  		Labels:  []string{"instance", "tag", "req", "cf"},
  1415  		Comment: "The keys scan details of each CF when executing command",
  1416  	},
  1417  	"einsteindb_scheduler_scan_details_total_num": {
  1418  		PromQL: `sum(increase(einsteindb_scheduler_ekv_scan_details{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (tag,instance,req,cf)`,
  1419  		Labels: []string{"instance", "tag", "req", "cf"},
  1420  	},
  1421  	"einsteindb_mvcc_versions": {
  1422  		PromQL:  `sum(rate(einsteindb_storage_mvcc_versions_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1423  		Labels:  []string{"instance"},
  1424  		Comment: "The number of versions for each key",
  1425  	},
  1426  	"einsteindb_mvcc_delete_versions": {
  1427  		PromQL:  `sum(rate(einsteindb_storage_mvcc_gc_delete_versions_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1428  		Labels:  []string{"instance"},
  1429  		Comment: "The number of versions deleted by GC for each key",
  1430  	},
  1431  	"einsteindb_gc_tasks_ops": {
  1432  		PromQL:  `sum(rate(einsteindb_gcworker_gc_tasks_vec{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (task,instance)`,
  1433  		Labels:  []string{"instance", "task"},
  1434  		Comment: "The count of GC total tasks processed by gc_worker per second",
  1435  	},
  1436  	"einsteindb_gc_skipped_tasks": {
  1437  		PromQL:  `sum(rate(einsteindb_storage_gc_skipped_counter{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (task,instance)`,
  1438  		Labels:  []string{"instance", "task"},
  1439  		Comment: "The count of GC skipped tasks processed by gc_worker",
  1440  	},
  1441  	"einsteindb_gc_fail_tasks": {
  1442  		PromQL:  `sum(rate(einsteindb_gcworker_gc_task_fail_vec{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (task,instance)`,
  1443  		Labels:  []string{"instance", "task"},
  1444  		Comment: "The count of GC tasks processed fail by gc_worker",
  1445  	},
  1446  	"einsteindb_gc_too_busy": {
  1447  		PromQL:  `sum(rate(einsteindb_gc_worker_too_busy{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1448  		Labels:  []string{"instance"},
  1449  		Comment: "The count of GC worker too busy",
  1450  	},
  1451  	"einsteindb_gc_tasks_duration": {
  1452  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_gcworker_gc_task_duration_vec_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,task,instance))`,
  1453  		Labels:   []string{"instance", "task"},
  1454  		Quantile: 1,
  1455  		Comment:  "The quantile of time consumed when executing GC tasks",
  1456  	},
  1457  	"einsteindb_gc_tasks_avg_duration": {
  1458  		PromQL:  `sum(rate(einsteindb_gcworker_gc_task_duration_vec_sum{}[$RANGE_DURATION])) by (task,instance) / sum(rate(einsteindb_gcworker_gc_task_duration_vec_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (task,instance)`,
  1459  		Labels:  []string{"instance", "task"},
  1460  		Comment: "The time consumed when executing GC tasks",
  1461  	},
  1462  	"einsteindb_gc_keys": {
  1463  		PromQL:  `sum(rate(einsteindb_gcworker_gc_keys{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (tag,cf,instance)`,
  1464  		Labels:  []string{"instance", "tag", "cf"},
  1465  		Comment: "The count of keys in write CF affected during GC",
  1466  	},
  1467  	"einsteindb_gc_keys_total_num": {
  1468  		PromQL:  `sum(increase(einsteindb_gcworker_gc_keys{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (tag,cf,instance)`,
  1469  		Labels:  []string{"instance", "tag", "cf"},
  1470  		Comment: "The total number of keys in write CF affected during GC",
  1471  	},
  1472  	"einsteindb_gc_speed": {
  1473  		PromQL:  `sum(rate(einsteindb_storage_mvcc_gc_delete_versions_sum[$RANGE_DURATION]))`,
  1474  		Comment: "The GC keys per second",
  1475  	},
  1476  	"einsteindb_auto_gc_working": {
  1477  		PromQL: `sum(max_over_time(einsteindb_gcworker_autogc_status{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,state)`,
  1478  		Labels: []string{"instance", "state"},
  1479  	},
  1480  	"einsteindb_client_task_progress": {
  1481  		PromQL:  `max(milevadb_einsteindbclient_range_task_stats{$LABEL_CONDITIONS}) by (result,type)`,
  1482  		Labels:  []string{"result", "type"},
  1483  		Comment: "The progress of einsteindb client task",
  1484  	},
  1485  	"einsteindb_auto_gc_progress": {
  1486  		PromQL:  `sum(einsteindb_gcworker_autogc_processed_regions{type="scan"}) by (instance,type) / sum(einsteindb_raftstore_region_count{type="region"}) by (instance)`,
  1487  		Labels:  []string{"instance"},
  1488  		Comment: "Progress of EinsteinDB's GC",
  1489  	},
  1490  	"einsteindb_auto_gc_safepoint": {
  1491  		PromQL:  `max(einsteindb_gcworker_autogc_safe_point{$LABEL_CONDITIONS}) by (instance) / (2^18)`,
  1492  		Labels:  []string{"instance"},
  1493  		Comment: "SafePoint used for EinsteinDB's Auto GC",
  1494  	},
  1495  	"einsteindb_send_snapshot_duration": {
  1496  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_server_send_snapshot_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1497  		Labels:   []string{"instance"},
  1498  		Quantile: 0.99,
  1499  		Comment:  "The quantile of time consumed when sending snapshots",
  1500  	},
  1501  	"einsteindb_handle_snapshot_duration": {
  1502  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_raftstore_snapshot_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,type))`,
  1503  		Labels:   []string{"instance", "type"},
  1504  		Quantile: 0.99,
  1505  		Comment:  "The quantile of time consumed when handling snapshots",
  1506  	},
  1507  	"einsteindb_snapshot_state_count": {
  1508  		PromQL:  `sum(einsteindb_raftstore_snapshot_traffic_total{$LABEL_CONDITIONS}) by (type,instance)`,
  1509  		Labels:  []string{"instance", "type"},
  1510  		Comment: "The number of snapshots in different states",
  1511  	},
  1512  	"einsteindb_snapshot_state_total_count": {
  1513  		PromQL:  `sum(delta(einsteindb_raftstore_snapshot_traffic_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1514  		Labels:  []string{"instance", "type"},
  1515  		Comment: "The total number of snapshots in different states",
  1516  	},
  1517  	"einsteindb_snapshot_size": {
  1518  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_snapshot_size_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1519  		Labels:   []string{"instance"},
  1520  		Quantile: 0.9999,
  1521  		Comment:  "The quantile of snapshot size",
  1522  	},
  1523  	"einsteindb_snapshot_ekv_count": {
  1524  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_snapshot_ekv_count_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1525  		Labels:   []string{"instance"},
  1526  		Quantile: 0.9999,
  1527  		Comment:  "The quantile of number of KV within a snapshot",
  1528  	},
  1529  	"einsteindb_worker_handled_tasks": {
  1530  		PromQL:  `sum(rate(einsteindb_worker_handled_task_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (name,instance)`,
  1531  		Labels:  []string{"instance", "name"},
  1532  		Comment: "The number of tasks handled by worker",
  1533  	},
  1534  	"einsteindb_worker_handled_tasks_total_num": {
  1535  		PromQL:  `sum(increase(einsteindb_worker_handled_task_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (name,instance)`,
  1536  		Labels:  []string{"instance", "name"},
  1537  		Comment: "Total number of tasks handled by worker",
  1538  	},
  1539  	"einsteindb_worker_pending_tasks": {
  1540  		PromQL:  `sum(rate(einsteindb_worker_pending_task_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (name,instance)`,
  1541  		Labels:  []string{"instance", "name"},
  1542  		Comment: "Current pending and running tasks of worker",
  1543  	},
  1544  	"einsteindb_worker_pending_tasks_total_num": {
  1545  		PromQL:  `sum(increase(einsteindb_worker_pending_task_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (name,instance)`,
  1546  		Labels:  []string{"instance", "name"},
  1547  		Comment: "Total pending and running tasks of worker",
  1548  	},
  1549  	"einsteindb_futurepool_handled_tasks": {
  1550  		PromQL:  `sum(rate(einsteindb_futurepool_handled_task_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (name,instance)`,
  1551  		Labels:  []string{"instance", "name"},
  1552  		Comment: "The number of tasks handled by future_pool",
  1553  	},
  1554  	"einsteindb_futurepool_handled_tasks_total_num": {
  1555  		PromQL:  `sum(increase(einsteindb_futurepool_handled_task_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (name,instance)`,
  1556  		Labels:  []string{"instance", "name"},
  1557  		Comment: "Total number of tasks handled by future_pool",
  1558  	},
  1559  	"einsteindb_futurepool_pending_tasks": {
  1560  		PromQL:  `sum(rate(einsteindb_futurepool_pending_task_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (name,instance)`,
  1561  		Labels:  []string{"instance", "name"},
  1562  		Comment: "Current pending and running tasks of future_pool",
  1563  	},
  1564  	"einsteindb_futurepool_pending_tasks_total_num": {
  1565  		PromQL:  `sum(increase(einsteindb_futurepool_pending_task_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (name,instance)`,
  1566  		Labels:  []string{"instance", "name"},
  1567  		Comment: "Total pending and running tasks of future_pool",
  1568  	},
  1569  	"einsteindb_cop_request_durations": {
  1570  		PromQL:  `sum(rate(einsteindb_coprocessor_request_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,req)`,
  1571  		Labels:  []string{"instance", "req"},
  1572  		Comment: "The time consumed to handle interlock read requests",
  1573  	},
  1574  	"einsteindb_cop_request_duration": {
  1575  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_coprocessor_request_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,req,instance))`,
  1576  		Labels:   []string{"instance", "req"},
  1577  		Quantile: 1,
  1578  		Comment:  "The quantile of time consumed to handle interlock read requests",
  1579  	},
  1580  	"einsteindb_cop_requests_ops": {
  1581  		PromQL: `sum(rate(einsteindb_coprocessor_request_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (req,instance)`,
  1582  		Labels: []string{"instance", "req"},
  1583  	},
  1584  	"einsteindb_cop_scan_keys_num": {
  1585  		PromQL: `sum(rate(einsteindb_coprocessor_scan_keys_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (req,instance)`,
  1586  		Labels: []string{"instance", "req"},
  1587  	},
  1588  	"einsteindb_cop_ekv_cursor_operations": {
  1589  		PromQL:   `histogram_quantile($QUANTILE, avg(rate(einsteindb_coprocessor_scan_keys_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,req,instance)) `,
  1590  		Labels:   []string{"instance", "req"},
  1591  		Quantile: 1,
  1592  	},
  1593  	"einsteindb_cop_total_lmdb_perf_statistics": {
  1594  		PromQL: `sum(rate(einsteindb_coprocessor_lmdb_perf{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (req,metric,instance)`,
  1595  		Labels: []string{"instance", "req", "metric"},
  1596  	},
  1597  	"einsteindb_cop_total_response_size_per_seconds": {
  1598  		PromQL: `sum(rate(einsteindb_coprocessor_response_bytes{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  1599  		Labels: []string{"instance"},
  1600  	},
  1601  	"einsteindb_cop_handle_duration": {
  1602  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_coprocessor_request_handle_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,req,instance))`,
  1603  		Labels:   []string{"instance", "req"},
  1604  		Quantile: 1,
  1605  		Comment:  "The quantile of time consumed when handling interlock requests",
  1606  	},
  1607  	"einsteindb_cop_wait_duration": {
  1608  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_coprocessor_request_wait_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,req,type,instance))`,
  1609  		Labels:   []string{"instance", "req", "type"},
  1610  		Quantile: 1,
  1611  		Comment:  "The quantile of time consumed when interlock requests are wait for being handled",
  1612  	},
  1613  	"einsteindb_cop_posetPosetDag_requests_ops": {
  1614  		PromQL: `sum(rate(einsteindb_coprocessor_posetPosetDag_request_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (vec_type,instance)`,
  1615  		Labels: []string{"instance", "vec_type"},
  1616  	},
  1617  	"einsteindb_cop_posetPosetDag_interlocks_ops": {
  1618  		PromQL:  `sum(rate(einsteindb_coprocessor_interlock_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1619  		Labels:  []string{"instance", "type"},
  1620  		Comment: "The number of PosetDag interlocks per seconds",
  1621  	},
  1622  	"einsteindb_cop_scan_details": {
  1623  		PromQL: `sum(rate(einsteindb_coprocessor_scan_details{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (tag,req,cf,instance)`,
  1624  		Labels: []string{"instance", "tag", "req", "cf"},
  1625  	},
  1626  	"einsteindb_cop_scan_details_total": {
  1627  		PromQL: `sum(increase(einsteindb_coprocessor_scan_details{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (tag,req,cf,instance)`,
  1628  		Labels: []string{"instance", "tag", "req", "cf"},
  1629  	},
  1630  
  1631  	"einsteindb_threads_state": {
  1632  		PromQL: `sum(einsteindb_threads_state{$LABEL_CONDITIONS}) by (instance,state)`,
  1633  		Labels: []string{"instance", "state"},
  1634  	},
  1635  	"einsteindb_threads_io": {
  1636  		PromQL: `sum(rate(einsteindb_threads_io_bytes_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (name,io,instance)`,
  1637  		Labels: []string{"instance", "io", "name"},
  1638  	},
  1639  	"einsteindb_thread_voluntary_context_switches": {
  1640  		PromQL: `sum(rate(einsteindb_thread_voluntary_context_switches{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, name)`,
  1641  		Labels: []string{"instance", "name"},
  1642  	},
  1643  	"einsteindb_thread_nonvoluntary_context_switches": {
  1644  		PromQL: `sum(rate(einsteindb_thread_nonvoluntary_context_switches{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, name)`,
  1645  		Labels: []string{"instance", "name"},
  1646  	},
  1647  	"einsteindb_engine_get_cpu_cache_operations": {
  1648  		PromQL:  `sum(rate(einsteindb_engine_get_served{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,type,instance)`,
  1649  		Labels:  []string{"instance", "type", "EDB"},
  1650  		Comment: "The count of get l0,l1,l2 operations",
  1651  	},
  1652  	"einsteindb_engine_get_block_cache_operations": {
  1653  		PromQL:  `sum(rate(einsteindb_engine_cache_efficiency{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,type,instance)`,
  1654  		Labels:  []string{"instance", "type", "EDB"},
  1655  		Comment: "The count of get memblock operations",
  1656  	},
  1657  
  1658  	"einsteindb_engine_get_memblock_operations": {
  1659  		PromQL:  `sum(rate(einsteindb_engine_memblock_efficiency{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,type,instance)`,
  1660  		Labels:  []string{"instance", "type", "EDB"},
  1661  		Comment: "The count of get memblock operations",
  1662  	},
  1663  	"einsteindb_engine_max_get_duration": {
  1664  		PromQL:  `max(einsteindb_engine_get_micro_seconds{$LABEL_CONDITIONS}) by (EDB,type,instance)`,
  1665  		Labels:  []string{"instance", "type", "EDB"},
  1666  		Comment: "The max time consumed when executing get operations, the unit is microsecond",
  1667  	},
  1668  	"einsteindb_engine_avg_get_duration": {
  1669  		PromQL:  `avg(einsteindb_engine_get_micro_seconds{$LABEL_CONDITIONS}) by (EDB,type,instance)`,
  1670  		Labels:  []string{"instance", "type", "EDB"},
  1671  		Comment: "The average time consumed when executing get operations, the unit is microsecond",
  1672  	},
  1673  	"einsteindb_engine_seek_operations": {
  1674  		PromQL:  `sum(rate(einsteindb_engine_locate{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,type,instance)`,
  1675  		Labels:  []string{"instance", "type", "EDB"},
  1676  		Comment: "The count of seek operations",
  1677  	},
  1678  	"einsteindb_engine_max_seek_duration": {
  1679  		PromQL:  `max(einsteindb_engine_seek_micro_seconds{$LABEL_CONDITIONS}) by (EDB,type,instance)`,
  1680  		Labels:  []string{"instance", "type", "EDB"},
  1681  		Comment: "The time consumed when executing seek operation, the unit is microsecond",
  1682  	},
  1683  	"einsteindb_engine_avg_seek_duration": {
  1684  		PromQL:  `avg(einsteindb_engine_seek_micro_seconds{$LABEL_CONDITIONS}) by (EDB,type,instance)`,
  1685  		Labels:  []string{"instance", "type", "EDB"},
  1686  		Comment: "The time consumed when executing seek operation, the unit is microsecond",
  1687  	},
  1688  	"einsteindb_engine_write_operations": {
  1689  		PromQL:  `sum(rate(einsteindb_engine_write_served{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,type,instance)`,
  1690  		Labels:  []string{"instance", "type", "EDB"},
  1691  		Comment: "The count of write operations",
  1692  	},
  1693  	"einsteindb_engine_write_duration": {
  1694  		PromQL:  `avg(einsteindb_engine_write_micro_seconds{$LABEL_CONDITIONS}) by (EDB,type,instance)`,
  1695  		Labels:  []string{"instance", "type", "EDB"},
  1696  		Comment: "The time consumed when executing write operation, the unit is microsecond",
  1697  	},
  1698  	"einsteindb_engine_write_max_duration": {
  1699  		PromQL:  `max(einsteindb_engine_write_micro_seconds{$LABEL_CONDITIONS}) by (EDB,type,instance)`,
  1700  		Labels:  []string{"instance", "type", "EDB"},
  1701  		Comment: "The time consumed when executing write operation, the unit is microsecond",
  1702  	},
  1703  	"einsteindb_engine_wal_sync_operations": {
  1704  		PromQL:  `sum(rate(einsteindb_engine_wal_file_synced{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,instance)`,
  1705  		Labels:  []string{"instance", "EDB"},
  1706  		Comment: "The count of WAL sync operations",
  1707  	},
  1708  
  1709  	"einsteindb_wal_sync_max_duration": {
  1710  		PromQL:  `max(einsteindb_engine_wal_file_sync_micro_seconds{$LABEL_CONDITIONS}) by (EDB,type,instance)`,
  1711  		Labels:  []string{"instance", "type", "EDB"},
  1712  		Comment: "The max time consumed when executing WAL sync operation, the unit is microsecond",
  1713  	},
  1714  	"einsteindb_wal_sync_duration": {
  1715  		PromQL:  `avg(einsteindb_engine_wal_file_sync_micro_seconds{$LABEL_CONDITIONS}) by (EDB,type,instance)`,
  1716  		Labels:  []string{"instance", "type"},
  1717  		Comment: "The time consumed when executing WAL sync operation, the unit is microsecond",
  1718  	},
  1719  	"einsteindb_compaction_operations": {
  1720  		PromQL:  `sum(rate(einsteindb_engine_event_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance,EDB)`,
  1721  		Labels:  []string{"instance", "type", "EDB"},
  1722  		Comment: "The count of compaction and flush operations",
  1723  	},
  1724  	"einsteindb_compaction_max_duration": {
  1725  		PromQL:  `max(einsteindb_engine_compaction_time{$LABEL_CONDITIONS}) by (type,instance,EDB)`,
  1726  		Labels:  []string{"instance", "type", "EDB"},
  1727  		Comment: "The time consumed when executing the compaction and flush operations",
  1728  	},
  1729  	"einsteindb_compaction_duration": {
  1730  		PromQL:  `avg(einsteindb_engine_compaction_time{$LABEL_CONDITIONS}) by (type,instance,EDB)`,
  1731  		Labels:  []string{"instance", "type", "EDB"},
  1732  		Comment: "The time consumed when executing the compaction and flush operations",
  1733  	},
  1734  	"einsteindb_sst_read_max_duration": {
  1735  		PromQL:  `max(einsteindb_engine_sst_read_micros{$LABEL_CONDITIONS}) by (type,instance,EDB)`,
  1736  		Labels:  []string{"instance", "type", "EDB"},
  1737  		Comment: "The max time consumed when reading SST files",
  1738  	},
  1739  	"einsteindb_sst_read_duration": {
  1740  		PromQL:  `avg(einsteindb_engine_sst_read_micros{$LABEL_CONDITIONS}) by (type,instance,EDB)`,
  1741  		Labels:  []string{"instance", "type", "EDB"},
  1742  		Comment: "The time consumed when reading SST files",
  1743  	},
  1744  	"einsteindb_write_stall_max_duration": {
  1745  		PromQL:  `max(einsteindb_engine_write_stall{$LABEL_CONDITIONS}) by (type,instance,EDB)`,
  1746  		Labels:  []string{"instance", "type", "EDB"},
  1747  		Comment: "The time which is caused by write stall",
  1748  	},
  1749  	"einsteindb_write_stall_avg_duration": {
  1750  		PromQL:  `avg(einsteindb_engine_write_stall{$LABEL_CONDITIONS}) by (type,instance,EDB)`,
  1751  		Labels:  []string{"instance", "type", "EDB"},
  1752  		Comment: "The time which is caused by write stall",
  1753  	},
  1754  	"einsteindb_memblock_size": {
  1755  		PromQL:  `avg(einsteindb_engine_memory_bytes{$LABEL_CONDITIONS}) by (type,instance,EDB,cf)`,
  1756  		Labels:  []string{"instance", "cf", "type", "EDB"},
  1757  		Comment: "The memblock size of each defCausumn family",
  1758  	},
  1759  	"einsteindb_memblock_hit": {
  1760  		PromQL:  `sum(rate(einsteindb_engine_memblock_efficiency{type="memblock_hit"}[$RANGE_DURATION])) by (instance,EDB) / (sum(rate(einsteindb_engine_memblock_efficiency{}[$RANGE_DURATION])) by (instance,EDB) + sum(rate(einsteindb_engine_memblock_efficiency{}[$RANGE_DURATION])) by (instance,EDB))`,
  1761  		Labels:  []string{"instance", "EDB"},
  1762  		Comment: "The hit rate of memblock",
  1763  	},
  1764  	"einsteindb_block_cache_size": {
  1765  		PromQL:  `topk(20, avg(einsteindb_engine_block_cache_size_bytes{$LABEL_CONDITIONS}) by(cf, instance, EDB))`,
  1766  		Labels:  []string{"instance", "cf", "EDB"},
  1767  		Comment: "The causet cache size. Broken down by defCausumn family if shared causet cache is disabled.",
  1768  	},
  1769  	"einsteindb_block_all_cache_hit": {
  1770  		PromQL:  `sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_hit"}[$RANGE_DURATION])) by (EDB,instance) / (sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_hit"}[$RANGE_DURATION])) by (EDB,instance) + sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_miss"}[$RANGE_DURATION])) by (EDB,instance))`,
  1771  		Labels:  []string{"instance", "EDB"},
  1772  		Comment: "The hit rate of all causet cache",
  1773  	},
  1774  	"einsteindb_block_data_cache_hit": {
  1775  		PromQL:  `sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_data_hit"}[$RANGE_DURATION])) by (EDB,instance) / (sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_data_hit"}[$RANGE_DURATION])) by (EDB,instance) + sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_data_miss"}[$RANGE_DURATION])) by (EDB,instance))`,
  1776  		Labels:  []string{"instance", "EDB"},
  1777  		Comment: "The hit rate of data causet cache",
  1778  	},
  1779  	"einsteindb_block_filter_cache_hit": {
  1780  		PromQL:  `sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_filter_hit"}[$RANGE_DURATION])) by (EDB,instance) / (sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_filter_hit"}[$RANGE_DURATION])) by (EDB,instance) + sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_filter_miss"}[$RANGE_DURATION])) by (EDB,instance))`,
  1781  		Labels:  []string{"instance", "EDB"},
  1782  		Comment: "The hit rate of data causet cache",
  1783  	},
  1784  	"einsteindb_block_index_cache_hit": {
  1785  		PromQL:  `sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_index_hit"}[$RANGE_DURATION])) by (EDB,instance) / (sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_index_hit"}[$RANGE_DURATION])) by (EDB,instance) + sum(rate(einsteindb_engine_cache_efficiency{type="block_cache_index_miss"}[$RANGE_DURATION])) by (EDB,instance))`,
  1786  		Labels:  []string{"instance", "EDB"},
  1787  		Comment: "The hit rate of data causet cache",
  1788  	},
  1789  	"einsteindb_block_bloom_prefix_cache_hit": {
  1790  		PromQL:  `sum(rate(einsteindb_engine_bloom_efficiency{type="bloom_prefix_useful"}[$RANGE_DURATION])) by (EDB,instance) / sum(rate(einsteindb_engine_bloom_efficiency{type="bloom_prefix_checked"}[$RANGE_DURATION])) by (EDB,instance)`,
  1791  		Labels:  []string{"instance", "EDB"},
  1792  		Comment: "The hit rate of data causet cache",
  1793  	},
  1794  	"einsteindb_corrrput_keys_flow": {
  1795  		PromQL:  `sum(rate(einsteindb_engine_compaction_num_corrupt_keys{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,cf,instance)`,
  1796  		Labels:  []string{"instance", "EDB", "cf"},
  1797  		Comment: "The flow of corrupt operations on keys",
  1798  	},
  1799  	"einsteindb_total_keys": {
  1800  		PromQL:  `sum(einsteindb_engine_estimate_num_keys{$LABEL_CONDITIONS}) by (EDB,cf,instance)`,
  1801  		Labels:  []string{"instance", "EDB", "cf"},
  1802  		Comment: "The count of keys in each defCausumn family",
  1803  	},
  1804  	"einsteindb_per_read_max_bytes": {
  1805  		PromQL:  `max(einsteindb_engine_bytes_per_read{$LABEL_CONDITIONS}) by (type,EDB,instance)`,
  1806  		Labels:  []string{"instance", "type", "EDB"},
  1807  		Comment: "The max bytes per read",
  1808  	},
  1809  	"einsteindb_per_read_avg_bytes": {
  1810  		PromQL:  `avg(einsteindb_engine_bytes_per_read{$LABEL_CONDITIONS}) by (type,EDB,instance)`,
  1811  		Labels:  []string{"instance", "type", "EDB"},
  1812  		Comment: "The avg bytes per read",
  1813  	},
  1814  	"einsteindb_per_write_max_bytes": {
  1815  		PromQL:  `max(einsteindb_engine_bytes_per_write{$LABEL_CONDITIONS}) by (type,EDB,instance)`,
  1816  		Labels:  []string{"instance", "type", "EDB"},
  1817  		Comment: "The max bytes per write",
  1818  	},
  1819  	"einsteindb_per_write_avg_bytes": {
  1820  		PromQL:  `avg(einsteindb_engine_bytes_per_write{$LABEL_CONDITIONS}) by (type,EDB,instance)`,
  1821  		Labels:  []string{"instance", "type", "EDB"},
  1822  		Comment: "The avg bytes per write",
  1823  	},
  1824  	"einsteindb_engine_compaction_flow_bytes": {
  1825  		PromQL:  `sum(rate(einsteindb_engine_compaction_flow_bytes{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,type,instance)`,
  1826  		Labels:  []string{"instance", "type", "EDB"},
  1827  		Comment: "The flow rate of compaction operations per type",
  1828  	},
  1829  	"einsteindb_compaction_pending_bytes": {
  1830  		PromQL:  `sum(rate(einsteindb_engine_pending_compaction_bytes{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (cf,instance,EDB)`,
  1831  		Labels:  []string{"instance", "cf", "EDB"},
  1832  		Comment: "The pending bytes to be compacted",
  1833  	},
  1834  	"einsteindb_read_amplication": {
  1835  		PromQL:  `sum(rate(einsteindb_engine_read_amp_flow_bytes{type="read_amp_total_read_bytes"}[$RANGE_DURATION])) by (instance,EDB) / sum(rate(einsteindb_engine_read_amp_flow_bytes{type="read_amp_estimate_useful_bytes"}[$RANGE_DURATION])) by (instance,EDB)`,
  1836  		Labels:  []string{"instance", "EDB"},
  1837  		Comment: "The read amplification per EinsteinDB instance",
  1838  	},
  1839  	"einsteindb_compression_ratio": {
  1840  		PromQL:  `avg(einsteindb_engine_compression_ratio{$LABEL_CONDITIONS}) by (level,instance,EDB)`,
  1841  		Labels:  []string{"instance", "level", "EDB"},
  1842  		Comment: "The compression ratio of each level",
  1843  	},
  1844  	"einsteindb_number_of_snapshots": {
  1845  		PromQL:  `einsteindb_engine_num_snapshots{$LABEL_CONDITIONS}`,
  1846  		Labels:  []string{"instance", "EDB"},
  1847  		Comment: "The number of snapshot of each EinsteinDB instance",
  1848  	},
  1849  	"einsteindb_oldest_snapshots_duration": {
  1850  		PromQL:  `einsteindb_engine_oldest_snapshot_duration{$LABEL_CONDITIONS}`,
  1851  		Labels:  []string{"instance", "EDB"},
  1852  		Comment: "The time that the oldest unreleased snapshot survivals",
  1853  	},
  1854  	"einsteindb_number_files_at_each_level": {
  1855  		PromQL:  `avg(einsteindb_engine_num_files_at_level{$LABEL_CONDITIONS}) by (cf, level,EDB,instance)`,
  1856  		Labels:  []string{"instance", "cf", "level", "EDB"},
  1857  		Comment: "The number of SST files for different defCausumn families in each level",
  1858  	},
  1859  	"einsteindb_ingest_sst_duration": {
  1860  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_snapshot_ingest_sst_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance,EDB))`,
  1861  		Labels:   []string{"instance", "EDB"},
  1862  		Quantile: 0.99,
  1863  		Comment:  "The quantile of time consumed when ingesting SST files",
  1864  	},
  1865  	"einsteindb_ingest_sst_avg_duration": {
  1866  		PromQL:  `sum(rate(einsteindb_snapshot_ingest_sst_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_snapshot_ingest_sst_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1867  		Labels:  []string{"instance"},
  1868  		Comment: "The average time consumed when ingesting SST files",
  1869  	},
  1870  	"einsteindb_stall_conditions_changed_of_each_cf": {
  1871  		PromQL:  `einsteindb_engine_stall_conditions_changed{$LABEL_CONDITIONS}`,
  1872  		Labels:  []string{"instance", "cf", "type", "EDB"},
  1873  		Comment: "Stall conditions changed of each defCausumn family",
  1874  	},
  1875  	"einsteindb_write_stall_reason": {
  1876  		PromQL: `sum(increase(einsteindb_engine_write_stall_reason{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,type,instance)`,
  1877  		Labels: []string{"instance", "type", "EDB"},
  1878  	},
  1879  	"einsteindb_compaction_reason": {
  1880  		PromQL: `sum(rate(einsteindb_engine_compaction_reason{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,cf,reason,instance)`,
  1881  		Labels: []string{"instance", "cf", "reason", "EDB"},
  1882  	},
  1883  	"einsteindb_engine_blob_key_max_size": {
  1884  		PromQL: `max(einsteindb_engine_blob_key_size{$LABEL_CONDITIONS}) by (EDB,instance,type)`,
  1885  		Labels: []string{"instance", "type", "EDB"},
  1886  	},
  1887  	"einsteindb_engine_blob_key_avg_size": {
  1888  		PromQL: `avg(einsteindb_engine_blob_key_size{$LABEL_CONDITIONS}) by (EDB,instance,type)`,
  1889  		Labels: []string{"instance", "type", "EDB"},
  1890  	},
  1891  	"einsteindb_engine_blob_value_avg_size": {
  1892  		PromQL: `avg(einsteindb_engine_blob_value_size{$LABEL_CONDITIONS}) by (EDB,instance,type)`,
  1893  		Labels: []string{"instance", "type", "EDB"},
  1894  	},
  1895  	"einsteindb_engine_blob_value_max_size": {
  1896  		PromQL: `max(einsteindb_engine_blob_value_size{$LABEL_CONDITIONS}) by (EDB,instance,type)`,
  1897  		Labels: []string{"instance", "type", "EDB"},
  1898  	},
  1899  	"einsteindb_engine_blob_seek_duration": {
  1900  		PromQL:  `avg(einsteindb_engine_blob_seek_micros_seconds{$LABEL_CONDITIONS}) by (EDB,type,instance)`,
  1901  		Labels:  []string{"instance", "type", "EDB"},
  1902  		Comment: "the unit is microsecond",
  1903  	},
  1904  	"einsteindb_engine_blob_seek_operations": {
  1905  		PromQL: `sum(rate(einsteindb_engine_blob_locate{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (EDB,type,instance)`,
  1906  		Labels: []string{"instance", "type", "EDB"},
  1907  	},
  1908  	"einsteindb_engine_blob_get_duration": {
  1909  		PromQL:  `avg(einsteindb_engine_blob_get_micros_seconds{$LABEL_CONDITIONS}) by (type,EDB,instance)`,
  1910  		Labels:  []string{"instance", "type", "EDB"},
  1911  		Comment: "the unit is microsecond",
  1912  	},
  1913  	"einsteindb_engine_blob_bytes_flow": {
  1914  		PromQL: `sum(rate(einsteindb_engine_blob_flow_bytes{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance,EDB)`,
  1915  		Labels: []string{"instance", "type", "EDB"},
  1916  	},
  1917  	"einsteindb_engine_blob_file_read_duration": {
  1918  		PromQL:  `avg(einsteindb_engine_blob_file_read_micros_seconds{$LABEL_CONDITIONS}) by (type,instance,EDB)`,
  1919  		Labels:  []string{"instance", "type", "EDB"},
  1920  		Comment: "the unit is microsecond",
  1921  	},
  1922  	"einsteindb_engine_blob_file_write_duration": {
  1923  		PromQL:  `avg(einsteindb_engine_blob_file_write_micros_seconds{$LABEL_CONDITIONS}) by (type,instance,EDB)`,
  1924  		Labels:  []string{"instance", "type", "EDB"},
  1925  		Comment: "the unit is microsecond",
  1926  	},
  1927  	"einsteindb_engine_blob_file_sync_operations": {
  1928  		PromQL: `sum(rate(einsteindb_engine_blob_file_synced{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1929  		Labels: []string{"instance"},
  1930  	},
  1931  	"einsteindb_engine_blob_file_sync_duration": {
  1932  		PromQL:  `avg(einsteindb_engine_blob_file_sync_micros_seconds{$LABEL_CONDITIONS}) by (instance,type,EDB)`,
  1933  		Labels:  []string{"instance", "type", "EDB"},
  1934  		Comment: "the unit is microsecond",
  1935  	},
  1936  	"einsteindb_engine_blob_file_count": {
  1937  		PromQL: `avg(einsteindb_engine_titandb_num_obsolete_blob_file{$LABEL_CONDITIONS}) by (instance,EDB)`,
  1938  		Labels: []string{"instance", "EDB"},
  1939  	},
  1940  	"einsteindb_engine_blob_file_size": {
  1941  		PromQL: `avg(einsteindb_engine_titandb_obsolete_blob_file_size{$LABEL_CONDITIONS}) by (instance,EDB)`,
  1942  		Labels: []string{"instance", "EDB"},
  1943  	},
  1944  	"einsteindb_engine_blob_gc_file": {
  1945  		PromQL: `sum(rate(einsteindb_engine_blob_gc_file_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance,EDB)`,
  1946  		Labels: []string{"instance", "type", "EDB"},
  1947  	},
  1948  	"einsteindb_engine_blob_gc_duration": {
  1949  		PromQL: `avg(einsteindb_engine_blob_gc_micros_seconds{$LABEL_CONDITIONS}) by (EDB,instance,type)`,
  1950  		Labels: []string{"instance", "type", "EDB"},
  1951  	},
  1952  	"einsteindb_engine_blob_gc_bytes_flow": {
  1953  		PromQL: `sum(rate(einsteindb_engine_blob_gc_flow_bytes{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance,EDB)`,
  1954  		Labels: []string{"instance", "type", "EDB"},
  1955  	},
  1956  	"einsteindb_engine_blob_gc_keys_flow": {
  1957  		PromQL: `sum(rate(einsteindb_engine_blob_gc_flow_bytes{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance,EDB)`,
  1958  		Labels: []string{"instance", "type", "EDB"},
  1959  	},
  1960  	"einsteindb_engine_live_blob_size": {
  1961  		PromQL: `avg(einsteindb_engine_titandb_live_blob_size{$LABEL_CONDITIONS}) by (instance,EDB)`,
  1962  		Labels: []string{"instance", "EDB"},
  1963  	},
  1964  
  1965  	"einsteindb_lock_manager_handled_tasks": {
  1966  		PromQL: `sum(rate(einsteindb_lock_manager_task_counter{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1967  		Labels: []string{"instance", "type"},
  1968  	},
  1969  	"einsteindb_lock_manager_waiter_lifetime_duration": {
  1970  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_lock_manager_waiter_lifetime_duration_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1971  		Labels:   []string{"instance"},
  1972  		Quantile: 0.99,
  1973  	},
  1974  	"einsteindb_lock_manager_waiter_lifetime_avg_duration": {
  1975  		PromQL: `sum(rate(einsteindb_lock_manager_waiter_lifetime_duration_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_lock_manager_waiter_lifetime_duration_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1976  		Labels: []string{"instance", "type"},
  1977  	},
  1978  	"einsteindb_lock_manager_wait_block": {
  1979  		PromQL: `sum(max_over_time(einsteindb_lock_manager_wait_block_status{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1980  		Labels: []string{"instance", "type"},
  1981  	},
  1982  	"einsteindb_lock_manager_deadlock_detect_duration": {
  1983  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_lock_manager_detect_duration_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  1984  		Labels:   []string{"instance"},
  1985  		Quantile: 0.99,
  1986  	},
  1987  	"einsteindb_lock_manager_deadlock_detect_avg_duration": {
  1988  		PromQL: `sum(rate(einsteindb_lock_manager_detect_duration_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_lock_manager_detect_duration_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  1989  		Labels: []string{"instance"},
  1990  	},
  1991  	"einsteindb_lock_manager_detect_error": {
  1992  		PromQL: `sum(rate(einsteindb_lock_manager_error_counter{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1993  		Labels: []string{"instance", "type"},
  1994  	},
  1995  	"einsteindb_lock_manager_detect_error_total_count": {
  1996  		PromQL: `sum(increase(einsteindb_lock_manager_error_counter{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  1997  		Labels: []string{"instance", "type"},
  1998  	},
  1999  	"einsteindb_lock_manager_deadlock_detector_leader": {
  2000  		PromQL: `sum(max_over_time(einsteindb_lock_manager_detector_leader_heartbeat{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  2001  		Labels: []string{"instance"},
  2002  	},
  2003  	"einsteindb_allocator_stats": {
  2004  		PromQL: `einsteindb_allocator_stats{$LABEL_CONDITIONS}`,
  2005  		Labels: []string{"instance", "type"},
  2006  	},
  2007  	"einsteindb_backup_range_size": {
  2008  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_backup_range_size_bytes_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,cf,instance))`,
  2009  		Labels:   []string{"instance", "cf"},
  2010  		Quantile: 0.99,
  2011  	},
  2012  	"einsteindb_backup_duration": {
  2013  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_backup_request_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,instance))`,
  2014  		Labels:   []string{"instance"},
  2015  		Quantile: 0.99,
  2016  	},
  2017  	"einsteindb_backup_avg_duration": {
  2018  		PromQL: `sum(rate(einsteindb_backup_request_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) / sum(rate(einsteindb_backup_request_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  2019  		Labels: []string{"instance"},
  2020  	},
  2021  
  2022  	"einsteindb_backup_flow": {
  2023  		PromQL: `sum(rate(einsteindb_backup_range_size_bytes_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  2024  		Labels: []string{"instance"},
  2025  	},
  2026  	"einsteindb_disk_read_bytes": {
  2027  		PromQL: `sum(irate(node_disk_read_bytes_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,device)`,
  2028  		Labels: []string{"instance", "device"},
  2029  	},
  2030  	"einsteindb_disk_write_bytes": {
  2031  		PromQL: `sum(irate(node_disk_written_bytes_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,device)`,
  2032  		Labels: []string{"instance", "device"},
  2033  	},
  2034  	"einsteindb_backup_range_duration": {
  2035  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(einsteindb_backup_range_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,instance))`,
  2036  		Labels:   []string{"instance", "type"},
  2037  		Quantile: 0.99,
  2038  	},
  2039  	"einsteindb_backup_range_avg_duration": {
  2040  		PromQL: `sum(rate(einsteindb_backup_range_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance) / sum(rate(einsteindb_backup_range_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type,instance)`,
  2041  		Labels: []string{"instance", "type"},
  2042  	},
  2043  	"einsteindb_backup_errors": {
  2044  		PromQL: `rate(einsteindb_backup_error_counter{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2045  		Labels: []string{"instance", "error"},
  2046  	},
  2047  	"einsteindb_backup_errors_total_count": {
  2048  		PromQL: `sum(increase(einsteindb_backup_error_counter{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,error)`,
  2049  		Labels: []string{"instance", "error"},
  2050  	},
  2051  	"node_virtual_cpus": {
  2052  		PromQL:  `count(node_cpu_seconds_total{mode="user"}) by (instance)`,
  2053  		Labels:  []string{"instance"},
  2054  		Comment: "node virtual cpu count",
  2055  	},
  2056  	"node_total_memory": {
  2057  		PromQL:  `node_memory_MemTotal_bytes{$LABEL_CONDITIONS}`,
  2058  		Labels:  []string{"instance"},
  2059  		Comment: "total memory in node",
  2060  	},
  2061  	"node_memory_available": {
  2062  		PromQL: `node_memory_MemAvailable_bytes{$LABEL_CONDITIONS}`,
  2063  		Labels: []string{"instance"},
  2064  	},
  2065  	"node_memory_usage": {
  2066  		PromQL: `100* (1-(node_memory_MemAvailable_bytes{$LABEL_CONDITIONS}/node_memory_MemTotal_bytes{$LABEL_CONDITIONS}))`,
  2067  		Labels: []string{"instance"},
  2068  	},
  2069  	"node_memory_swap_used": {
  2070  		PromQL:  `node_memory_SwapTotal_bytes{$LABEL_CONDITIONS} - node_memory_SwapFree_bytes{$LABEL_CONDITIONS}`,
  2071  		Labels:  []string{"instance"},
  2072  		Comment: "bytes used of node swap memory",
  2073  	},
  2074  	"node_uptime": {
  2075  		PromQL:  `node_time_seconds{$LABEL_CONDITIONS} - node_boot_time_seconds{$LABEL_CONDITIONS}`,
  2076  		Labels:  []string{"instance"},
  2077  		Comment: "node uptime, units are seconds",
  2078  	},
  2079  	"node_load1": {
  2080  		PromQL:  `node_load1{$LABEL_CONDITIONS}`,
  2081  		Labels:  []string{"instance"},
  2082  		Comment: "1 minute load averages in node",
  2083  	},
  2084  	"node_load5": {
  2085  		PromQL:  `node_load5{$LABEL_CONDITIONS}`,
  2086  		Labels:  []string{"instance"},
  2087  		Comment: "5 minutes load averages in node",
  2088  	},
  2089  	"node_load15": {
  2090  		PromQL:  `node_load15{$LABEL_CONDITIONS}`,
  2091  		Labels:  []string{"instance"},
  2092  		Comment: "15 minutes load averages in node",
  2093  	},
  2094  	"node_kernel_interrupts": {
  2095  		PromQL: `rate(node_intr_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) or irate(node_intr_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2096  		Labels: []string{"instance"},
  2097  	},
  2098  	"node_kernel_forks": {
  2099  		PromQL: `rate(node_forks_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) or irate(node_forks_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2100  		Labels: []string{"instance"},
  2101  	},
  2102  	"node_kernel_context_switches": {
  2103  		PromQL: `rate(node_context_switches_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) or irate(node_context_switches_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2104  		Labels: []string{"instance"},
  2105  	},
  2106  	"node_cpu_usage": {
  2107  		PromQL: `sum(rate(node_cpu_seconds_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (mode,instance) * 100 / count(node_cpu_seconds_total{$LABEL_CONDITIONS}) by (mode,instance) or sum(irate(node_cpu_seconds_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (mode,instance) * 100 / count(node_cpu_seconds_total{$LABEL_CONDITIONS}) by (mode,instance)`,
  2108  		Labels: []string{"instance", "mode"},
  2109  	},
  2110  	"node_memory_free": {
  2111  		PromQL: `node_memory_MemFree_bytes{$LABEL_CONDITIONS}`,
  2112  		Labels: []string{"instance"},
  2113  	},
  2114  	"node_memory_buffers": {
  2115  		PromQL: `node_memory_Buffers_bytes{$LABEL_CONDITIONS}`,
  2116  		Labels: []string{"instance"},
  2117  	},
  2118  	"node_memory_cached": {
  2119  		PromQL: `node_memory_Cached_bytes{$LABEL_CONDITIONS}`,
  2120  		Labels: []string{"instance"},
  2121  	},
  2122  	"node_memory_active": {
  2123  		PromQL: `node_memory_Active_bytes{$LABEL_CONDITIONS}`,
  2124  		Labels: []string{"instance"},
  2125  	},
  2126  	"node_memory_inactive": {
  2127  		PromQL: `node_memory_Inactive_bytes{$LABEL_CONDITIONS}`,
  2128  		Labels: []string{"instance"},
  2129  	},
  2130  	"node_memory_writeback": {
  2131  		PromQL: `node_memory_Writeback_bytes{$LABEL_CONDITIONS}`,
  2132  		Labels: []string{"instance"},
  2133  	},
  2134  	"node_memory_writeback_tmp": {
  2135  		PromQL: `node_memory_WritebackTmp_bytes{$LABEL_CONDITIONS}`,
  2136  		Labels: []string{"instance"},
  2137  	},
  2138  	"node_memory_dirty": {
  2139  		PromQL: `node_memory_Dirty_bytes{$LABEL_CONDITIONS}`,
  2140  		Labels: []string{"instance"},
  2141  	},
  2142  	"node_memory_shared": {
  2143  		PromQL: `node_memory_Shmem_bytes{$LABEL_CONDITIONS}`,
  2144  		Labels: []string{"instance"},
  2145  	},
  2146  	"node_memory_mapped": {
  2147  		PromQL: `node_memory_Mapped_bytes{$LABEL_CONDITIONS}`,
  2148  		Labels: []string{"instance"},
  2149  	},
  2150  	"node_disk_size": {
  2151  		PromQL: `node_filesystem_size_bytes{$LABEL_CONDITIONS}`,
  2152  		Labels: []string{"instance", "device", "fstype", "mountpoint"},
  2153  	},
  2154  	"node_disk_available_size": {
  2155  		PromQL: `node_filesystem_avail_bytes{$LABEL_CONDITIONS}`,
  2156  		Labels: []string{"instance", "device", "fstype", "mountpoint"},
  2157  	},
  2158  	"node_disk_state": {
  2159  		PromQL: `node_filesystem_readonly{$LABEL_CONDITIONS}`,
  2160  		Labels: []string{"instance", "device", "fstype", "mountpoint"},
  2161  	},
  2162  	"node_disk_io_util": {
  2163  		PromQL: `rate(node_disk_io_time_seconds_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) or irate(node_disk_io_time_seconds_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2164  		Labels: []string{"instance", "device"},
  2165  	},
  2166  	"node_disk_iops": {
  2167  		PromQL: `sum(rate(node_disk_reads_completed_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) + rate(node_disk_writes_completed_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,device)`,
  2168  		Labels: []string{"instance", "device"},
  2169  	},
  2170  	"node_disk_write_latency": {
  2171  		PromQL:  `(rate(node_disk_write_time_seconds_total{$LABEL_CONDITIONS}[$RANGE_DURATION])/ rate(node_disk_writes_completed_total{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  2172  		Labels:  []string{"instance", "device"},
  2173  		Comment: "node disk write latency",
  2174  	},
  2175  	"node_disk_read_latency": {
  2176  		PromQL:  `(rate(node_disk_read_time_seconds_total{$LABEL_CONDITIONS}[$RANGE_DURATION])/ rate(node_disk_reads_completed_total{$LABEL_CONDITIONS}[$RANGE_DURATION]))`,
  2177  		Labels:  []string{"instance", "device"},
  2178  		Comment: "node disk read latency",
  2179  	},
  2180  	"node_disk_throughput": {
  2181  		PromQL:  `irate(node_disk_read_bytes_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) + irate(node_disk_written_bytes_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2182  		Labels:  []string{"instance", "device"},
  2183  		Comment: "Units is byte",
  2184  	},
  2185  	"node_disk_usage": {
  2186  		PromQL:  `((node_filesystem_size_bytes{$LABEL_CONDITIONS} - node_filesystem_avail_bytes{$LABEL_CONDITIONS}) / node_filesystem_size_bytes{$LABEL_CONDITIONS}) * 100`,
  2187  		Labels:  []string{"instance", "device"},
  2188  		Comment: "Filesystem used space. If is > 80% then is Critical.",
  2189  	},
  2190  	"node_file_descriptor_allocated": {
  2191  		PromQL: `node_filefd_allocated{$LABEL_CONDITIONS}`,
  2192  		Labels: []string{"instance"},
  2193  	},
  2194  	"node_network_in_drops": {
  2195  		PromQL: `rate(node_network_receive_drop_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) `,
  2196  		Labels: []string{"instance", "device"},
  2197  	},
  2198  	"node_network_out_drops": {
  2199  		PromQL: `rate(node_network_transmit_drop_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2200  		Labels: []string{"instance", "device"},
  2201  	},
  2202  	"node_network_in_errors": {
  2203  		PromQL: `rate(node_network_receive_errs_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2204  		Labels: []string{"instance", "device"},
  2205  	},
  2206  	"node_network_in_errors_total_count": {
  2207  		PromQL: `sum(increase(node_network_receive_errs_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by(instance, device)`,
  2208  		Labels: []string{"instance", "device"},
  2209  	},
  2210  	"node_network_out_errors": {
  2211  		PromQL: `rate(node_network_transmit_errs_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2212  		Labels: []string{"instance", "device"},
  2213  	},
  2214  	"node_network_out_errors_total_count": {
  2215  		PromQL: `sum(increase(node_network_transmit_errs_total{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance, device)`,
  2216  		Labels: []string{"instance", "device"},
  2217  	},
  2218  	"node_network_in_traffic": {
  2219  		PromQL: `rate(node_network_receive_bytes_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) or irate(node_network_receive_bytes_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2220  		Labels: []string{"instance", "device"},
  2221  	},
  2222  	"node_network_out_traffic": {
  2223  		PromQL: `rate(node_network_transmit_bytes_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) or irate(node_network_transmit_bytes_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2224  		Labels: []string{"instance", "device"},
  2225  	},
  2226  	"node_network_in_packets": {
  2227  		PromQL: `rate(node_network_receive_packets_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) or irate(node_network_receive_packets_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2228  		Labels: []string{"instance", "device"},
  2229  	},
  2230  	"node_network_out_packets": {
  2231  		PromQL: `rate(node_network_transmit_packets_total{$LABEL_CONDITIONS}[$RANGE_DURATION]) or irate(node_network_transmit_packets_total{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2232  		Labels: []string{"instance", "device"},
  2233  	},
  2234  	"node_network_interface_speed": {
  2235  		PromQL:  `node_network_transmit_queue_length{$LABEL_CONDITIONS}`,
  2236  		Labels:  []string{"instance", "device"},
  2237  		Comment: "node_network_transmit_queue_length = transmit_queue_length value of /sys/class/net/<iface>.",
  2238  	},
  2239  	"node_network_utilization_in_hourly": {
  2240  		PromQL: `sum(increase(node_network_receive_bytes_total{$LABEL_CONDITIONS}[1h]))`,
  2241  		Labels: []string{"instance", "device"},
  2242  	},
  2243  	"node_network_utilization_out_hourly": {
  2244  		PromQL: `sum(increase(node_network_transmit_bytes_total{$LABEL_CONDITIONS}[1h]))`,
  2245  		Labels: []string{"instance", "device"},
  2246  	},
  2247  	"node_tcp_in_use": {
  2248  		PromQL: `node_sockstat_TCP_inuse{$LABEL_CONDITIONS}`,
  2249  		Labels: []string{"instance"},
  2250  	},
  2251  	"node_tcp_segments_retransmitted": {
  2252  		PromQL: `rate(node_netstat_Tcp_RetransSegs{$LABEL_CONDITIONS}[$RANGE_DURATION]) or irate(node_netstat_Tcp_RetransSegs{$LABEL_CONDITIONS}[$RANGE_DURATION])`,
  2253  		Labels: []string{"instance"},
  2254  	},
  2255  	"node_tcp_connections": {
  2256  		PromQL: `node_netstat_Tcp_CurrEstab{$LABEL_CONDITIONS}`,
  2257  		Labels: []string{"instance"},
  2258  	},
  2259  	"node_processes_running": {
  2260  		PromQL: `node_procs_running{$LABEL_CONDITIONS}`,
  2261  		Labels: []string{"instance"},
  2262  	},
  2263  	"node_processes_blocked": {
  2264  		PromQL: `node_procs_blocked{$LABEL_CONDITIONS}`,
  2265  		Labels: []string{"instance"},
  2266  	},
  2267  
  2268  	"etcd_wal_fsync_total_count": {
  2269  		PromQL:  "sum(increase(etcd_disk_wal_fsync_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2270  		Labels:  []string{"instance"},
  2271  		Comment: "The total count of writing WAL into the persistent storage",
  2272  	},
  2273  	"etcd_wal_fsync_total_time": {
  2274  		PromQL:  "sum(increase(etcd_disk_wal_fsync_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2275  		Labels:  []string{"instance"},
  2276  		Comment: "The total time of writing WAL into the persistent storage",
  2277  	},
  2278  	"FIDel_client_cmd_total_count": {
  2279  		PromQL:  "sum(increase(FIDel_client_cmd_handle_cmds_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2280  		Labels:  []string{"instance", "type"},
  2281  		Comment: "The total count of fidel client command durations",
  2282  	},
  2283  	"FIDel_client_cmd_total_time": {
  2284  		PromQL:  "sum(increase(FIDel_client_cmd_handle_cmds_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2285  		Labels:  []string{"instance", "type"},
  2286  		Comment: "The total time of fidel client command durations",
  2287  	},
  2288  	"FIDel_grpc_completed_commands_total_count": {
  2289  		PromQL:  "sum(increase(grpc_server_handling_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,grpc_method)",
  2290  		Labels:  []string{"instance", "grpc_method"},
  2291  		Comment: "The total count of completing each HoTT of gRPC commands",
  2292  	},
  2293  	"FIDel_grpc_completed_commands_total_time": {
  2294  		PromQL:  "sum(increase(grpc_server_handling_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,grpc_method)",
  2295  		Labels:  []string{"instance", "grpc_method"},
  2296  		Comment: "The total time of completing each HoTT of gRPC commands",
  2297  	},
  2298  	"FIDel_request_rpc_total_count": {
  2299  		PromQL:  "sum(increase(FIDel_client_request_handle_requests_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2300  		Labels:  []string{"instance", "type"},
  2301  		Comment: "The total count of fidel client handle request duration(second)",
  2302  	},
  2303  	"FIDel_request_rpc_total_time": {
  2304  		PromQL:  "sum(increase(FIDel_client_request_handle_requests_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2305  		Labels:  []string{"instance", "type"},
  2306  		Comment: "The total time of fidel client handle request duration(second)",
  2307  	},
  2308  	"FIDel_handle_transactions_total_count": {
  2309  		PromQL:  "sum(increase(FIDel_txn_handle_txns_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,result)",
  2310  		Labels:  []string{"instance", "result"},
  2311  		Comment: "The total count of handling etcd transactions",
  2312  	},
  2313  	"FIDel_handle_transactions_total_time": {
  2314  		PromQL:  "sum(increase(FIDel_txn_handle_txns_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,result)",
  2315  		Labels:  []string{"instance", "result"},
  2316  		Comment: "The total time of handling etcd transactions",
  2317  	},
  2318  	"FIDel_operator_finish_total_count": {
  2319  		PromQL:  "sum(increase(FIDel_schedule_finish_operators_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type)",
  2320  		Labels:  []string{"type"},
  2321  		Comment: "The total count of the operator is finished",
  2322  	},
  2323  	"FIDel_operator_finish_total_time": {
  2324  		PromQL:  "sum(increase(FIDel_schedule_finish_operators_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type)",
  2325  		Labels:  []string{"type"},
  2326  		Comment: "The total time consumed when the operator is finished",
  2327  	},
  2328  	"FIDel_operator_step_finish_total_count": {
  2329  		PromQL:  "sum(increase(FIDel_schedule_finish_operator_steps_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type)",
  2330  		Labels:  []string{"type"},
  2331  		Comment: "The total count of the operator step is finished",
  2332  	},
  2333  	"FIDel_operator_step_finish_total_time": {
  2334  		PromQL:  "sum(increase(FIDel_schedule_finish_operator_steps_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (type)",
  2335  		Labels:  []string{"type"},
  2336  		Comment: "The total time consumed when the operator step is finished",
  2337  	},
  2338  	"FIDel_peer_round_trip_total_count": {
  2339  		PromQL:  "sum(increase(etcd_network_peer_round_trip_time_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,To)",
  2340  		Labels:  []string{"instance", "To"},
  2341  		Comment: "The total count of the network in .99",
  2342  	},
  2343  	"FIDel_peer_round_trip_total_time": {
  2344  		PromQL:  "sum(increase(etcd_network_peer_round_trip_time_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,To)",
  2345  		Labels:  []string{"instance", "To"},
  2346  		Comment: "The total time of latency of the network in .99",
  2347  	},
  2348  	"FIDel_region_heartbeat_total_count": {
  2349  		PromQL:  "sum(increase(FIDel_scheduler_region_heartbeat_latency_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (address,causetstore)",
  2350  		Labels:  []string{"address", "causetstore"},
  2351  		Comment: "The total count of heartbeat latency of each EinsteinDB instance in",
  2352  	},
  2353  	"FIDel_region_heartbeat_total_time": {
  2354  		PromQL:  "sum(increase(FIDel_scheduler_region_heartbeat_latency_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (address,causetstore)",
  2355  		Labels:  []string{"address", "causetstore"},
  2356  		Comment: "The total time of heartbeat latency of each EinsteinDB instance in",
  2357  	},
  2358  	"FIDel_start_tso_wait_total_count": {
  2359  		PromQL:  "sum(increase(milevadb_FIDelclient_ts_future_wait_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2360  		Labels:  []string{"instance"},
  2361  		Comment: "The total count of the waiting for getting the start timestamp oracle",
  2362  	},
  2363  	"FIDel_start_tso_wait_total_time": {
  2364  		PromQL:  "sum(increase(milevadb_FIDelclient_ts_future_wait_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2365  		Labels:  []string{"instance"},
  2366  		Comment: "The total time of duration of the waiting time for getting the start timestamp oracle",
  2367  	},
  2368  	"FIDel_tso_rpc_total_count": {
  2369  		PromQL:  "sum(increase(FIDel_client_request_handle_requests_duration_seconds_count{type=\"tso\"}[$RANGE_DURATION])) by (instance)",
  2370  		Labels:  []string{"instance"},
  2371  		Comment: "The total count of a client sending TSO request until received the response.",
  2372  	},
  2373  	"FIDel_tso_rpc_total_time": {
  2374  		PromQL:  "sum(increase(FIDel_client_request_handle_requests_duration_seconds_sum{type=\"tso\"}[$RANGE_DURATION])) by (instance)",
  2375  		Labels:  []string{"instance"},
  2376  		Comment: "The total time of a client sending TSO request until received the response.",
  2377  	},
  2378  	"FIDel_tso_wait_total_count": {
  2379  		PromQL:  "sum(increase(FIDel_client_cmd_handle_cmds_duration_seconds_count{type=\"wait\"}[$RANGE_DURATION])) by (instance)",
  2380  		Labels:  []string{"instance"},
  2381  		Comment: "The total count of a client starting to wait for the TS until received the TS result.",
  2382  	},
  2383  	"FIDel_tso_wait_total_time": {
  2384  		PromQL:  "sum(increase(FIDel_client_cmd_handle_cmds_duration_seconds_sum{type=\"wait\"}[$RANGE_DURATION])) by (instance)",
  2385  		Labels:  []string{"instance"},
  2386  		Comment: "The total time of a client starting to wait for the TS until received the TS result.",
  2387  	},
  2388  	"milevadb_auto_id_request_total_count": {
  2389  		PromQL:  "sum(increase(milevadb_autoid_operation_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2390  		Labels:  []string{"instance", "type"},
  2391  		Comment: "The total count of MilevaDB auto id requests durations",
  2392  	},
  2393  	"milevadb_auto_id_request_total_time": {
  2394  		PromQL:  "sum(increase(milevadb_autoid_operation_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2395  		Labels:  []string{"instance", "type"},
  2396  		Comment: "The total time of MilevaDB auto id requests durations",
  2397  	},
  2398  	"milevadb_batch_client_unavailable_total_count": {
  2399  		PromQL:  "sum(increase(milevadb_einsteindbclient_batch_client_unavailable_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2400  		Labels:  []string{"instance"},
  2401  		Comment: "The total count of ekv storage batch processing unvailable durations",
  2402  	},
  2403  	"milevadb_batch_client_unavailable_total_time": {
  2404  		PromQL:  "sum(increase(milevadb_einsteindbclient_batch_client_unavailable_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2405  		Labels:  []string{"instance"},
  2406  		Comment: "The total time of ekv storage batch processing unvailable durations",
  2407  	},
  2408  	"milevadb_batch_client_wait_total_count": {
  2409  		PromQL:  "sum(increase(milevadb_einsteindbclient_batch_wait_duration_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2410  		Labels:  []string{"instance"},
  2411  		Comment: "The total count of ekv storage batch processing durations",
  2412  	},
  2413  	"milevadb_batch_client_wait_total_time": {
  2414  		PromQL:  "sum(increase(milevadb_einsteindbclient_batch_wait_duration_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2415  		Labels:  []string{"instance"},
  2416  		Comment: "The total time of ekv storage batch processing durations",
  2417  	},
  2418  	"milevadb_compile_total_count": {
  2419  		PromQL:  "sum(increase(milevadb_stochastik_compile_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,sql_type)",
  2420  		Labels:  []string{"instance", "sql_type"},
  2421  		Comment: "The total count of building the query plan(second)",
  2422  	},
  2423  	"milevadb_compile_total_time": {
  2424  		PromQL:  "sum(increase(milevadb_stochastik_compile_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,sql_type)",
  2425  		Labels:  []string{"instance", "sql_type"},
  2426  		Comment: "The total time of cost of building the query plan(second)",
  2427  	},
  2428  	"milevadb_cop_total_count": {
  2429  		PromQL:  "sum(increase(milevadb_einsteindbclient_cop_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2430  		Labels:  []string{"instance"},
  2431  		Comment: "The total count of ekv storage interlock processing durations",
  2432  	},
  2433  	"milevadb_cop_total_time": {
  2434  		PromQL:  "sum(increase(milevadb_einsteindbclient_cop_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2435  		Labels:  []string{"instance"},
  2436  		Comment: "The total time of ekv storage interlock processing durations",
  2437  	},
  2438  	"milevadb_dbs_batch_add_index_total_count": {
  2439  		PromQL:  "sum(increase(milevadb_dbs_batch_add_idx_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2440  		Labels:  []string{"instance", "type"},
  2441  		Comment: "The total count of MilevaDB batch add index durations by histogram buckets",
  2442  	},
  2443  	"milevadb_dbs_batch_add_index_total_time": {
  2444  		PromQL:  "sum(increase(milevadb_dbs_batch_add_idx_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2445  		Labels:  []string{"instance", "type"},
  2446  		Comment: "The total time of MilevaDB batch add index durations by histogram buckets",
  2447  	},
  2448  	"milevadb_dbs_deploy_syncer_total_count": {
  2449  		PromQL:  "sum(increase(milevadb_dbs_deploy_syncer_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,result)",
  2450  		Labels:  []string{"instance", "type", "result"},
  2451  		Comment: "The total count of MilevaDB dbs schemaReplicant syncer statistics, including init, start, watch, clear function call",
  2452  	},
  2453  	"milevadb_dbs_deploy_syncer_total_time": {
  2454  		PromQL:  "sum(increase(milevadb_dbs_deploy_syncer_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,result)",
  2455  		Labels:  []string{"instance", "type", "result"},
  2456  		Comment: "The total time of MilevaDB dbs schemaReplicant syncer statistics, including init, start, watch, clear function call time cost",
  2457  	},
  2458  	"milevadb_dbs_total_count": {
  2459  		PromQL:  "sum(increase(milevadb_dbs_handle_job_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2460  		Labels:  []string{"instance", "type"},
  2461  		Comment: "The total count of MilevaDB DBS duration statistics",
  2462  	},
  2463  	"milevadb_dbs_total_time": {
  2464  		PromQL:  "sum(increase(milevadb_dbs_handle_job_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2465  		Labels:  []string{"instance", "type"},
  2466  		Comment: "The total time of MilevaDB DBS duration statistics",
  2467  	},
  2468  	"milevadb_dbs_uFIDelate_self_version_total_count": {
  2469  		PromQL:  "sum(increase(milevadb_dbs_uFIDelate_self_ver_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,result)",
  2470  		Labels:  []string{"instance", "result"},
  2471  		Comment: "The total count of MilevaDB schemaReplicant syncer version uFIDelate",
  2472  	},
  2473  	"milevadb_dbs_uFIDelate_self_version_total_time": {
  2474  		PromQL:  "sum(increase(milevadb_dbs_uFIDelate_self_ver_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,result)",
  2475  		Labels:  []string{"instance", "result"},
  2476  		Comment: "The total time of MilevaDB schemaReplicant syncer version uFIDelate time duration",
  2477  	},
  2478  	"milevadb_dbs_worker_total_count": {
  2479  		PromQL:  "sum(increase(milevadb_dbs_worker_operation_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,result,action)",
  2480  		Labels:  []string{"instance", "type", "result", "action"},
  2481  		Comment: "The total count of MilevaDB dbs worker duration",
  2482  	},
  2483  	"milevadb_dbs_worker_total_time": {
  2484  		PromQL:  "sum(increase(milevadb_dbs_worker_operation_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,result,action)",
  2485  		Labels:  []string{"instance", "type", "result", "action"},
  2486  		Comment: "The total time of MilevaDB dbs worker duration",
  2487  	},
  2488  	"milevadb_allegrosql_execution_total_count": {
  2489  		PromQL:  "sum(increase(milevadb_allegrosql_handle_query_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2490  		Labels:  []string{"instance", "type"},
  2491  		Comment: "The total count of allegrosql execution(second)",
  2492  	},
  2493  	"milevadb_allegrosql_execution_total_time": {
  2494  		PromQL:  "sum(increase(milevadb_allegrosql_handle_query_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2495  		Labels:  []string{"instance", "type"},
  2496  		Comment: "The total time of allegrosql execution(second)",
  2497  	},
  2498  	"milevadb_execute_total_count": {
  2499  		PromQL:  "sum(increase(milevadb_stochastik_execute_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,sql_type)",
  2500  		Labels:  []string{"instance", "sql_type"},
  2501  		Comment: "The total count of of MilevaDB executing the ALLEGROALLEGROSQL",
  2502  	},
  2503  	"milevadb_execute_total_time": {
  2504  		PromQL:  "sum(increase(milevadb_stochastik_execute_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,sql_type)",
  2505  		Labels:  []string{"instance", "sql_type"},
  2506  		Comment: "The total time cost of executing the ALLEGROALLEGROSQL which does not include the time to get the results of the query(second)",
  2507  	},
  2508  	"milevadb_gc_push_task_total_count": {
  2509  		PromQL:  "sum(increase(milevadb_einsteindbclient_range_task_push_duration_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2510  		Labels:  []string{"instance", "type"},
  2511  		Comment: "The total count of ekv storage range worker processing one task duration",
  2512  	},
  2513  	"milevadb_gc_push_task_total_time": {
  2514  		PromQL:  "sum(increase(milevadb_einsteindbclient_range_task_push_duration_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2515  		Labels:  []string{"instance", "type"},
  2516  		Comment: "The total time of ekv storage range worker processing one task duration",
  2517  	},
  2518  	"milevadb_gc_total_count": {
  2519  		PromQL:  "sum(increase(milevadb_einsteindbclient_gc_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2520  		Labels:  []string{"instance"},
  2521  		Comment: "The total count of ekv storage garbage defCauslection",
  2522  	},
  2523  	"milevadb_gc_total_time": {
  2524  		PromQL:  "sum(increase(milevadb_einsteindbclient_gc_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2525  		Labels:  []string{"instance"},
  2526  		Comment: "The total time of ekv storage garbage defCauslection time durations",
  2527  	},
  2528  	"milevadb_get_token_total_count": {
  2529  		PromQL:  "sum(increase(milevadb_server_get_token_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2530  		Labels:  []string{"instance"},
  2531  		Comment: "The total count of Duration (us) for getting token, it should be small until concurrency limit is reached",
  2532  	},
  2533  	"milevadb_get_token_total_time": {
  2534  		PromQL:  "sum(increase(milevadb_server_get_token_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2535  		Labels:  []string{"instance"},
  2536  		Comment: "The total time of Duration (us) for getting token, it should be small until concurrency limit is reached(microsecond)",
  2537  	},
  2538  	"milevadb_ekv_backoff_total_count": {
  2539  		PromQL:  "sum(increase(milevadb_einsteindbclient_backoff_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2540  		Labels:  []string{"instance", "type"},
  2541  		Comment: "The total count of ekv backoff",
  2542  	},
  2543  	"milevadb_ekv_backoff_total_time": {
  2544  		PromQL:  "sum(increase(milevadb_einsteindbclient_backoff_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2545  		Labels:  []string{"instance", "type"},
  2546  		Comment: "The total time of ekv backoff time durations(second)",
  2547  	},
  2548  	"milevadb_ekv_request_total_count": {
  2549  		PromQL:  "sum(increase(milevadb_einsteindbclient_request_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,causetstore)",
  2550  		Labels:  []string{"instance", "type", "causetstore"},
  2551  		Comment: "The total count of ekv requests durations by causetstore",
  2552  	},
  2553  	"milevadb_ekv_request_total_time": {
  2554  		PromQL:  "sum(increase(milevadb_einsteindbclient_request_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,causetstore)",
  2555  		Labels:  []string{"instance", "type", "causetstore"},
  2556  		Comment: "The total time of ekv requests durations by causetstore",
  2557  	},
  2558  	"milevadb_load_schema_total_count": {
  2559  		PromQL:  "sum(increase(milevadb_petri_load_schema_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2560  		Labels:  []string{"instance"},
  2561  		Comment: "The total count of MilevaDB loading schemaReplicant by instance",
  2562  	},
  2563  	"milevadb_load_schema_total_time": {
  2564  		PromQL:  "sum(increase(milevadb_petri_load_schema_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2565  		Labels:  []string{"instance"},
  2566  		Comment: "The total time of MilevaDB loading schemaReplicant time durations by instance",
  2567  	},
  2568  	"milevadb_spacetime_operation_total_count": {
  2569  		PromQL:  "sum(increase(milevadb_spacetime_operation_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,result)",
  2570  		Labels:  []string{"instance", "type", "result"},
  2571  		Comment: "The total count of MilevaDB spacetime operation durations including get/set schemaReplicant and dbs jobs",
  2572  	},
  2573  	"milevadb_spacetime_operation_total_time": {
  2574  		PromQL:  "sum(increase(milevadb_spacetime_operation_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,result)",
  2575  		Labels:  []string{"instance", "type", "result"},
  2576  		Comment: "The total time of MilevaDB spacetime operation durations including get/set schemaReplicant and dbs jobs",
  2577  	},
  2578  	"milevadb_new_etcd_stochastik_total_count": {
  2579  		PromQL:  "sum(increase(milevadb_tenant_new_stochastik_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,result)",
  2580  		Labels:  []string{"instance", "type", "result"},
  2581  		Comment: "The total count of MilevaDB new stochastik durations for new etcd stochastik",
  2582  	},
  2583  	"milevadb_new_etcd_stochastik_total_time": {
  2584  		PromQL:  "sum(increase(milevadb_tenant_new_stochastik_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,result)",
  2585  		Labels:  []string{"instance", "type", "result"},
  2586  		Comment: "The total time of MilevaDB new stochastik durations for new etcd stochastik",
  2587  	},
  2588  	"milevadb_tenant_handle_syncer_total_count": {
  2589  		PromQL:  "sum(increase(milevadb_dbs_tenant_handle_syncer_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,result)",
  2590  		Labels:  []string{"instance", "type", "result"},
  2591  		Comment: "The total count of MilevaDB dbs tenant operations on etcd ",
  2592  	},
  2593  	"milevadb_tenant_handle_syncer_total_time": {
  2594  		PromQL:  "sum(increase(milevadb_dbs_tenant_handle_syncer_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,result)",
  2595  		Labels:  []string{"instance", "type", "result"},
  2596  		Comment: "The total time of MilevaDB dbs tenant time operations on etcd duration statistics ",
  2597  	},
  2598  	"milevadb_parse_total_count": {
  2599  		PromQL:  "sum(increase(milevadb_stochastik_parse_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,sql_type)",
  2600  		Labels:  []string{"instance", "sql_type"},
  2601  		Comment: "The total count of parsing ALLEGROALLEGROSQL to AST(second)",
  2602  	},
  2603  	"milevadb_parse_total_time": {
  2604  		PromQL:  "sum(increase(milevadb_stochastik_parse_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,sql_type)",
  2605  		Labels:  []string{"instance", "sql_type"},
  2606  		Comment: "The total time cost of parsing ALLEGROALLEGROSQL to AST(second)",
  2607  	},
  2608  	"milevadb_query_total_count": {
  2609  		PromQL:  "sum(increase(milevadb_server_handle_query_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,sql_type)",
  2610  		Labels:  []string{"instance", "sql_type"},
  2611  		Comment: "The total count of MilevaDB query durations(second)",
  2612  	},
  2613  	"milevadb_query_total_time": {
  2614  		PromQL:  "sum(increase(milevadb_server_handle_query_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,sql_type)",
  2615  		Labels:  []string{"instance", "sql_type"},
  2616  		Comment: "The total time of MilevaDB query durations(second)",
  2617  	},
  2618  	"milevadb_txn_cmd_duration": {
  2619  		PromQL:   `histogram_quantile($QUANTILE, sum(rate(milevadb_einsteindbclient_txn_cmd_duration_seconds_bucket{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (le,type,instance))`,
  2620  		Labels:   []string{"instance", "type"},
  2621  		Quantile: 0.90,
  2622  		Comment:  "The quantile of MilevaDB transaction command durations(second)",
  2623  	},
  2624  	"milevadb_txn_cmd_total_count": {
  2625  		PromQL:  "sum(increase(milevadb_einsteindbclient_txn_cmd_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2626  		Labels:  []string{"instance", "type"},
  2627  		Comment: "The total count of MilevaDB transaction command",
  2628  	},
  2629  	"milevadb_txn_cmd_total_time": {
  2630  		PromQL:  "sum(increase(milevadb_einsteindbclient_txn_cmd_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2631  		Labels:  []string{"instance", "type"},
  2632  		Comment: "The total time of MilevaDB transaction command",
  2633  	},
  2634  	"milevadb_slow_query_cop_process_total_count": {
  2635  		PromQL:  "sum(increase(milevadb_server_slow_query_cop_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2636  		Labels:  []string{"instance"},
  2637  		Comment: "The total count of MilevaDB slow query cop process",
  2638  	},
  2639  	"milevadb_slow_query_cop_process_total_time": {
  2640  		PromQL:  "sum(increase(milevadb_server_slow_query_cop_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2641  		Labels:  []string{"instance"},
  2642  		Comment: "The total time of MilevaDB slow query statistics with slow query total cop process time(second)",
  2643  	},
  2644  	"milevadb_slow_query_cop_wait_total_count": {
  2645  		PromQL:  "sum(increase(milevadb_server_slow_query_wait_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2646  		Labels:  []string{"instance"},
  2647  		Comment: "The total count of MilevaDB slow query cop wait",
  2648  	},
  2649  	"milevadb_slow_query_cop_wait_total_time": {
  2650  		PromQL:  "sum(increase(milevadb_server_slow_query_wait_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2651  		Labels:  []string{"instance"},
  2652  		Comment: "The total time of MilevaDB slow query statistics with slow query total cop wait time(second)",
  2653  	},
  2654  	"milevadb_slow_query_total_count": {
  2655  		PromQL:  "sum(increase(milevadb_server_slow_query_process_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2656  		Labels:  []string{"instance"},
  2657  		Comment: "The total count of MilevaDB slow query",
  2658  	},
  2659  	"milevadb_slow_query_total_time": {
  2660  		PromQL:  "sum(increase(milevadb_server_slow_query_process_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2661  		Labels:  []string{"instance"},
  2662  		Comment: "The total time of MilevaDB slow query statistics with slow query time(second)",
  2663  	},
  2664  	"milevadb_statistics_auto_analyze_total_count": {
  2665  		PromQL:  "sum(increase(milevadb_statistics_auto_analyze_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2666  		Labels:  []string{"instance"},
  2667  		Comment: "The total count of MilevaDB auto analyze",
  2668  	},
  2669  	"milevadb_statistics_auto_analyze_total_time": {
  2670  		PromQL:  "sum(increase(milevadb_statistics_auto_analyze_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2671  		Labels:  []string{"instance"},
  2672  		Comment: "The total time of MilevaDB auto analyze time durations within 95 percent histogram buckets",
  2673  	},
  2674  	"milevadb_transaction_local_latch_wait_total_count": {
  2675  		PromQL:  "sum(increase(milevadb_einsteindbclient_local_latch_wait_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2676  		Labels:  []string{"instance"},
  2677  		Comment: "The total count of MilevaDB transaction latch wait on key value storage(second)",
  2678  	},
  2679  	"milevadb_transaction_local_latch_wait_total_time": {
  2680  		PromQL:  "sum(increase(milevadb_einsteindbclient_local_latch_wait_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2681  		Labels:  []string{"instance"},
  2682  		Comment: "The total time of MilevaDB transaction latch wait time on key value storage(second)",
  2683  	},
  2684  	"milevadb_transaction_total_count": {
  2685  		PromQL:  "sum(increase(milevadb_stochastik_transaction_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,sql_type)",
  2686  		Labels:  []string{"instance", "type", "sql_type"},
  2687  		Comment: "The total count of transaction execution durations, including retry(second)",
  2688  	},
  2689  	"milevadb_transaction_total_time": {
  2690  		PromQL:  "sum(increase(milevadb_stochastik_transaction_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type,sql_type)",
  2691  		Labels:  []string{"instance", "type", "sql_type"},
  2692  		Comment: "The total time of transaction execution durations, including retry(second)",
  2693  	},
  2694  	"einsteindb_raftstore_append_log_total_count": {
  2695  		PromQL:  "sum(increase(einsteindb_raftstore_append_log_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2696  		Labels:  []string{"instance"},
  2697  		Comment: "The total count of Raft appends log",
  2698  	},
  2699  	"einsteindb_raftstore_append_log_total_time": {
  2700  		PromQL:  "sum(increase(einsteindb_raftstore_append_log_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2701  		Labels:  []string{"instance"},
  2702  		Comment: "The total time of Raft appends log",
  2703  	},
  2704  	"einsteindb_raftstore_apply_log_total_count": {
  2705  		PromQL:  "sum(increase(einsteindb_raftstore_apply_log_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2706  		Labels:  []string{"instance"},
  2707  		Comment: "The total count of Raft applies log",
  2708  	},
  2709  	"einsteindb_raftstore_apply_log_total_time": {
  2710  		PromQL:  "sum(increase(einsteindb_raftstore_apply_log_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2711  		Labels:  []string{"instance"},
  2712  		Comment: "The total time of Raft applies log",
  2713  	},
  2714  	"einsteindb_raftstore_apply_wait_total_count": {
  2715  		PromQL: "sum(increase(einsteindb_raftstore_apply_wait_time_duration_secs_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2716  		Labels: []string{"instance"},
  2717  	},
  2718  	"einsteindb_raftstore_apply_wait_total_time": {
  2719  		PromQL: "sum(increase(einsteindb_raftstore_apply_wait_time_duration_secs_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2720  		Labels: []string{"instance"},
  2721  	},
  2722  	"einsteindb_backup_range_total_count": {
  2723  		PromQL: "sum(increase(einsteindb_backup_range_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2724  		Labels: []string{"instance", "type"},
  2725  	},
  2726  	"einsteindb_backup_range_total_time": {
  2727  		PromQL: "sum(increase(einsteindb_backup_range_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2728  		Labels: []string{"instance", "type"},
  2729  	},
  2730  	"einsteindb_backup_total_count": {
  2731  		PromQL: "sum(increase(einsteindb_backup_request_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2732  		Labels: []string{"instance"},
  2733  	},
  2734  	"einsteindb_backup_total_time": {
  2735  		PromQL: "sum(increase(einsteindb_backup_request_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2736  		Labels: []string{"instance"},
  2737  	},
  2738  	"einsteindb_check_split_total_count": {
  2739  		PromQL:  "sum(increase(einsteindb_raftstore_check_split_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2740  		Labels:  []string{"instance"},
  2741  		Comment: "The total count of running split check",
  2742  	},
  2743  	"einsteindb_check_split_total_time": {
  2744  		PromQL:  "sum(increase(einsteindb_raftstore_check_split_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2745  		Labels:  []string{"instance"},
  2746  		Comment: "The total time of time consumed when running split check in .9999",
  2747  	},
  2748  	"einsteindb_raftstore_commit_log_total_count": {
  2749  		PromQL:  "sum(increase(einsteindb_raftstore_commit_log_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2750  		Labels:  []string{"instance"},
  2751  		Comment: "The total count of Raft commits log",
  2752  	},
  2753  	"einsteindb_raftstore_commit_log_total_time": {
  2754  		PromQL:  "sum(increase(einsteindb_raftstore_commit_log_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2755  		Labels:  []string{"instance"},
  2756  		Comment: "The total time of Raft commits log",
  2757  	},
  2758  	"einsteindb_cop_handle_total_count": {
  2759  		PromQL:  "sum(increase(einsteindb_coprocessor_request_handle_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,req)",
  2760  		Labels:  []string{"instance", "req"},
  2761  		Comment: "The total count of einsteindb interlock handling interlock requests",
  2762  	},
  2763  	"einsteindb_cop_handle_total_time": {
  2764  		PromQL:  "sum(increase(einsteindb_coprocessor_request_handle_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,req)",
  2765  		Labels:  []string{"instance", "req"},
  2766  		Comment: "The total time of time consumed when handling interlock requests",
  2767  	},
  2768  	"einsteindb_cop_request_total_count": {
  2769  		PromQL:  "sum(increase(einsteindb_coprocessor_request_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,req)",
  2770  		Labels:  []string{"instance", "req"},
  2771  		Comment: "The total count of einsteindb handle interlock read requests",
  2772  	},
  2773  	"einsteindb_cop_request_total_time": {
  2774  		PromQL:  "sum(increase(einsteindb_coprocessor_request_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,req)",
  2775  		Labels:  []string{"instance", "req"},
  2776  		Comment: "The total time of time consumed to handle interlock read requests",
  2777  	},
  2778  	"einsteindb_cop_wait_total_count": {
  2779  		PromQL:  "sum(increase(einsteindb_coprocessor_request_wait_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,req,type)",
  2780  		Labels:  []string{"instance", "req", "type"},
  2781  		Comment: "The total count of interlock requests that wait for being handled",
  2782  	},
  2783  	"einsteindb_cop_wait_total_time": {
  2784  		PromQL:  "sum(increase(einsteindb_coprocessor_request_wait_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,req,type)",
  2785  		Labels:  []string{"instance", "req", "type"},
  2786  		Comment: "The total time of time consumed when interlock requests are wait for being handled",
  2787  	},
  2788  	"einsteindb_raft_store_events_total_count": {
  2789  		PromQL:  "sum(increase(einsteindb_raftstore_event_duration_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2790  		Labels:  []string{"instance", "type"},
  2791  		Comment: "The total count of raftstore events (P99).99",
  2792  	},
  2793  	"einsteindb_raft_store_events_total_time": {
  2794  		PromQL:  "sum(increase(einsteindb_raftstore_event_duration_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2795  		Labels:  []string{"instance", "type"},
  2796  		Comment: "The total time of raftstore events (P99).99",
  2797  	},
  2798  	"einsteindb_gc_tasks_total_count": {
  2799  		PromQL:  "sum(increase(einsteindb_gcworker_gc_task_duration_vec_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,task)",
  2800  		Labels:  []string{"instance", "task"},
  2801  		Comment: "The total count of executing GC tasks",
  2802  	},
  2803  	"einsteindb_gc_tasks_total_time": {
  2804  		PromQL:  "sum(increase(einsteindb_gcworker_gc_task_duration_vec_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,task)",
  2805  		Labels:  []string{"instance", "task"},
  2806  		Comment: "The total time of time consumed when executing GC tasks",
  2807  	},
  2808  	"einsteindb_grpc_message_total_count": {
  2809  		PromQL:  "sum(increase(einsteindb_grpc_msg_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2810  		Labels:  []string{"instance", "type"},
  2811  		Comment: "The total count of einsteindb execution gRPC message",
  2812  	},
  2813  	"einsteindb_grpc_message_total_time": {
  2814  		PromQL:  "sum(increase(einsteindb_grpc_msg_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2815  		Labels:  []string{"instance", "type"},
  2816  		Comment: "The total time of execution time of gRPC message",
  2817  	},
  2818  	"einsteindb_handle_snapshot_total_count": {
  2819  		PromQL:  "sum(increase(einsteindb_raftstore_snapshot_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2820  		Labels:  []string{"instance", "type"},
  2821  		Comment: "The total count of einsteindb handling snapshots",
  2822  	},
  2823  	"einsteindb_handle_snapshot_total_time": {
  2824  		PromQL:  "sum(increase(einsteindb_raftstore_snapshot_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2825  		Labels:  []string{"instance", "type"},
  2826  		Comment: "The total time of time consumed when handling snapshots",
  2827  	},
  2828  	"einsteindb_ingest_sst_total_count": {
  2829  		PromQL:  "sum(increase(einsteindb_snapshot_ingest_sst_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,EDB)",
  2830  		Labels:  []string{"instance", "EDB"},
  2831  		Comment: "The total count of ingesting SST files",
  2832  	},
  2833  	"einsteindb_ingest_sst_total_time": {
  2834  		PromQL:  "sum(increase(einsteindb_snapshot_ingest_sst_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,EDB)",
  2835  		Labels:  []string{"instance", "EDB"},
  2836  		Comment: "The total time of time consumed when ingesting SST files",
  2837  	},
  2838  	"einsteindb_lock_manager_deadlock_detect_total_count": {
  2839  		PromQL: "sum(increase(einsteindb_lock_manager_detect_duration_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2840  		Labels: []string{"instance"},
  2841  	},
  2842  	"einsteindb_lock_manager_deadlock_detect_total_time": {
  2843  		PromQL: "sum(increase(einsteindb_lock_manager_detect_duration_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2844  		Labels: []string{"instance"},
  2845  	},
  2846  	"einsteindb_lock_manager_waiter_lifetime_total_count": {
  2847  		PromQL: "sum(increase(einsteindb_lock_manager_waiter_lifetime_duration_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2848  		Labels: []string{"instance"},
  2849  	},
  2850  	"einsteindb_lock_manager_waiter_lifetime_total_time": {
  2851  		PromQL: "sum(increase(einsteindb_lock_manager_waiter_lifetime_duration_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2852  		Labels: []string{"instance"},
  2853  	},
  2854  	"einsteindb_raftstore_process_total_count": {
  2855  		PromQL:  "sum(increase(einsteindb_raftstore_raft_process_duration_secs_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2856  		Labels:  []string{"instance", "type"},
  2857  		Comment: "The total count of peer processes in Raft",
  2858  	},
  2859  	"einsteindb_raftstore_process_total_time": {
  2860  		PromQL:  "sum(increase(einsteindb_raftstore_raft_process_duration_secs_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2861  		Labels:  []string{"instance", "type"},
  2862  		Comment: "The total time of peer processes in Raft",
  2863  	},
  2864  	"einsteindb_raftstore_propose_wait_total_count": {
  2865  		PromQL:  "sum(increase(einsteindb_raftstore_request_wait_time_duration_secs_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2866  		Labels:  []string{"instance"},
  2867  		Comment: "The total count of each proposal",
  2868  	},
  2869  	"einsteindb_raftstore_propose_wait_total_time": {
  2870  		PromQL:  "sum(increase(einsteindb_raftstore_request_wait_time_duration_secs_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2871  		Labels:  []string{"instance"},
  2872  		Comment: "The total time of wait time of each proposal",
  2873  	},
  2874  	"einsteindb_scheduler_command_total_count": {
  2875  		PromQL:  "sum(increase(einsteindb_scheduler_command_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2876  		Labels:  []string{"instance", "type"},
  2877  		Comment: "The total count of einsteindb scheduler executing command",
  2878  	},
  2879  	"einsteindb_scheduler_command_total_time": {
  2880  		PromQL:  "sum(increase(einsteindb_scheduler_command_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2881  		Labels:  []string{"instance", "type"},
  2882  		Comment: "The total time of time consumed when executing command",
  2883  	},
  2884  	"einsteindb_scheduler_latch_wait_total_count": {
  2885  		PromQL:  "sum(increase(einsteindb_scheduler_latch_wait_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2886  		Labels:  []string{"instance", "type"},
  2887  		Comment: "The total count which is caused by latch wait in command",
  2888  	},
  2889  	"einsteindb_scheduler_latch_wait_total_time": {
  2890  		PromQL:  "sum(increase(einsteindb_scheduler_latch_wait_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2891  		Labels:  []string{"instance", "type"},
  2892  		Comment: "The total time which is caused by latch wait in command",
  2893  	},
  2894  	"einsteindb_send_snapshot_total_count": {
  2895  		PromQL:  "sum(increase(einsteindb_server_send_snapshot_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2896  		Labels:  []string{"instance"},
  2897  		Comment: "The total count of sending snapshots",
  2898  	},
  2899  	"einsteindb_send_snapshot_total_time": {
  2900  		PromQL:  "sum(increase(einsteindb_server_send_snapshot_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2901  		Labels:  []string{"instance"},
  2902  		Comment: "The total time of time consumed when sending snapshots",
  2903  	},
  2904  	"einsteindb_storage_async_request_total_count": {
  2905  		PromQL:  "sum(increase(einsteindb_storage_engine_async_request_duration_seconds_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2906  		Labels:  []string{"instance", "type"},
  2907  		Comment: "The total count of processing asynchronous snapshot requests",
  2908  	},
  2909  	"einsteindb_storage_async_request_total_time": {
  2910  		PromQL:  "sum(increase(einsteindb_storage_engine_async_request_duration_seconds_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2911  		Labels:  []string{"instance", "type"},
  2912  		Comment: "The total time of time consumed by processing asynchronous snapshot requests",
  2913  	},
  2914  
  2915  	"milevadb_allegrosql_partial_num_total_count": {
  2916  		PromQL:  "sum(increase(milevadb_allegrosql_partial_num_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2917  		Labels:  []string{"instance"},
  2918  		Comment: "The total count of allegrosql partial numbers per query",
  2919  	},
  2920  	"milevadb_allegrosql_partial_scan_key_num_total_count": {
  2921  		PromQL:  "sum(increase(milevadb_allegrosql_scan_keys_partial_num_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2922  		Labels:  []string{"instance"},
  2923  		Comment: "The total count of allegrosql partial scan key numbers",
  2924  	},
  2925  	"milevadb_allegrosql_partial_scan_key_total_num": {
  2926  		PromQL:  "sum(increase(milevadb_allegrosql_scan_keys_partial_num_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2927  		Labels:  []string{"instance"},
  2928  		Comment: "The total num of allegrosql partial scan key numbers",
  2929  	},
  2930  	"milevadb_allegrosql_partial_total_num": {
  2931  		PromQL:  "sum(increase(milevadb_allegrosql_partial_num_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2932  		Labels:  []string{"instance"},
  2933  		Comment: "The total num of allegrosql partial numbers per query",
  2934  	},
  2935  	"milevadb_allegrosql_scan_key_num_total_count": {
  2936  		PromQL:  "sum(increase(milevadb_allegrosql_scan_keys_num_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2937  		Labels:  []string{"instance"},
  2938  		Comment: "The total count of allegrosql scan numbers",
  2939  	},
  2940  	"milevadb_allegrosql_scan_key_total_num": {
  2941  		PromQL:  "sum(increase(milevadb_allegrosql_scan_keys_num_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2942  		Labels:  []string{"instance"},
  2943  		Comment: "The total num of allegrosql scan numbers",
  2944  	},
  2945  	"milevadb_ekv_write_num_total_count": {
  2946  		PromQL:  "sum(increase(milevadb_einsteindbclient_txn_write_ekv_num_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2947  		Labels:  []string{"instance"},
  2948  		Comment: "The total count of ekv write in transaction execution",
  2949  	},
  2950  	"milevadb_ekv_write_size_total_count": {
  2951  		PromQL:  "sum(increase(milevadb_einsteindbclient_txn_write_size_bytes_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2952  		Labels:  []string{"instance"},
  2953  		Comment: "The total count of ekv write size per transaction execution",
  2954  	},
  2955  	"milevadb_ekv_write_total_num": {
  2956  		PromQL:  "sum(increase(milevadb_einsteindbclient_txn_write_ekv_num_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2957  		Labels:  []string{"instance"},
  2958  		Comment: "The total num of ekv write in transaction execution",
  2959  	},
  2960  	"milevadb_ekv_write_total_size": {
  2961  		PromQL:  "sum(increase(milevadb_einsteindbclient_txn_write_size_bytes_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2962  		Labels:  []string{"instance"},
  2963  		Comment: "The total ekv write size in transaction execution",
  2964  	},
  2965  	"milevadb_statistics_fast_analyze_status_total_count": {
  2966  		PromQL:  "sum(increase(milevadb_statistics_fast_analyze_status_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2967  		Labels:  []string{"instance", "type"},
  2968  		Comment: "The total count of MilevaDB fast analyze statistics ",
  2969  	},
  2970  	"milevadb_statistics_fast_analyze_total_status": {
  2971  		PromQL:  "sum(increase(milevadb_statistics_fast_analyze_status_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  2972  		Labels:  []string{"instance", "type"},
  2973  		Comment: "The total time of MilevaDB fast analyze statistics ",
  2974  	},
  2975  	"milevadb_statistics_stats_inaccuracy_rate_total_count": {
  2976  		PromQL:  "sum(increase(milevadb_statistics_stats_inaccuracy_rate_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2977  		Labels:  []string{"instance"},
  2978  		Comment: "The total count of MilevaDB statistics inaccurate rate",
  2979  	},
  2980  	"milevadb_statistics_stats_inaccuracy_total_rate": {
  2981  		PromQL:  "sum(increase(milevadb_statistics_stats_inaccuracy_rate_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2982  		Labels:  []string{"instance"},
  2983  		Comment: "The total time of MilevaDB statistics inaccurate rate",
  2984  	},
  2985  	"milevadb_transaction_retry_num_total_count": {
  2986  		PromQL:  "sum(increase(milevadb_stochastik_retry_num_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2987  		Labels:  []string{"instance"},
  2988  		Comment: "The total count of MilevaDB transaction retry num",
  2989  	},
  2990  	"milevadb_transaction_retry_total_num": {
  2991  		PromQL:  "sum(increase(milevadb_stochastik_retry_num_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  2992  		Labels:  []string{"instance"},
  2993  		Comment: "The total num of MilevaDB transaction retry num",
  2994  	},
  2995  	"milevadb_transaction_memex_num_total_count": {
  2996  		PromQL:  "sum(increase(milevadb_stochastik_transaction_memex_num_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,sql_type)",
  2997  		Labels:  []string{"instance", "sql_type"},
  2998  		Comment: "The total count of MilevaDB memexs numbers within one transaction. Internal means MilevaDB inner transaction",
  2999  	},
  3000  	"milevadb_transaction_memex_total_num": {
  3001  		PromQL:  "sum(increase(milevadb_stochastik_transaction_memex_num_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,sql_type)",
  3002  		Labels:  []string{"instance", "sql_type"},
  3003  		Comment: "The total num of MilevaDB memexs numbers within one transaction. Internal means MilevaDB inner transaction",
  3004  	},
  3005  	"milevadb_txn_region_num_total_count": {
  3006  		PromQL:  "sum(increase(milevadb_einsteindbclient_txn_regions_num_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3007  		Labels:  []string{"instance"},
  3008  		Comment: "The total count of regions transaction operates on count",
  3009  	},
  3010  	"milevadb_txn_region_total_num": {
  3011  		PromQL:  "sum(increase(milevadb_einsteindbclient_txn_regions_num_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3012  		Labels:  []string{"instance"},
  3013  		Comment: "The total num of regions transaction operates on count",
  3014  	},
  3015  	"einsteindb_approximate_region_size_total_count": {
  3016  		PromQL:  "sum(increase(einsteindb_raftstore_region_size_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3017  		Labels:  []string{"instance"},
  3018  		Comment: "The total count of approximate Region size, the default value is P99",
  3019  	},
  3020  	"einsteindb_approximate_region_total_size": {
  3021  		PromQL:  "sum(increase(einsteindb_raftstore_region_size_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3022  		Labels:  []string{"instance"},
  3023  		Comment: "The total size of approximate Region size",
  3024  	},
  3025  	"einsteindb_backup_range_size_total_count": {
  3026  		PromQL: "sum(increase(einsteindb_backup_range_size_bytes_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,cf)",
  3027  		Labels: []string{"instance", "cf"},
  3028  	},
  3029  	"einsteindb_backup_range_total_size": {
  3030  		PromQL: "sum(increase(einsteindb_backup_range_size_bytes_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,cf)",
  3031  		Labels: []string{"instance", "cf"},
  3032  	},
  3033  	"einsteindb_cop_ekv_cursor_operations_total_count": {
  3034  		PromQL: "sum(increase(einsteindb_coprocessor_scan_keys_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,req)",
  3035  		Labels: []string{"instance", "req"},
  3036  	},
  3037  	"einsteindb_cop_scan_keys_total_num": {
  3038  		PromQL: "sum(increase(einsteindb_coprocessor_scan_keys_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,req)",
  3039  		Labels: []string{"instance", "req"},
  3040  	},
  3041  	"einsteindb_cop_total_response_total_size": {
  3042  		PromQL: `sum(increase(einsteindb_coprocessor_response_bytes{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)`,
  3043  		Labels: []string{"instance"},
  3044  	},
  3045  	"einsteindb_grpc_req_batch_size_total_count": {
  3046  		PromQL: "sum(increase(einsteindb_server_grpc_req_batch_size_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3047  		Labels: []string{"instance"},
  3048  	},
  3049  	"einsteindb_grpc_req_batch_total_size": {
  3050  		PromQL: "sum(increase(einsteindb_server_grpc_req_batch_size_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3051  		Labels: []string{"instance"},
  3052  	},
  3053  	"einsteindb_grpc_resp_batch_size_total_count": {
  3054  		PromQL: "sum(increase(einsteindb_server_grpc_resp_batch_size_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3055  		Labels: []string{"instance"},
  3056  	},
  3057  	"einsteindb_grpc_resp_batch_total_size": {
  3058  		PromQL: "sum(increase(einsteindb_server_grpc_resp_batch_size_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3059  		Labels: []string{"instance"},
  3060  	},
  3061  	"einsteindb_raft_message_batch_size_total_count": {
  3062  		PromQL: "sum(increase(einsteindb_server_raft_message_batch_size_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3063  		Labels: []string{"instance"},
  3064  	},
  3065  	"einsteindb_raft_message_batch_total_size": {
  3066  		PromQL: "sum(increase(einsteindb_server_raft_message_batch_size_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3067  		Labels: []string{"instance"},
  3068  	},
  3069  	"einsteindb_raft_proposals_per_ready_total_count": {
  3070  		PromQL:  "sum(increase(einsteindb_raftstore_apply_proposal_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3071  		Labels:  []string{"instance"},
  3072  		Comment: "The total count of proposal count of all Regions in a mio tick",
  3073  	},
  3074  	"einsteindb_raft_proposals_per_total_ready": {
  3075  		PromQL:  "sum(increase(einsteindb_raftstore_apply_proposal_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3076  		Labels:  []string{"instance"},
  3077  		Comment: "The total proposal count of all Regions in a mio tick",
  3078  	},
  3079  	"einsteindb_request_batch_ratio_total_count": {
  3080  		PromQL:  "sum(increase(einsteindb_server_request_batch_ratio_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  3081  		Labels:  []string{"instance", "type"},
  3082  		Comment: "The total count of request batch output to input per EinsteinDB instance",
  3083  	},
  3084  	"einsteindb_request_batch_size_total_count": {
  3085  		PromQL:  "sum(increase(einsteindb_server_request_batch_size_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  3086  		Labels:  []string{"instance", "type"},
  3087  		Comment: "The total count of request batch per EinsteinDB instance",
  3088  	},
  3089  	"einsteindb_request_batch_total_ratio": {
  3090  		PromQL:  "sum(increase(einsteindb_server_request_batch_ratio_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  3091  		Labels:  []string{"instance", "type"},
  3092  		Comment: "The total ratio of request batch output to input per EinsteinDB instance",
  3093  	},
  3094  	"einsteindb_request_batch_total_size": {
  3095  		PromQL:  "sum(increase(einsteindb_server_request_batch_size_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  3096  		Labels:  []string{"instance", "type"},
  3097  		Comment: "The total size of requests into request batch per EinsteinDB instance",
  3098  	},
  3099  	"einsteindb_scheduler_keys_read_total_count": {
  3100  		PromQL:  "sum(increase(einsteindb_scheduler_ekv_command_key_read_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  3101  		Labels:  []string{"instance", "type"},
  3102  		Comment: "The total count of keys read by a command",
  3103  	},
  3104  	"einsteindb_scheduler_keys_total_read": {
  3105  		PromQL:  "sum(increase(einsteindb_scheduler_ekv_command_key_read_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  3106  		Labels:  []string{"instance", "type"},
  3107  		Comment: "The total count of keys read by command",
  3108  	},
  3109  	"einsteindb_scheduler_keys_total_written": {
  3110  		PromQL:  "sum(increase(einsteindb_scheduler_ekv_command_key_write_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  3111  		Labels:  []string{"instance", "type"},
  3112  		Comment: "The total count of keys written by a command",
  3113  	},
  3114  	"einsteindb_scheduler_keys_written_total_count": {
  3115  		PromQL:  "sum(increase(einsteindb_scheduler_ekv_command_key_write_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance,type)",
  3116  		Labels:  []string{"instance", "type"},
  3117  		Comment: "The total count of keys written by a command",
  3118  	},
  3119  	"einsteindb_snapshot_ekv_count_total_count": {
  3120  		PromQL:  "sum(increase(einsteindb_snapshot_ekv_count_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3121  		Labels:  []string{"instance"},
  3122  		Comment: "The total count of number of KV within a snapshot",
  3123  	},
  3124  	"einsteindb_snapshot_ekv_total_count": {
  3125  		PromQL:  "sum(increase(einsteindb_snapshot_ekv_count_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3126  		Labels:  []string{"instance"},
  3127  		Comment: "The total number of KV within a snapshot",
  3128  	},
  3129  	"einsteindb_snapshot_size_total_count": {
  3130  		PromQL:  "sum(increase(einsteindb_snapshot_size_count{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3131  		Labels:  []string{"instance"},
  3132  		Comment: "The total count of snapshot size",
  3133  	},
  3134  	"einsteindb_snapshot_total_size": {
  3135  		PromQL:  "sum(increase(einsteindb_snapshot_size_sum{$LABEL_CONDITIONS}[$RANGE_DURATION])) by (instance)",
  3136  		Labels:  []string{"instance"},
  3137  		Comment: "The total size of snapshot size",
  3138  	},
  3139  	"einsteindb_config_lmdb": {
  3140  		PromQL:  "einsteindb_config_lmdb{$LABEL_CONDITIONS}",
  3141  		Labels:  []string{"instance", "cf", "name"},
  3142  		Comment: "EinsteinDB lmdb config value",
  3143  	},
  3144  	"einsteindb_config_raftstore": {
  3145  		PromQL:  "einsteindb_config_raftstore{$LABEL_CONDITIONS}",
  3146  		Labels:  []string{"instance", "name"},
  3147  		Comment: "EinsteinDB lmdb config value",
  3148  	},
  3149  }