From 5a1fe03f0c25ed3fe3319b1f38e180377eca140d Mon Sep 17 00:00:00 2001 From: dzc <2388224167@qq.com> Date: Wed, 17 Jun 2026 20:22:19 +0800 Subject: [PATCH] =?UTF-8?q?feat:=E8=AF=B7=E6=B1=82=E6=97=A5=E5=BF=97?= =?UTF-8?q?=EF=BC=8C=E5=92=8C=E6=97=A5=E5=BF=97=E5=88=A0=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- database/add_index.sql | 23 + database/database.md | 2206 +++++++++++++++++ database/pjcloudx/pjcloudx-1.json | 100 + database/pjcloudx/pjcloudx-2.json | 15 + database/pjcloudx/pjcloudx-3.json | 44 + database/pjcloudx/pjcloudx-4.json | 754 ++++++ database/pjcloudx/sql-execute-map.js | 97 + database/result-1-v1.json | 364 +++ database/result-2-v1.json | 70 + database/result-3-v1.json | 294 +++ database/result-4-v1.json | 328 +++ database/result-5-v1.json | 46 + database/sql-execute-map.js | 152 ++ database/test/index.js | 283 +++ .../test/output/20260617-202016-round3.json | 324 +++ .../test/output/20260617-202016-round3.tsv | 21 + .../test/output/20260617-202105-round3.json | 324 +++ .../test/output/20260617-202105-round3.tsv | 21 + .../utils/discounts/discounts_tool.dart | 8 +- lib/common/utils/logger/logger_tool.dart | 69 +- lib/common/utils/manage/http_manage.dart | 64 + lib/common/utils/sync/sync_check_tool.dart | 52 + lib/common/values/constants.dart | 9 + lib/pages/panel/controller.dart | 2 +- lib/sub_screen/page/sub_product.dart | 34 +- 26 files changed, 5661 insertions(+), 45 deletions(-) create mode 100644 database/add_index.sql create mode 100644 database/database.md create mode 100644 database/pjcloudx/pjcloudx-1.json create mode 100644 database/pjcloudx/pjcloudx-2.json create mode 100644 database/pjcloudx/pjcloudx-3.json create mode 100644 database/pjcloudx/pjcloudx-4.json create mode 100644 database/pjcloudx/sql-execute-map.js create mode 100644 database/result-1-v1.json create mode 100644 database/result-2-v1.json create mode 100644 database/result-3-v1.json create mode 100644 database/result-4-v1.json create mode 100644 database/result-5-v1.json create mode 100644 database/sql-execute-map.js create mode 100644 database/test/index.js create mode 100644 database/test/output/20260617-202016-round3.json create mode 100644 database/test/output/20260617-202016-round3.tsv create mode 100644 database/test/output/20260617-202105-round3.json create mode 100644 database/test/output/20260617-202105-round3.tsv diff --git a/README.md b/README.md index a1b7e98..0006c29 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ flutter pub run build_runner build --delete-conflicting-outputs~ ``` ## flutter打包 ``` -flutter build apk --build-name 1.7.4 --build-number 174 +flutter build apk --build-name 1.9.0 --build-number 190 --build-name为版本号(展示) --build-number为版本号(内部比较) ``` diff --git a/database/add_index.sql b/database/add_index.sql new file mode 100644 index 0000000..57d9ba7 --- /dev/null +++ b/database/add_index.sql @@ -0,0 +1,23 @@ +CREATE INDEX idx_hard_order_tenant_del_user_mt +ON pjcloudx_hardware.hard_order (tenant_id, del_flag, user_id, merchant_type); + +CREATE INDEX idx_hard_manager_tenant_del_merchant_type +ON pjcloudx_hardware.hard_manager (tenant_id, del_flag, merchant_id, type); + +CREATE INDEX idx_hard_car_tenant_del_parent +ON pjcloudx_hardware.hard_car (tenant_id, del_flag, parent_car_id); + +CREATE INDEX idx_coupon_record_tenant_del_user_status_end +ON pjcloudx_wallet.act_coupon_record (tenant_id, del_flag, user_id, status, end_time); + +CREATE INDEX idx_mch_manage_tenant_del_visible_parent_cat +ON pjcloudx_wallet.mch_manage (tenant_id, del_flag, visible_mobile, parent_id, catgory_id); + +CREATE INDEX idx_mch_manage_tenant_del_visible_parent_canteen +ON pjcloudx_wallet.mch_manage (tenant_id, del_flag, visible_mobile, parent_id, canteen_is_open); + +CREATE INDEX idx_utd_del_mobile_fp_name +ON pjcloudx.user_trusted_device (del_flag, mobile_phone, device_fingerprint, device_name); + +CREATE INDEX idx_sys_file_del_file_name +ON pjcloudx.sys_file (del_flag, file_name); \ No newline at end of file diff --git a/database/database.md b/database/database.md new file mode 100644 index 0000000..333f379 --- /dev/null +++ b/database/database.md @@ -0,0 +1,2206 @@ +### 1、检查数据库版本 + +#### 执行命令 `SELECT VERSION();` + +#### 返回 + +| VERSION() | +| ----------------------------- | +| 5.7.25-OceanBase_CE-v4.2.1.10 | + +#### 执行命令 `SHOW VARIABLES LIKE 'version%';` + +#### 返回 + +| Variable_name | Value | +| ----------------------- | ----------------------------------------------------------------------------------------------------------------- | +| version | 5.7.25-OceanBase_CE-v4.2.1.10 | +| version_comment | OceanBase_CE 4.2.1.10 (r110000072024112010-28c1343085627e79a4f13c29121646bb889cf901) (Built Nov 20 2024 10:13:05) | +| version_compile_machine | | +| version_compile_os | | + +### 2、检查慢sql先检查`pjcloudx_wallet`、`pjcloudx_hardware`库,我无法给你设置linux变量所有尽可能给出具体的sql来排查问题 + +#### 执行命令 `DESC oceanbase.GV$OB_SQL_AUDIT;` + +#### 返回(json格式) + +```json +{ + "RECORDS": [ + { + "Field": "SVR_IP", + "Type": "varchar(46)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "SVR_PORT", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "REQUEST_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "SQL_EXEC_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "TRACE_ID", + "Type": "varchar(128)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "SID", + "Type": "bigint(20) unsigned", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "CLIENT_IP", + "Type": "varchar(46)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "CLIENT_PORT", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "TENANT_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "TENANT_NAME", + "Type": "varchar(64)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "EFFECTIVE_TENANT_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "USER_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "USER_NAME", + "Type": "varchar(64)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "USER_GROUP", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "USER_CLIENT_IP", + "Type": "varchar(46)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "DB_ID", + "Type": "bigint(20) unsigned", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "DB_NAME", + "Type": "varchar(128)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "SQL_ID", + "Type": "varchar(32)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "QUERY_SQL", + "Type": "longtext", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "PLAN_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "AFFECTED_ROWS", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "RETURN_ROWS", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "PARTITION_CNT", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "RET_CODE", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "QC_ID", + "Type": "bigint(20) unsigned", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "DFO_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "SQC_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "WORKER_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "EVENT", + "Type": "varchar(64)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "P1TEXT", + "Type": "varchar(64)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "P1", + "Type": "bigint(20) unsigned", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "P2TEXT", + "Type": "varchar(64)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "P2", + "Type": "bigint(20) unsigned", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "P3TEXT", + "Type": "varchar(64)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "P3", + "Type": "bigint(20) unsigned", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "LEVEL", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "WAIT_CLASS_ID", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "WAIT_CLASS#", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "WAIT_CLASS", + "Type": "varchar(64)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "STATE", + "Type": "varchar(19)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "WAIT_TIME_MICRO", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "TOTAL_WAIT_TIME_MICRO", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "TOTAL_WAITS", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "RPC_COUNT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "PLAN_TYPE", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "IS_INNER_SQL", + "Type": "tinyint(4)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "IS_EXECUTOR_RPC", + "Type": "tinyint(4)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "IS_HIT_PLAN", + "Type": "tinyint(4)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "REQUEST_TIME", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "ELAPSED_TIME", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "NET_TIME", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "NET_WAIT_TIME", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "QUEUE_TIME", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "DECODE_TIME", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "GET_PLAN_TIME", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "EXECUTE_TIME", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "APPLICATION_WAIT_TIME", + "Type": "bigint(20) unsigned", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "CONCURRENCY_WAIT_TIME", + "Type": "bigint(20) unsigned", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "USER_IO_WAIT_TIME", + "Type": "bigint(20) unsigned", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "SCHEDULE_TIME", + "Type": "bigint(20) unsigned", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "ROW_CACHE_HIT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "BLOOM_FILTER_CACHE_HIT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "BLOCK_CACHE_HIT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "DISK_READS", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "RETRY_CNT", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "TABLE_SCAN", + "Type": "tinyint(4)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "CONSISTENCY_LEVEL", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "MEMSTORE_READ_ROW_COUNT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "SSSTORE_READ_ROW_COUNT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "DATA_BLOCK_READ_CNT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "DATA_BLOCK_CACHE_HIT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "INDEX_BLOCK_READ_CNT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "INDEX_BLOCK_CACHE_HIT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "BLOCKSCAN_BLOCK_CNT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "BLOCKSCAN_ROW_CNT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "PUSHDOWN_STORAGE_FILTER_ROW_CNT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "REQUEST_MEMORY_USED", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "EXPECTED_WORKER_COUNT", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "USED_WORKER_COUNT", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "SCHED_INFO", + "Type": "varchar(16384)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "FUSE_ROW_CACHE_HIT", + "Type": "bigint(20)", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "PS_CLIENT_STMT_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "PS_INNER_STMT_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "TX_ID", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "SNAPSHOT_VERSION", + "Type": "bigint(20) unsigned", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "REQUEST_TYPE", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "IS_BATCHED_MULTI_STMT", + "Type": "tinyint(4)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "OB_TRACE_INFO", + "Type": "varchar(4096)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "PLAN_HASH", + "Type": "bigint(20) unsigned", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "LOCK_FOR_READ_TIME", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "PARAMS_VALUE", + "Type": "longtext", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "RULE_NAME", + "Type": "varchar(256)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "PARTITION_HIT", + "Type": "tinyint(4)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "TX_INTERNAL_ROUTING", + "Type": "bigint(20)", + "Null": "NO", + "Key": "", + "Default": "", + "Extra": "" + }, + { + "Field": "TX_STATE_VERSION", + "Type": "bigint(20) unsigned", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "FLT_TRACE_ID", + "Type": "varchar(1024)", + "Null": "NO", + "Key": "", + "Default": "NULL", + "Extra": "" + }, + { + "Field": "NETWORK_WAIT_TIME", + "Type": "bigint(20) unsigned", + "Null": "YES", + "Key": "", + "Default": "NULL", + "Extra": "" + } + ] +} +``` + +#### 执行命令 `SELECT * FROM oceanbase.GV$OB_SQL_AUDIT LIMIT 1;` + +#### 返回json + +```json +{ + "RECORDS": [ + { + "SVR_IP": "172.17.0.2", + "SVR_PORT": 2882, + "REQUEST_ID": 3523880508, + "SQL_EXEC_ID": 3523883676, + "TRACE_ID": "YB42AC110002-00062BB9A13F1BC1-0-0", + "SID": 1, + "CLIENT_IP": "0.0.0.0", + "CLIENT_PORT": 0, + "TENANT_ID": 1, + "TENANT_NAME": "sys", + "EFFECTIVE_TENANT_ID": 1, + "USER_ID": 200001, + "USER_NAME": "root", + "USER_GROUP": 0, + "USER_CLIENT_IP": "0.0.0.0", + "DB_ID": 201001, + "DB_NAME": "oceanbase", + "SQL_ID": "24D486F20861EBD9E0217692DB0E9C61", + "QUERY_SQL": " update __all_weak_read_service set min_version=1781667875338771126, max_version=1781667875338771126 where tenant_id = 1 and level_id = 0 and level_value = '' and min_version = 1781667875138598698 and max_version = 1781667875138598698 ", + "PLAN_ID": 62175243, + "AFFECTED_ROWS": 1, + "RETURN_ROWS": 0, + "PARTITION_CNT": 1, + "RET_CODE": 0, + "QC_ID": 0, + "DFO_ID": 0, + "SQC_ID": 0, + "WORKER_ID": 0, + "EVENT": "", + "P1TEXT": "", + "P1": 0, + "P2TEXT": "", + "P2": 0, + "P3TEXT": "", + "P3": 0, + "LEVEL": 0, + "WAIT_CLASS_ID": 100, + "WAIT_CLASS#": 0, + "WAIT_CLASS": "OTHER", + "STATE": "MAX_WAIT TIME ZERO", + "WAIT_TIME_MICRO": 0, + "TOTAL_WAIT_TIME_MICRO": 0, + "TOTAL_WAITS": 0, + "RPC_COUNT": 0, + "PLAN_TYPE": 1, + "IS_INNER_SQL": 1, + "IS_EXECUTOR_RPC": 0, + "IS_HIT_PLAN": 1, + "REQUEST_TIME": 1781667875538413, + "ELAPSED_TIME": 361, + "NET_TIME": 0, + "NET_WAIT_TIME": 0, + "QUEUE_TIME": 0, + "DECODE_TIME": 0, + "GET_PLAN_TIME": 80, + "EXECUTE_TIME": 281, + "APPLICATION_WAIT_TIME": 0, + "CONCURRENCY_WAIT_TIME": 0, + "USER_IO_WAIT_TIME": 0, + "SCHEDULE_TIME": 0, + "ROW_CACHE_HIT": 0, + "BLOOM_FILTER_CACHE_HIT": 0, + "BLOCK_CACHE_HIT": 0, + "DISK_READS": 0, + "RETRY_CNT": 0, + "TABLE_SCAN": 0, + "CONSISTENCY_LEVEL": 3, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 0, + "DATA_BLOCK_READ_CNT": 0, + "DATA_BLOCK_CACHE_HIT": 0, + "INDEX_BLOCK_READ_CNT": 0, + "INDEX_BLOCK_CACHE_HIT": 0, + "BLOCKSCAN_BLOCK_CNT": 0, + "BLOCKSCAN_ROW_CNT": 0, + "PUSHDOWN_STORAGE_FILTER_ROW_CNT": 0, + "REQUEST_MEMORY_USED": 321336, + "EXPECTED_WORKER_COUNT": 0, + "USED_WORKER_COUNT": 0, + "SCHED_INFO": null, + "FUSE_ROW_CACHE_HIT": 0, + "PS_CLIENT_STMT_ID": -1, + "PS_INNER_STMT_ID": -1, + "TX_ID": 675106753, + "SNAPSHOT_VERSION": 1781667875523066571, + "REQUEST_TYPE": 1, + "IS_BATCHED_MULTI_STMT": 0, + "OB_TRACE_INFO": null, + "PLAN_HASH": 10435171333981900908, + "LOCK_FOR_READ_TIME": 0, + "PARAMS_VALUE": "", + "RULE_NAME": "", + "PARTITION_HIT": 1, + "TX_INTERNAL_ROUTING": 0, + "TX_STATE_VERSION": 0, + "FLT_TRACE_ID": "", + "NETWORK_WAIT_TIME": 0 + } + ] +} +``` + +#### 执行命令 + +```sql +SELECT + +FROM oceanbase.GV$OB_SQL_AUDIT +LIMIT 1;SELECT + FROM_UNIXTIME(REQUEST_TIME / 1000000) AS req_time, + TENANT_NAME, + DB_NAME, + USER_NAME, + IS_INNER_SQL, + SQL_ID, + ROUND(ELAPSED_TIME / 1000, 2) AS elapsed_ms, + LEFT(REPLACE(QUERY_SQL, '\n', ' '), 200) AS sample_sql +FROM oceanbase.GV$OB_SQL_AUDIT +ORDER BY REQUEST_TIME DESC +LIMIT 20; +``` + +#### 返回(json格式) + +```json +{ + "RECORDS": [ + { + "SVR_IP": "172.17.0.2", + "SVR_PORT": 2882, + "REQUEST_ID": 3523917827, + "SQL_EXEC_ID": 3523920995, + "TRACE_ID": "YB42AC110002-00062BB9A13F2398-0-0", + "SID": 1, + "CLIENT_IP": "0.0.0.0", + "CLIENT_PORT": 0, + "TENANT_ID": 1, + "TENANT_NAME": "sys", + "EFFECTIVE_TENANT_ID": 1, + "USER_ID": 200001, + "USER_NAME": "root", + "USER_GROUP": 0, + "USER_CLIENT_IP": "0.0.0.0", + "DB_ID": 201001, + "DB_NAME": "oceanbase", + "SQL_ID": "24D486F20861EBD9E0217692DB0E9C61", + "QUERY_SQL": " update __all_weak_read_service set min_version=1781668277379493867, max_version=1781668277379493867 where tenant_id = 1 and level_id = 0 and level_value = '' and min_version = 1781668277179508812 and max_version = 1781668277179508812 ", + "PLAN_ID": 62175243, + "AFFECTED_ROWS": 1, + "RETURN_ROWS": 0, + "PARTITION_CNT": 1, + "RET_CODE": 0, + "QC_ID": 0, + "DFO_ID": 0, + "SQC_ID": 0, + "WORKER_ID": 0, + "EVENT": "", + "P1TEXT": "", + "P1": 0, + "P2TEXT": "", + "P2": 0, + "P3TEXT": "", + "P3": 0, + "LEVEL": 0, + "WAIT_CLASS_ID": 100, + "WAIT_CLASS#": 0, + "WAIT_CLASS": "OTHER", + "STATE": "MAX_WAIT TIME ZERO", + "WAIT_TIME_MICRO": 0, + "TOTAL_WAIT_TIME_MICRO": 0, + "TOTAL_WAITS": 0, + "RPC_COUNT": 0, + "PLAN_TYPE": 1, + "IS_INNER_SQL": 1, + "IS_EXECUTOR_RPC": 0, + "IS_HIT_PLAN": 1, + "REQUEST_TIME": 1781668277579277, + "ELAPSED_TIME": 381, + "NET_TIME": 0, + "NET_WAIT_TIME": 0, + "QUEUE_TIME": 0, + "DECODE_TIME": 0, + "GET_PLAN_TIME": 86, + "EXECUTE_TIME": 295, + "APPLICATION_WAIT_TIME": 0, + "CONCURRENCY_WAIT_TIME": 0, + "USER_IO_WAIT_TIME": 0, + "SCHEDULE_TIME": 0, + "ROW_CACHE_HIT": 0, + "BLOOM_FILTER_CACHE_HIT": 0, + "BLOCK_CACHE_HIT": 0, + "DISK_READS": 0, + "RETRY_CNT": 0, + "TABLE_SCAN": 0, + "CONSISTENCY_LEVEL": 3, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 0, + "DATA_BLOCK_READ_CNT": 0, + "DATA_BLOCK_CACHE_HIT": 0, + "INDEX_BLOCK_READ_CNT": 0, + "INDEX_BLOCK_CACHE_HIT": 0, + "BLOCKSCAN_BLOCK_CNT": 0, + "BLOCKSCAN_ROW_CNT": 0, + "PUSHDOWN_STORAGE_FILTER_ROW_CNT": 0, + "REQUEST_MEMORY_USED": 321336, + "EXPECTED_WORKER_COUNT": 0, + "USED_WORKER_COUNT": 0, + "SCHED_INFO": null, + "FUSE_ROW_CACHE_HIT": 0, + "PS_CLIENT_STMT_ID": -1, + "PS_INNER_STMT_ID": -1, + "TX_ID": 675113066, + "SNAPSHOT_VERSION": 1781668277542193249, + "REQUEST_TYPE": 1, + "IS_BATCHED_MULTI_STMT": 0, + "OB_TRACE_INFO": null, + "PLAN_HASH": 10435171333981900908, + "LOCK_FOR_READ_TIME": 0, + "PARAMS_VALUE": "", + "RULE_NAME": "", + "PARTITION_HIT": 1, + "TX_INTERNAL_ROUTING": 0, + "TX_STATE_VERSION": 0, + "FLT_TRACE_ID": "", + "NETWORK_WAIT_TIME": 0 + }, + { + "req_time": "17/6/2026 11:52:08.8238", + "TENANT_NAME": "sys", + "DB_NAME": "", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "B3055B539C68B64BABC6B15ACAB50DC3", + "elapsed_ms": 4.320000171661377, + "sample_sql": "SHOW COLUMNS FROM `oceanbase`.`GV$OB_SQL_AUDIT`" + }, + { + "req_time": "17/6/2026 11:52:08.8228", + "TENANT_NAME": "sys", + "DB_NAME": "", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "90BB5FDF379641120D76894CD0C56EC4", + "elapsed_ms": 0.15000000596046449, + "sample_sql": "SELECT * FROM `oceanbase`.`GV$OB_SQL_AUDIT` LIMIT 0" + }, + { + "req_time": "17/6/2026 11:52:08.8215", + "TENANT_NAME": "sys", + "DB_NAME": "", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "599E21A4AEACE0E73878D0392DCE8D02", + "elapsed_ms": 0.27000001072883608, + "sample_sql": "SELECT * \r FROM oceanbase.GV$OB_SQL_AUDIT \r LIMIT 1" + }, + { + "req_time": "17/6/2026 11:52:08.819", + "TENANT_NAME": "sys", + "DB_NAME": "", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "8482C19F04EF03269F8D83A80B7DC877", + "elapsed_ms": 1.2599999904632569, + "sample_sql": "SHOW STATUS" + }, + { + "req_time": "17/6/2026 11:52:08.8166", + "TENANT_NAME": "sys", + "DB_NAME": "", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "8482C19F04EF03269F8D83A80B7DC877", + "elapsed_ms": 1.7000000476837159, + "sample_sql": "SHOW STATUS" + }, + { + "req_time": "17/6/2026 11:52:08.8153", + "TENANT_NAME": "sys", + "DB_NAME": "oceanbase", + "USER_NAME": "root", + "IS_INNER_SQL": 1, + "SQL_ID": "2E2DB7AC3B158DCB0873675E95DA0B28", + "elapsed_ms": 0.30000001192092898, + "sample_sql": "select 1 from __all_sys_variable where tenant_id=0 and name='profiling';" + }, + { + "req_time": "17/6/2026 11:52:08.8145", + "TENANT_NAME": "sys", + "DB_NAME": "", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "AE05C5458DF68A1DB23BCCE649B50E45", + "elapsed_ms": 1.309999942779541, + "sample_sql": "SET PROFILING = 1" + }, + { + "req_time": "17/6/2026 11:52:08.8102", + "TENANT_NAME": "sys", + "DB_NAME": "oceanbase", + "USER_NAME": "root", + "IS_INNER_SQL": 1, + "SQL_ID": "24D486F20861EBD9E0217692DB0E9C61", + "elapsed_ms": 0.3799999952316284, + "sample_sql": " update __all_weak_read_service set min_version=1781668328610450210, max_version=1781668328610450210 where tenant_id = 1 and level_id = 0 and level_value = '' and min_version = 178166832841040" + }, + { + "req_time": "17/6/2026 11:52:08.7405", + "TENANT_NAME": "sys", + "DB_NAME": "ocs", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "2983E372002117946E00660266EB3683", + "elapsed_ms": 0.15000000596046449, + "sample_sql": "SELECT * FROM `dag_instance` WHERE is_finished = false" + }, + { + "req_time": "17/6/2026 11:52:08.7369", + "TENANT_NAME": "sys", + "DB_NAME": "ocs", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "549981E00A3D95F03DD5A9EF6044AA20", + "elapsed_ms": 3.2699999809265138, + "sample_sql": "SHOW DATABASES" + }, + { + "req_time": "17/6/2026 11:52:08.6808", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "elapsed_ms": 4.559999942779541, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '8c1ae9b" + }, + { + "req_time": "17/6/2026 11:52:08.6101", + "TENANT_NAME": "sys", + "DB_NAME": "oceanbase", + "USER_NAME": "root", + "IS_INNER_SQL": 1, + "SQL_ID": "24D486F20861EBD9E0217692DB0E9C61", + "elapsed_ms": 0.3100000023841858, + "sample_sql": " update __all_weak_read_service set min_version=1781668328410404625, max_version=1781668328410404625 where tenant_id = 1 and level_id = 0 and level_value = '' and min_version = 178166832821026" + }, + { + "req_time": "17/6/2026 11:52:08.6015", + "TENANT_NAME": "sys", + "DB_NAME": "seata", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "D0A4F18E0349F173B94F895D1FB95B5F", + "elapsed_ms": 0.1899999976158142, + "sample_sql": "SET autocommit=1" + }, + { + "req_time": "17/6/2026 11:52:08.6015", + "TENANT_NAME": "sys", + "DB_NAME": "seata", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "D0A4F18E0349F173B94F895D1FB95B5F", + "elapsed_ms": 0.15000000596046449, + "sample_sql": "SET autocommit=1" + }, + { + "req_time": "17/6/2026 11:52:08.6008", + "TENANT_NAME": "sys", + "DB_NAME": "seata", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "D0A4F18E0349F173B94F895D1FB95B5F", + "elapsed_ms": 0.15000000596046449, + "sample_sql": "SET autocommit=1" + }, + { + "req_time": "17/6/2026 11:52:08.5985", + "TENANT_NAME": "sys", + "DB_NAME": "seata", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "FFFCA4D67EA0A788813031B8BBC3B329", + "elapsed_ms": 0.07999999821186066, + "sample_sql": "commit" + }, + { + "req_time": "17/6/2026 11:52:08.5984", + "TENANT_NAME": "sys", + "DB_NAME": "seata", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "FFFCA4D67EA0A788813031B8BBC3B329", + "elapsed_ms": 0.12999999523162843, + "sample_sql": "commit" + }, + { + "req_time": "17/6/2026 11:52:08.5983", + "TENANT_NAME": "sys", + "DB_NAME": "seata", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "FFFCA4D67EA0A788813031B8BBC3B329", + "elapsed_ms": 0.10999999940395355, + "sample_sql": "commit" + }, + { + "req_time": "17/6/2026 11:52:08.5981", + "TENANT_NAME": "sys", + "DB_NAME": "seata", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "04160ED80C327FCD7A2BB9796332B934", + "elapsed_ms": 0.2199999988079071, + "sample_sql": "UPDATE distributed_lock SET lock_value=' ', expire=0 WHERE lock_key='RetryCommitting'" + }, + { + "req_time": "17/6/2026 11:52:08.5981", + "TENANT_NAME": "sys", + "DB_NAME": "seata", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "D0A4F18E0349F173B94F895D1FB95B5F", + "elapsed_ms": 0.1899999976158142, + "sample_sql": "SET autocommit=1" + } + ] +} +``` + +#### 执行命令 + +```sql +SELECT + TENANT_NAME, + DB_NAME, + COUNT(*) AS cnt, + SUM(CASE WHEN IS_INNER_SQL = 0 THEN 1 ELSE 0 END) AS user_sql_cnt, + SUM(CASE WHEN IS_INNER_SQL = 1 THEN 1 ELSE 0 END) AS inner_sql_cnt +FROM oceanbase.GV$OB_SQL_AUDIT +WHERE REQUEST_TIME >= UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 HOUR)) * 1000000 +GROUP BY TENANT_NAME, DB_NAME +ORDER BY cnt DESC +LIMIT 100; +``` + +#### 返回(json格式) + +```json +{ + "RECORDS": [ + { + "TENANT_NAME": "sys", + "DB_NAME": "seata", + "cnt": 7753, + "user_sql_cnt": 7753.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "oceanbase", + "cnt": 4186, + "user_sql_cnt": 0.0, + "inner_sql_cnt": 4186.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx", + "cnt": 2408, + "user_sql_cnt": 2408.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "cnt": 596, + "user_sql_cnt": 596.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "ocs", + "cnt": 567, + "user_sql_cnt": 567.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_hardware", + "cnt": 487, + "user_sql_cnt": 487.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "uabase_dini", + "cnt": 361, + "user_sql_cnt": 361.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_flow", + "cnt": 172, + "user_sql_cnt": 172.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_config", + "cnt": 119, + "user_sql_cnt": 119.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_integrated", + "cnt": 74, + "user_sql_cnt": 74.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "", + "cnt": 30, + "user_sql_cnt": 30.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_app", + "cnt": 22, + "user_sql_cnt": 22.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_thirdparty", + "cnt": 22, + "user_sql_cnt": 22.0, + "inner_sql_cnt": 0.0 + }, + { + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_supermarket", + "cnt": 15, + "user_sql_cnt": 15.0, + "inner_sql_cnt": 0.0 + } + ] +} +``` + +#### 执行sql + +```sql +SELECT + FROM_UNIXTIME(REQUEST_TIME / 1000000) AS req_time, + TENANT_NAME, + DB_NAME, + USER_NAME, + IS_INNER_SQL, + SQL_ID, + PLAN_ID, + ROUND(ELAPSED_TIME / 1000, 2) AS elapsed_ms, + ROUND(EXECUTE_TIME / 1000, 2) AS execute_ms, + ROUND(QUEUE_TIME / 1000, 2) AS queue_ms, + RETURN_ROWS, + AFFECTED_ROWS, + TABLE_SCAN, + LEFT(REPLACE(QUERY_SQL, '\n', ' '), 300) AS sample_sql +FROM oceanbase.GV$OB_SQL_AUDIT +WHERE REQUEST_TIME >= UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 HOUR)) * 1000000 + AND DB_NAME IN ('pjcloudx_wallet', 'pjcloudx_hardware') +ORDER BY REQUEST_TIME DESC +LIMIT 50; +``` + +#### 返回(json格式) + +```json +{ + "RECORDS": [ + { + "req_time": "17/6/2026 11:55:43.4267", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "2C4AE8DCC737A2806BB612A4891D7A3D", + "PLAN_ID": 62242462, + "elapsed_ms": 0.9700000286102295, + "execute_ms": 0.8600000143051148, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 10, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:43.4251", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "A577C7372963DC99F31CA516DEBBD5CA", + "PLAN_ID": 62242461, + "elapsed_ms": 0.5400000214576721, + "execute_ms": 0.4399999976158142, + "queue_ms": 0.019999999552965165, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.catgory_id = 1917111404413517825 AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:40.1117", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "F3B83B175E6A8D1E9AEA3FC1C39D36C4", + "PLAN_ID": 62235147, + "elapsed_ms": 0.3400000035762787, + "execute_ms": 0.20000000298023225, + "queue_ms": 0.05999999865889549, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:38.9982", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "407345B8B4FD51DD2B212C918799AABA", + "PLAN_ID": 62242946, + "elapsed_ms": 0.8799999952316284, + "execute_ms": 0.7900000214576721, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 10, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:38.9954", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "A577C7372963DC99F31CA516DEBBD5CA", + "PLAN_ID": 62242461, + "elapsed_ms": 0.5299999713897705, + "execute_ms": 0.4099999964237213, + "queue_ms": 0.05999999865889549, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.catgory_id = 1917111404413517825 AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:38.4649", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "2C4AE8DCC737A2806BB612A4891D7A3D", + "PLAN_ID": 62242462, + "elapsed_ms": 0.8199999928474426, + "execute_ms": 0.7300000190734863, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 10, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:38.4634", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "A577C7372963DC99F31CA516DEBBD5CA", + "PLAN_ID": 62242461, + "elapsed_ms": 0.550000011920929, + "execute_ms": 0.41999998688697817, + "queue_ms": 0.05000000074505806, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.catgory_id = 1917111404413517825 AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:36.9507", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "F3B83B175E6A8D1E9AEA3FC1C39D36C4", + "PLAN_ID": 62235147, + "elapsed_ms": 0.28999999165534975, + "execute_ms": 0.18000000715255738, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:35.9152", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "407345B8B4FD51DD2B212C918799AABA", + "PLAN_ID": 62242946, + "elapsed_ms": 0.8600000143051148, + "execute_ms": 0.7799999713897705, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 10, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:35.9136", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "A577C7372963DC99F31CA516DEBBD5CA", + "PLAN_ID": 62242461, + "elapsed_ms": 0.5699999928474426, + "execute_ms": 0.4399999976158142, + "queue_ms": 0.05000000074505806, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.catgory_id = 1917111404413517825 AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:35.3866", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "2C4AE8DCC737A2806BB612A4891D7A3D", + "PLAN_ID": 62242462, + "elapsed_ms": 0.8399999737739563, + "execute_ms": 0.7599999904632568, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 10, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:35.385", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "A577C7372963DC99F31CA516DEBBD5CA", + "PLAN_ID": 62242461, + "elapsed_ms": 0.5699999928474426, + "execute_ms": 0.4300000071525574, + "queue_ms": 0.05000000074505806, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.catgory_id = 1917111404413517825 AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:32.5551", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "F3B83B175E6A8D1E9AEA3FC1C39D36C4", + "PLAN_ID": 62235147, + "elapsed_ms": 0.28999999165534975, + "execute_ms": 0.18000000715255738, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:32.0484", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_hardware", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "D0A4F18E0349F173B94F895D1FB95B5F", + "PLAN_ID": 0, + "elapsed_ms": 0.1599999964237213, + "execute_ms": 0.05999999865889549, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SET autocommit=1" + }, + { + "req_time": "17/6/2026 11:55:32.0475", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_hardware", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "52717C90AF3126884CFCBD8313F107FF", + "PLAN_ID": 62235265, + "elapsed_ms": 0.33000001311302187, + "execute_ms": 0.23000000417232514, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT id, hard_group_id, merchant_id, dept_id, name, type, mq_client_id, unique_code, main_topic, mq_socket_address, mq_socket_port, mq_username, mq_password, is_take_food, face_app_id, face_sdk_key, face_active_key, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM hard_mana" + }, + { + "req_time": "17/6/2026 11:55:32.0461", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_hardware", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "FFFCA4D67EA0A788813031B8BBC3B329", + "PLAN_ID": 0, + "elapsed_ms": 0.12999999523162843, + "execute_ms": 0.05999999865889549, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "commit" + }, + { + "req_time": "17/6/2026 11:55:32.045", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_hardware", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "80EFF074740855D524A66272D79347EA", + "PLAN_ID": 62235264, + "elapsed_ms": 0.25999999046325686, + "execute_ms": 0.18000000715255738, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 1, + "TABLE_SCAN": 0, + "sample_sql": "UPDATE hard_order SET order_status = '5', pay_price = 1980, pay_time = '2026-06-17 11:55:32.042707', update_by = '17280590045', update_time = '2026-06-17 11:55:32.042832' WHERE id = 2067093761016188930 AND del_flag = '0' AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:32.0447", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_hardware", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "E1B8882A266AF42BD1453489C029CBB8", + "PLAN_ID": 62235258, + "elapsed_ms": 0.09000000357627869, + "execute_ms": 0.019999999552965165, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT @@session.transaction_read_only" + }, + { + "req_time": "17/6/2026 11:55:32.0431", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "D0A4F18E0349F173B94F895D1FB95B5F", + "PLAN_ID": 0, + "elapsed_ms": 0.18000000715255738, + "execute_ms": 0.07999999821186066, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SET autocommit=1" + }, + { + "req_time": "17/6/2026 11:55:32.0403", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "FFFCA4D67EA0A788813031B8BBC3B329", + "PLAN_ID": 0, + "elapsed_ms": 0.1599999964237213, + "execute_ms": 0.09000000357627869, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "commit" + }, + { + "req_time": "17/6/2026 11:55:32.0395", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "6F2FC049FEF085B688506AEFFC440480", + "PLAN_ID": 62235263, + "elapsed_ms": 0.27000001072883608, + "execute_ms": 0.1899999976158142, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 1, + "TABLE_SCAN": 0, + "sample_sql": "INSERT INTO wallet_transaction (id, user_id, dept_id, wallet_id, biz_type, biz_id, title, price, balance, version, create_by, create_time, update_by, update_time, del_flag, tenant_id) VALUES (2067093761049751553, 1972567737769897985, 1899989418344390658, 1972577233426583554, '4', '206709376101618893" + }, + { + "req_time": "17/6/2026 11:55:32.0391", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "E1B8882A266AF42BD1453489C029CBB8", + "PLAN_ID": 62235261, + "elapsed_ms": 0.09000000357627869, + "execute_ms": 0.019999999552965165, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT @@session.transaction_read_only" + }, + { + "req_time": "17/6/2026 11:55:32.0375", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "80E7A7B065C86D4A79B228382E761086", + "PLAN_ID": 62235262, + "elapsed_ms": 0.38999998569488528, + "execute_ms": 0.28999999165534975, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 1, + "TABLE_SCAN": 0, + "sample_sql": "UPDATE wallet_manage SET balance = balance - 1980, total_expense = total_expense + 1980, version = version + 1 WHERE del_flag = '0' AND (id = 1972577233426583554) AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:32.0372", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "E1B8882A266AF42BD1453489C029CBB8", + "PLAN_ID": 62235261, + "elapsed_ms": 0.10999999940395355, + "execute_ms": 0.029999999329447748, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT @@session.transaction_read_only" + }, + { + "req_time": "17/6/2026 11:55:32.0354", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "7523DB5CA61B44A6E48F81F4244E47A0", + "PLAN_ID": 62235260, + "elapsed_ms": 0.23999999463558198, + "execute_ms": 0.15000000596046449, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT id, user_id, wallet_type_id, dept_id, card_number, balance, total_expense, total_recharge, freeze_price, is_freeze, active_bind_time, status, version, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_manage WHERE id = 1972577233426583554 AND del_flag = '0' AND t" + }, + { + "req_time": "17/6/2026 11:55:32.0339", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "FAF0B5463BBDBCCA9F8584234D5908C2", + "PLAN_ID": 0, + "elapsed_ms": 0.2199999988079071, + "execute_ms": 0.09000000357627869, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SET autocommit=0" + }, + { + "req_time": "17/6/2026 11:55:32.0314", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_hardware", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "81C0BF564B80EB8D95217E765FAEC448", + "PLAN_ID": 62235259, + "elapsed_ms": 0.4000000059604645, + "execute_ms": 0.30000001192092898, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 1, + "TABLE_SCAN": 0, + "sample_sql": "INSERT INTO hard_order (id, user_id, user_dept_id, merchant_id, merchant_type, merchant_dept_id, wallet_id, order_type, order_status, pay_type, sys_type, total_price, extra_price, pay_price, is_offline_order, product_desc, create_by, create_time, update_by, update_time, del_flag, tenant_id) VALUES (" + }, + { + "req_time": "17/6/2026 11:55:32.031", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_hardware", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "E1B8882A266AF42BD1453489C029CBB8", + "PLAN_ID": 62235258, + "elapsed_ms": 0.09000000357627869, + "execute_ms": 0.029999999329447748, + "queue_ms": 0.019999999552965165, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT @@session.transaction_read_only" + }, + { + "req_time": "17/6/2026 11:55:32.0282", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "E99DBD2BC95F860A5F3962DCAA8ADC45", + "PLAN_ID": 62235257, + "elapsed_ms": 0.3100000023841858, + "execute_ms": 0.2199999988079071, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.user_id, t.wallet_type_id, t.dept_id, t.card_number, t.balance, t.total_expense, t.total_recharge, t.freeze_price, t.is_freeze, t.active_bind_time, t.status, t.version, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id, t1.name AS walletTypeName, t1.uniqu" + }, + { + "req_time": "17/6/2026 11:55:32.0061", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "F3B83B175E6A8D1E9AEA3FC1C39D36C4", + "PLAN_ID": 62235147, + "elapsed_ms": 0.3100000023841858, + "execute_ms": 0.1899999976158142, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:32.0025", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_hardware", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "FAF0B5463BBDBCCA9F8584234D5908C2", + "PLAN_ID": 0, + "elapsed_ms": 0.25, + "execute_ms": 0.10000000149011612, + "queue_ms": 0.05000000074505806, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SET autocommit=0" + }, + { + "req_time": "17/6/2026 11:55:30.3738", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "407345B8B4FD51DD2B212C918799AABA", + "PLAN_ID": 62242946, + "elapsed_ms": 0.8100000023841858, + "execute_ms": 0.7300000190734863, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 10, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:30.3724", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "A577C7372963DC99F31CA516DEBBD5CA", + "PLAN_ID": 62242461, + "elapsed_ms": 0.46000000834465029, + "execute_ms": 0.3700000047683716, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.catgory_id = 1917111404413517825 AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:29.9169", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "2C4AE8DCC737A2806BB612A4891D7A3D", + "PLAN_ID": 62242462, + "elapsed_ms": 0.8199999928474426, + "execute_ms": 0.75, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 10, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:29.9153", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "A577C7372963DC99F31CA516DEBBD5CA", + "PLAN_ID": 62242461, + "elapsed_ms": 0.6000000238418579, + "execute_ms": 0.46000000834465029, + "queue_ms": 0.05999999865889549, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.catgory_id = 1917111404413517825 AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:28.4892", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "0634F31AAF585CA78923D241EF91AB7C", + "PLAN_ID": 62235170, + "elapsed_ms": 0.5899999737739563, + "execute_ms": 0.5099999904632568, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 2, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:28.4877", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "PLAN_ID": 62235165, + "elapsed_ms": 0.5099999904632568, + "execute_ms": 0.3700000047683716, + "queue_ms": 0.05999999865889549, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = 1917481386427260929 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:28.352", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "456BC8375C4B7B6E222B78BADB7922FD", + "PLAN_ID": 62237197, + "elapsed_ms": 0.30000001192092898, + "execute_ms": 0.17000000178813935, + "queue_ms": 0.05000000074505806, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT a.id, a.coupon_id, a.user_id, a.user_name, a.coupon_code, a.status, a.coupon_name, a.coupon_type, a.face_value, a.min_point, a.start_time, a.end_time, a.use_time, a.order_id, a.use_amount, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.tenant_id FROM act_coupon_record a" + }, + { + "req_time": "17/6/2026 11:55:28.2457", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "DBB3F758E483F87C27ECFE73C3980216", + "PLAN_ID": 62235183, + "elapsed_ms": 0.17000000178813935, + "execute_ms": 0.10000000149011612, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 3, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT id, name, icon, unique_code, is_rule, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_type WHERE del_flag = '0' AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:28.235", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "72232D3632B6E842E8DA58FC16E6EE4E", + "PLAN_ID": 62235182, + "elapsed_ms": 0.2800000011920929, + "execute_ms": 0.20000000298023225, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 2, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT id, user_id, wallet_type_id, dept_id, card_number, balance, total_expense, total_recharge, freeze_price, is_freeze, active_bind_time, status, version, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_manage WHERE del_flag = '0' AND (user_id = 1972567737769897985" + }, + { + "req_time": "17/6/2026 11:55:28.2337", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "30E53CB2C758ED3B74795ECA38F6FA74", + "PLAN_ID": 62235181, + "elapsed_ms": 0.47999998927116396, + "execute_ms": 0.3499999940395355, + "queue_ms": 0.05000000074505806, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT COUNT(*) AS total FROM wallet_manage WHERE del_flag = '0' AND (user_id = 1972567737769897985) AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:28.1513", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "F3B83B175E6A8D1E9AEA3FC1C39D36C4", + "PLAN_ID": 62235147, + "elapsed_ms": 0.3199999928474426, + "execute_ms": 0.1899999976158142, + "queue_ms": 0.05000000074505806, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:28.0028", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "2C4AE8DCC737A2806BB612A4891D7A3D", + "PLAN_ID": 62242462, + "elapsed_ms": 0.7599999904632568, + "execute_ms": 0.6700000166893005, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 10, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:28.0013", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "A577C7372963DC99F31CA516DEBBD5CA", + "PLAN_ID": 62242461, + "elapsed_ms": 0.5199999809265137, + "execute_ms": 0.3700000047683716, + "queue_ms": 0.07000000029802323, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.catgory_id = 1976117666614280194 AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:27.9225", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "F3B83B175E6A8D1E9AEA3FC1C39D36C4", + "PLAN_ID": 62235147, + "elapsed_ms": 0.36000001430511477, + "execute_ms": 0.2199999988079071, + "queue_ms": 0.05000000074505806, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:26.5643", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "2C4AE8DCC737A2806BB612A4891D7A3D", + "PLAN_ID": 62242462, + "elapsed_ms": 0.8700000047683716, + "execute_ms": 0.7799999713897705, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 10, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:26.5628", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "A577C7372963DC99F31CA516DEBBD5CA", + "PLAN_ID": 62242461, + "elapsed_ms": 0.5199999809265137, + "execute_ms": 0.41999998688697817, + "queue_ms": 0.03999999910593033, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.catgory_id = 1917111404413517825 AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 11:55:25.1236", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "BF7B4069A97B0E4A3A059783C5B8AFC1", + "PLAN_ID": 62242638, + "elapsed_ms": 0.3799999952316284, + "execute_ms": 0.23999999463558198, + "queue_ms": 0.05000000074505806, + "RETURN_ROWS": 0, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT a.id, a.source_mch_id, a.target_mch_id, a.rule_price_config_id, a.status, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.tenant_id, p.id AS rulePirceConfigId, p.rule_price_type, p.base_price, p.multiple, source.name AS sourceMchName, target.name AS targetMchName FROM mc" + }, + { + "req_time": "17/6/2026 11:55:24.8743", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "0634F31AAF585CA78923D241EF91AB7C", + "PLAN_ID": 62235170, + "elapsed_ms": 0.6299999952316284, + "execute_ms": 0.5600000023841858, + "queue_ms": 0.029999999329447748, + "RETURN_ROWS": 2, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "req_time": "17/6/2026 11:55:24.8727", + "TENANT_NAME": "sys", + "DB_NAME": "pjcloudx_wallet", + "USER_NAME": "root", + "IS_INNER_SQL": 0, + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "PLAN_ID": 62235165, + "elapsed_ms": 0.5199999809265137, + "execute_ms": 0.38999998569488528, + "queue_ms": 0.05999999865889549, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "TABLE_SCAN": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = 1905523985427894274 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + } + ] +} +``` + +我有一个本地库和线上库(表、结构、索引一摸一样),线上库数据量特别大,本地库只是测试数据,我用本地支持的mcp连接我的本地测试库再结合线上的慢sql分析来解决问题 diff --git a/database/pjcloudx/pjcloudx-1.json b/database/pjcloudx/pjcloudx-1.json new file mode 100644 index 0000000..0ef1d9e --- /dev/null +++ b/database/pjcloudx/pjcloudx-1.json @@ -0,0 +1,100 @@ +{ + "RECORDS": [ + { + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "exec_cnt": 15, + "total_s": 0.07000000029802323, + "avg_ms": 4.573999881744385, + "max_ms": 4.816999912261963, + "table_scan_cnt": 15.0, + "avg_read_rows": 215.72999572753907, + "avg_return_rows": 1.0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'c8188833a3de43a8b0a14cb776767f83.png')" + }, + { + "DB_NAME": "pjcloudx", + "SQL_ID": "63CD59C8F42DB7204071C6CC97E74B5A", + "exec_cnt": 1, + "total_s": 0.0, + "avg_ms": 0.3630000054836273, + "max_ms": 0.3630000054836273, + "table_scan_cnt": 0.0, + "avg_read_rows": 8.0, + "avg_return_rows": 4.0, + "sample_sql": "SELECT dept_id, name, hard_group_id, sort_order, is_sync_zy, create_by, update_by, create_time, update_time, parent_id, del_flag FROM sys_dept WHERE del_flag = '0' AND (dept_id IN (2006251987291287554, 2005905424064917506, 1985186135934717954, 1942046316044144642)) AND tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx", + "SQL_ID": "50B6A1EF7E1FD417DFC0D240749EA002", + "exec_cnt": 4, + "total_s": 0.0, + "avg_ms": 0.2750000059604645, + "max_ms": 0.3140000104904175, + "table_scan_cnt": 0.0, + "avg_read_rows": 2.0, + "avg_return_rows": 2.0, + "sample_sql": "SELECT user_id, role_id FROM sys_user_role WHERE (user_id = 1937304885073272834)" + }, + { + "DB_NAME": "pjcloudx", + "SQL_ID": "3FECEE9D574596DA8FAFB1A0E895D394", + "exec_cnt": 2, + "total_s": 0.0, + "avg_ms": 0.4449999928474426, + "max_ms": 0.44699999690055849, + "table_scan_cnt": 2.0, + "avg_read_rows": 50.0, + "avg_return_rows": 2.0, + "sample_sql": "SELECT sys_role.role_id, sys_role.role_name, sys_role.role_code, sys_role.role_desc, sys_role.ds_type, sys_role.ds_scope, sys_role.create_time, sys_role.update_time, sys_role.del_flag FROM sys_role, sys_user_role WHERE sys_role.role_id = sys_user_role.role_id AND sys_role.del_flag = '0' AND sys_user" + }, + { + "DB_NAME": "pjcloudx", + "SQL_ID": "35B9C9ED9EBA340450BD60F0ADDE7152", + "exec_cnt": 2, + "total_s": 0.0, + "avg_ms": 0.18700000643730164, + "max_ms": 0.19900000095367433, + "table_scan_cnt": 0.0, + "avg_read_rows": 2.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT dept_id, name, hard_group_id, sort_order, is_sync_zy, create_by, update_by, create_time, update_time, parent_id, del_flag FROM sys_dept WHERE del_flag = '0' AND (dept_id IN (1936980721862926337)) AND tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx", + "SQL_ID": "D474D8CE50EBCC19DC9DF588BECE9913", + "exec_cnt": 4, + "total_s": 0.0, + "avg_ms": 0.25, + "max_ms": 0.27900001406669619, + "table_scan_cnt": 0.0, + "avg_read_rows": 2.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT role_id, role_name, role_code, role_desc, ds_type, ds_scope, create_by, update_by, create_time, update_time, del_flag FROM sys_role WHERE del_flag = '0' AND (role_code = 'MCH_USER') AND tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx", + "SQL_ID": "27E86813C4CABBAC3314E5DC1104AAE7", + "exec_cnt": 1, + "total_s": 0.0, + "avg_ms": 0.17800000309944154, + "max_ms": 0.17800000309944154, + "table_scan_cnt": 0.0, + "avg_read_rows": 2.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT dept_id, name, hard_group_id, sort_order, is_sync_zy, create_by, update_by, create_time, update_time, parent_id, del_flag FROM sys_dept WHERE dept_id = 2006251987291287554 AND del_flag = '0' AND tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx", + "SQL_ID": "4A85444728499802223B6AEBD4A1EB37", + "exec_cnt": 2, + "total_s": 0.0, + "avg_ms": 0.2709999978542328, + "max_ms": 0.2770000100135803, + "table_scan_cnt": 0.0, + "avg_read_rows": 1.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT user_id, process_id, process_status, process_time, username, password, salt, create_by, update_by, create_time, update_time, del_flag, lock_flag, password_expire_flag, password_modify_time, phone, avatar, birthday, dept_id, tenant_id, wx_openid, wx_cp_userid, wx_ding_userid, mini_openid, qq_o" + } + ] +} \ No newline at end of file diff --git a/database/pjcloudx/pjcloudx-2.json b/database/pjcloudx/pjcloudx-2.json new file mode 100644 index 0000000..24d0999 --- /dev/null +++ b/database/pjcloudx/pjcloudx-2.json @@ -0,0 +1,15 @@ +{ + "RECORDS": [ + { + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "exec_cnt": 19, + "avg_ms": 4.576000213623047, + "max_ms": 4.816999912261963, + "total_s": 0.09000000357627869, + "table_scan_cnt": 19.0, + "avg_read_rows": 215.7899932861328, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'f1b9d7ec0b7442a0b947f5a3881e5ce1.png')" + } + ] +} \ No newline at end of file diff --git a/database/pjcloudx/pjcloudx-3.json b/database/pjcloudx/pjcloudx-3.json new file mode 100644 index 0000000..03120b9 --- /dev/null +++ b/database/pjcloudx/pjcloudx-3.json @@ -0,0 +1,44 @@ +{ + "RECORDS": [ + { + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "exec_cnt": 52, + "table_scan_cnt": 52.0, + "table_scan_pct": 100.0, + "avg_ms": 4.507999897003174, + "avg_read_rows": 215.85000610351563, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'f1b9d7ec0b7442a0b947f5a3881e5ce1.png')" + }, + { + "DB_NAME": "pjcloudx", + "SQL_ID": "3FECEE9D574596DA8FAFB1A0E895D394", + "exec_cnt": 3, + "table_scan_cnt": 3.0, + "table_scan_pct": 100.0, + "avg_ms": 0.4399999976158142, + "avg_read_rows": 50.0, + "sample_sql": "SELECT sys_role.role_id, sys_role.role_name, sys_role.role_code, sys_role.role_desc, sys_role.ds_type, sys_role.ds_scope, sys_role.create_time, sys_role.update_time, sys_role.del_flag FROM sys_role, sys_user_role WHERE sys_role.role_id = sys_user_role.role_id AND sys_role.del_flag = '0' AND sys_user" + }, + { + "DB_NAME": "pjcloudx", + "SQL_ID": "465E34B4594DEC3E30AF6C28476E981E", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 0.289000004529953, + "avg_read_rows": 50.0, + "sample_sql": "SELECT sys_role.role_id, sys_role.role_name, sys_role.role_code, sys_role.role_desc, sys_role.ds_type, sys_role.ds_scope, sys_role.create_time, sys_role.update_time, sys_role.del_flag FROM sys_role, sys_user_role WHERE sys_role.role_id = sys_user_role.role_id AND sys_role.del_flag = '0' and sys_user" + }, + { + "DB_NAME": "pjcloudx", + "SQL_ID": "6B09CAD5103AFC619EF36141A1DC9090", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 0.15299999713897706, + "avg_read_rows": 0.0, + "sample_sql": "SELECT p.post_id, p.post_name, p.post_code, p.post_sort, p.del_flag, p.create_time, p.update_time, p.remark FROM sys_post p, sys_user_post up WHERE p.post_id = up.post_id AND p.del_flag = '0' and up.user_id = 1901838838308462594" + } + ] +} \ No newline at end of file diff --git a/database/pjcloudx/pjcloudx-4.json b/database/pjcloudx/pjcloudx-4.json new file mode 100644 index 0000000..7b2a1dd --- /dev/null +++ b/database/pjcloudx/pjcloudx-4.json @@ -0,0 +1,754 @@ +{ + "RECORDS": [ + { + "req_time": "17/6/2026 15:00:12.255", + "DB_NAME": "pjcloudx", + "SQL_ID": "9020C350A356AA86B6270604D422FA7B", + "PLAN_ID": 62259379, + "elapsed_ms": 10.305999755859375, + "execute_ms": 8.163000106811524, + "queue_ms": 0.032999999821186069, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 1, + "SSSTORE_READ_ROW_COUNT": 5018, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, mobile_phone, device_fingerprint, device_name, last_login_time, expire_time, create_by, create_time, update_by, update_time, del_flag FROM user_trusted_device WHERE del_flag = '0' AND (mobile_phone = '15356941188' AND device_fingerprint = '7c213aa407cdefcd4b8177ec7eea1eb7' AND device_name = '诗画设备认证')" + }, + { + "req_time": "17/6/2026 14:59:27.146", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 6.879000186920166, + "execute_ms": 6.758999824523926, + "queue_ms": 0.052000001072883609, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '6eef8fdf64c543cd86eaf6478630c951.jpg')" + }, + { + "req_time": "17/6/2026 14:59:42.3541", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.927999973297119, + "execute_ms": 4.789999961853027, + "queue_ms": 0.05700000002980232, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '0bd9df9ca62e42cbbca1135384e673ef.jpg')" + }, + { + "req_time": "17/6/2026 15:01:07.8415", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.89300012588501, + "execute_ms": 4.763000011444092, + "queue_ms": 0.05400000140070915, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '2ea697d06d484234877f2d4defa83f4a.jpg')" + }, + { + "req_time": "17/6/2026 15:00:13.0572", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.822000026702881, + "execute_ms": 4.679999828338623, + "queue_ms": 0.054999999701976779, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '47162c815795478a9183077511e6a0d2.jpg')" + }, + { + "req_time": "17/6/2026 15:00:03.7312", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.814000129699707, + "execute_ms": 4.677000045776367, + "queue_ms": 0.05700000002980232, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '28f7b734deee42ec8915d93d29c54585.jpg')" + }, + { + "req_time": "17/6/2026 15:00:11.4376", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.796000003814697, + "execute_ms": 4.658999919891357, + "queue_ms": 0.05700000002980232, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '94d303f8719b4f7fbb483e037218b705.png')" + }, + { + "req_time": "17/6/2026 15:00:15.7957", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.789999961853027, + "execute_ms": 4.703000068664551, + "queue_ms": 0.03799999877810478, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 215, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'a04dab3af14841e28e0be2a58fe0813b.png')" + }, + { + "req_time": "17/6/2026 15:00:17.3273", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.776000022888184, + "execute_ms": 4.639999866485596, + "queue_ms": 0.05700000002980232, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '8a9984b841f0471380f37c1a7c977608.jpg')" + }, + { + "req_time": "17/6/2026 15:00:18.7236", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.770999908447266, + "execute_ms": 4.650000095367432, + "queue_ms": 0.054999999701976779, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'f6d94bbc1d68407fae562f77aabe6817.jpg')" + }, + { + "req_time": "17/6/2026 15:00:34.2747", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.769000053405762, + "execute_ms": 4.631999969482422, + "queue_ms": 0.0560000017285347, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'ee66de1bb13a4a84a6f4c970c5c0d906.jpg')" + }, + { + "req_time": "17/6/2026 14:59:27.2351", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.761000156402588, + "execute_ms": 4.626999855041504, + "queue_ms": 0.05400000140070915, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '3b1a7a7c2c644513b406c177e1f65045.jpg')" + }, + { + "req_time": "17/6/2026 15:00:52.4672", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.75600004196167, + "execute_ms": 4.614999771118164, + "queue_ms": 0.05900000035762787, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'fd585a825ffd4a70ab8bdceb63c9bf21.jpg')" + }, + { + "req_time": "17/6/2026 15:00:10.768", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.752999782562256, + "execute_ms": 4.619999885559082, + "queue_ms": 0.05299999937415123, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'ab8823b0abb045a7b9ce7a52d91eea8f.png')" + }, + { + "req_time": "17/6/2026 15:00:38.9958", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.752999782562256, + "execute_ms": 4.63700008392334, + "queue_ms": 0.052000001072883609, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '624e83624f594c539851ce13248fd785.jpg')" + }, + { + "req_time": "17/6/2026 15:00:43.339", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.751999855041504, + "execute_ms": 4.629000186920166, + "queue_ms": 0.05000000074505806, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '909eb25428cf4727ac6a89be4a2e5538.png')" + }, + { + "req_time": "17/6/2026 15:00:42.302", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.751999855041504, + "execute_ms": 4.613999843597412, + "queue_ms": 0.05700000002980232, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '1ad9e60cca724e26b812d695c43a0254.png')" + }, + { + "req_time": "17/6/2026 14:59:28.8479", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.744999885559082, + "execute_ms": 4.639999866485596, + "queue_ms": 0.024000000208616258, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '5220af385d464973a78f1df669f144ca.jpg')" + }, + { + "req_time": "17/6/2026 15:00:30.4162", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.742000102996826, + "execute_ms": 4.632999897003174, + "queue_ms": 0.03400000184774399, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '4b0f666dc39c444fbdf4668e41dce0d7.png')" + }, + { + "req_time": "17/6/2026 14:59:27.0728", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.742000102996826, + "execute_ms": 4.611000061035156, + "queue_ms": 0.05299999937415123, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '2dd54705a9b94e33a380ab47f849fd0f.png')" + }, + { + "req_time": "17/6/2026 14:59:33.4752", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.742000102996826, + "execute_ms": 4.614999771118164, + "queue_ms": 0.05400000140070915, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'ad80f87294d244e7ba4ed85e4fd60ea3.png')" + }, + { + "req_time": "17/6/2026 15:00:37.5447", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.735000133514404, + "execute_ms": 4.603000164031982, + "queue_ms": 0.0560000017285347, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '7a1e418b1f2b48389a1b0725bd75b51f.png')" + }, + { + "req_time": "17/6/2026 15:00:23.7274", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.732999801635742, + "execute_ms": 4.622000217437744, + "queue_ms": 0.04800000041723251, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '47a92ef7e20d433290cf44b57fa6be36.jpg')" + }, + { + "req_time": "17/6/2026 15:00:03.0112", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.73199987411499, + "execute_ms": 4.611000061035156, + "queue_ms": 0.04500000178813934, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'fc32b806e0bc4aa5865dead65ac302ce.png')" + }, + { + "req_time": "17/6/2026 15:00:06.2466", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.73199987411499, + "execute_ms": 4.624000072479248, + "queue_ms": 0.03700000047683716, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 215, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '48a1ae3ea4294532a48ad55d169e3c9f.png')" + }, + { + "req_time": "17/6/2026 14:59:42.2806", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.730999946594238, + "execute_ms": 4.589000225067139, + "queue_ms": 0.06300000101327896, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '9601f22f3170460da0846362e99a705c.png')" + }, + { + "req_time": "17/6/2026 15:00:28.9947", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.730000019073486, + "execute_ms": 4.599999904632568, + "queue_ms": 0.054999999701976779, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '144e49bc218a4e4ba2cd11dcc770858f.png')" + }, + { + "req_time": "17/6/2026 15:00:29.8156", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.72599983215332, + "execute_ms": 4.61299991607666, + "queue_ms": 0.04399999976158142, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'ce5b6257d8bb4215870d2c6232458311.jpg')" + }, + { + "req_time": "17/6/2026 15:00:11.3602", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.72599983215332, + "execute_ms": 4.603000164031982, + "queue_ms": 0.05000000074505806, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'b84c0f0e95f24dc7940bce10db479f15.png')" + }, + { + "req_time": "17/6/2026 14:59:51.7005", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.7230000495910648, + "execute_ms": 4.6020002365112309, + "queue_ms": 0.052000001072883609, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '34459628eeb9424aba8a96f0d56d2a16.jpg')" + }, + { + "req_time": "17/6/2026 15:00:03.4352", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.7210001945495609, + "execute_ms": 4.616000175476074, + "queue_ms": 0.03700000047683716, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'e73fd597b9bd4d4d98935c2af8891ac3.png')" + }, + { + "req_time": "17/6/2026 15:00:29.0798", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.7210001945495609, + "execute_ms": 4.605000019073486, + "queue_ms": 0.04899999871850014, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '6006e634bc9946e1acf38051a9608481.jpg')" + }, + { + "req_time": "17/6/2026 15:01:01.569", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.71999979019165, + "execute_ms": 4.585000038146973, + "queue_ms": 0.05400000140070915, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'c3b1ab8476964a868cc02d5c6c1f4d5b.jpg')" + }, + { + "req_time": "17/6/2026 15:00:22.7372", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.716000080108643, + "execute_ms": 4.605999946594238, + "queue_ms": 0.04800000041723251, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'ac6f1bf36b964739b07403749044d209.jpg')" + }, + { + "req_time": "17/6/2026 15:00:43.6088", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.710000038146973, + "execute_ms": 4.642000198364258, + "queue_ms": 0.027000000700354577, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '47162c815795478a9183077511e6a0d2.jpg')" + }, + { + "req_time": "17/6/2026 15:00:36.8513", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.709000110626221, + "execute_ms": 4.605000019073486, + "queue_ms": 0.03500000014901161, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'ef1529d6e654454e9d560f27589ad2a5.png')" + }, + { + "req_time": "17/6/2026 14:59:28.7301", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.709000110626221, + "execute_ms": 4.571000099182129, + "queue_ms": 0.05900000035762787, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'f4a793fa66274b7285edede1e59086c4.jpg')" + }, + { + "req_time": "17/6/2026 15:01:01.6947", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.706999778747559, + "execute_ms": 4.571000099182129, + "queue_ms": 0.05700000002980232, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'bbaf430eb0804456a2a466dffafecc48.jpg')" + }, + { + "req_time": "17/6/2026 15:00:36.7183", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.704999923706055, + "execute_ms": 4.574999809265137, + "queue_ms": 0.0560000017285347, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '3d68afdd24d146698d01fb11ac41668b.jpg')" + }, + { + "req_time": "17/6/2026 15:00:42.1014", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.701000213623047, + "execute_ms": 4.589000225067139, + "queue_ms": 0.0430000014603138, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'cd97b8ef9ca94479bd2f638f8b4fd5d9.jpg')" + }, + { + "req_time": "17/6/2026 15:00:24.5931", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.699999809265137, + "execute_ms": 4.605000019073486, + "queue_ms": 0.03799999877810478, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'be1a577678064d918d517710dfc127a2.png')" + }, + { + "req_time": "17/6/2026 15:00:52.209", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.699999809265137, + "execute_ms": 4.570000171661377, + "queue_ms": 0.050999999046325687, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'cecbdb04b1994ff79d2f18da4d07dd45.jpg')" + }, + { + "req_time": "17/6/2026 14:59:57.3358", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.698999881744385, + "execute_ms": 4.572000026702881, + "queue_ms": 0.05299999937415123, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '27cae2f5200f4c9da02ad2aa0b7065c8.jpg')" + }, + { + "req_time": "17/6/2026 15:00:37.3828", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.696000099182129, + "execute_ms": 4.559999942779541, + "queue_ms": 0.05700000002980232, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '3d68afdd24d146698d01fb11ac41668b.jpg')" + }, + { + "req_time": "17/6/2026 14:59:40.9461", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.689000129699707, + "execute_ms": 4.554999828338623, + "queue_ms": 0.04800000041723251, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'c5daf4081546402d8287e52fef29bc17.jpg')" + }, + { + "req_time": "17/6/2026 15:01:07.4745", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.689000129699707, + "execute_ms": 4.548999786376953, + "queue_ms": 0.06199999898672104, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '222b24e79b3d437f8f33decca2f98628.jpg')" + }, + { + "req_time": "17/6/2026 15:01:01.314", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.688000202178955, + "execute_ms": 4.553999900817871, + "queue_ms": 0.0560000017285347, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '1c4f4c71d72d4099963b8b72f07e921e.jpg')" + }, + { + "req_time": "17/6/2026 15:00:03.3043", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.685999870300293, + "execute_ms": 4.566999912261963, + "queue_ms": 0.04399999976158142, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'fc32b806e0bc4aa5865dead65ac302ce.png')" + }, + { + "req_time": "17/6/2026 14:59:28.0077", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.685999870300293, + "execute_ms": 4.567999839782715, + "queue_ms": 0.04100000113248825, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = '3d68afdd24d146698d01fb11ac41668b.jpg')" + }, + { + "req_time": "17/6/2026 15:00:35.1576", + "DB_NAME": "pjcloudx", + "SQL_ID": "E8CA1985E10C9B4DF67725254BCE8BAF", + "PLAN_ID": 62257749, + "elapsed_ms": 4.685999870300293, + "execute_ms": 4.558000087738037, + "queue_ms": 0.05299999937415123, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 216, + "RETURN_ROWS": 1, + "AFFECTED_ROWS": 0, + "sample_sql": "SELECT id, file_name, original, bucket_name, dir, type, group_id, file_size, hash, create_by, create_time, update_by, update_time, del_flag FROM sys_file WHERE del_flag = '0' AND (file_name = 'f0ae3f3012724de3a53231d9e393ab8d.jpg')" + } + ] +} \ No newline at end of file diff --git a/database/pjcloudx/sql-execute-map.js b/database/pjcloudx/sql-execute-map.js new file mode 100644 index 0000000..e5b0843 --- /dev/null +++ b/database/pjcloudx/sql-execute-map.js @@ -0,0 +1,97 @@ +const map = [ + { + executeSql: ` + SELECT + DB_NAME, + SQL_ID, + COUNT(*) AS exec_cnt, + ROUND(SUM(ELAPSED_TIME) / 1000000, 2) AS total_s, + ROUND(AVG(ELAPSED_TIME) / 1000, 3) AS avg_ms, + ROUND(MAX(ELAPSED_TIME) / 1000, 3) AS max_ms, + SUM(CASE WHEN TABLE_SCAN = 1 THEN 1 ELSE 0 END) AS table_scan_cnt, + ROUND(AVG(MEMSTORE_READ_ROW_COUNT + SSSTORE_READ_ROW_COUNT), 2) AS avg_read_rows, + ROUND(AVG(RETURN_ROWS), 2) AS avg_return_rows, + MAX(LEFT(REPLACE(QUERY_SQL, '\n', ' '), 300)) AS sample_sql +FROM oceanbase.GV$OB_SQL_AUDIT +WHERE REQUEST_TIME >= UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 HOUR)) * 1000000 + AND DB_NAME = 'pjcloudx' + AND IS_INNER_SQL = 0 + AND QUERY_SQL NOT IN ('SET autocommit=1', 'SET autocommit=0', 'commit', 'SELECT @@session.transaction_read_only') +GROUP BY DB_NAME, SQL_ID +ORDER BY total_s DESC +LIMIT 30;`, + resultJsonPath: './pjcloudx-1.json' + }, + { + executeSql: ` + SELECT + DB_NAME, + SQL_ID, + COUNT(*) AS exec_cnt, + ROUND(AVG(ELAPSED_TIME) / 1000, 3) AS avg_ms, + ROUND(MAX(ELAPSED_TIME) / 1000, 3) AS max_ms, + ROUND(SUM(ELAPSED_TIME) / 1000000, 2) AS total_s, + SUM(CASE WHEN TABLE_SCAN = 1 THEN 1 ELSE 0 END) AS table_scan_cnt, + ROUND(AVG(MEMSTORE_READ_ROW_COUNT + SSSTORE_READ_ROW_COUNT), 2) AS avg_read_rows, + MAX(LEFT(REPLACE(QUERY_SQL, '\n', ' '), 300)) AS sample_sql +FROM oceanbase.GV$OB_SQL_AUDIT +WHERE REQUEST_TIME >= UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 HOUR)) * 1000000 + AND DB_NAME = 'pjcloudx' + AND IS_INNER_SQL = 0 + AND QUERY_SQL NOT IN ('SET autocommit=1', 'SET autocommit=0', 'commit', 'SELECT @@session.transaction_read_only') +GROUP BY DB_NAME, SQL_ID +HAVING COUNT(*) >= 5 +ORDER BY avg_ms DESC +LIMIT 30; + `, + resultJsonPath: './pjcloudx-2.json' + }, + { + executeSql: ` + SELECT + DB_NAME, + SQL_ID, + COUNT(*) AS exec_cnt, + SUM(CASE WHEN TABLE_SCAN = 1 THEN 1 ELSE 0 END) AS table_scan_cnt, + ROUND(SUM(CASE WHEN TABLE_SCAN = 1 THEN 1 ELSE 0 END) / COUNT(*) * 100, 2) AS table_scan_pct, + ROUND(AVG(ELAPSED_TIME) / 1000, 3) AS avg_ms, + ROUND(AVG(MEMSTORE_READ_ROW_COUNT + SSSTORE_READ_ROW_COUNT), 2) AS avg_read_rows, + MAX(LEFT(REPLACE(QUERY_SQL, '\n', ' '), 300)) AS sample_sql +FROM oceanbase.GV$OB_SQL_AUDIT +WHERE REQUEST_TIME >= UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 HOUR)) * 1000000 + AND DB_NAME = 'pjcloudx' + AND IS_INNER_SQL = 0 + AND QUERY_SQL NOT IN ('SET autocommit=1', 'SET autocommit=0', 'commit', 'SELECT @@session.transaction_read_only') +GROUP BY DB_NAME, SQL_ID +HAVING table_scan_cnt > 0 +ORDER BY table_scan_cnt DESC, avg_ms DESC +LIMIT 30; + `, + resultJsonPath: './pjcloudx-3.json' + }, + { + executeSql: ` +SELECT + FROM_UNIXTIME(REQUEST_TIME / 1000000) AS req_time, + DB_NAME, + SQL_ID, + PLAN_ID, + ROUND(ELAPSED_TIME / 1000, 3) AS elapsed_ms, + ROUND(EXECUTE_TIME / 1000, 3) AS execute_ms, + ROUND(QUEUE_TIME / 1000, 3) AS queue_ms, + TABLE_SCAN, + MEMSTORE_READ_ROW_COUNT, + SSSTORE_READ_ROW_COUNT, + RETURN_ROWS, + AFFECTED_ROWS, + LEFT(REPLACE(QUERY_SQL, '\n', ' '), 500) AS sample_sql +FROM oceanbase.GV$OB_SQL_AUDIT +WHERE REQUEST_TIME >= UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 HOUR)) * 1000000 + AND DB_NAME = 'pjcloudx' + AND IS_INNER_SQL = 0 +ORDER BY ELAPSED_TIME DESC +LIMIT 50; + `, + resultJsonPath: './pjcloudx-4.json' + } +] \ No newline at end of file diff --git a/database/result-1-v1.json b/database/result-1-v1.json new file mode 100644 index 0000000..3193865 --- /dev/null +++ b/database/result-1-v1.json @@ -0,0 +1,364 @@ +{ + "RECORDS": [ + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "746EDD1C7EE905B0CA06DFAA320C7664", + "exec_cnt": 19, + "total_s": 1.0800000429153443, + "avg_ms": 57.02299880981445, + "max_ms": 63.88100051879883, + "table_scan_cnt": 19.0, + "avg_read_rows": 38263.421875, + "avg_return_rows": 10.0, + "sample_sql": "SELECT t.id, t.order_no, t.user_id, t.user_dept_id, t.merchant_id, t.merchant_type, t.merchant_dept_id, t.hard_id, t.dept_id, t.wallet_id, t.parent_car_id, t.order_source_type_id, t.order_type, t.order_status, t.pay_type, t.hour_type, t.appt_id, t.sys_type, t.total_price, t.extra_price, t.pay_price," + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "A9B65884654FD2500EC6A00E7AEFBD5B", + "exec_cnt": 19, + "total_s": 0.46000000834465029, + "avg_ms": 24.048999786376954, + "max_ms": 28.43199920654297, + "table_scan_cnt": 0.0, + "avg_read_rows": 1818.3699951171876, + "avg_return_rows": 1.0, + "sample_sql": "SELECT COUNT(*) AS total FROM hard_order t WHERE t.del_flag = '0' AND (t.user_id = 2004364201588109313 AND t.merchant_type IN ('2', '3')) AND t.tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "E35B8801C67C012BE090D08557908766", + "exec_cnt": 5, + "total_s": 0.07000000029802323, + "avg_ms": 13.244999885559082, + "max_ms": 13.418999671936036, + "table_scan_cnt": 5.0, + "avg_read_rows": 1820.4000244140626, + "avg_return_rows": 1.399999976158142, + "sample_sql": "SELECT id, parent_car_id, product_id, product_name, product_pic, product_price, product_nature, product_count, product_weight, is_discounts_product, total_price, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM hard_car WHERE del_flag = '0' AND (parent_car_id = 20670967317598" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "143118826A7689F1962567CAFC307513", + "exec_cnt": 1, + "total_s": 0.029999999329447748, + "avg_ms": 33.44499969482422, + "max_ms": 33.44499969482422, + "table_scan_cnt": 1.0, + "avg_read_rows": 890.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT * FROM (SELECT a.merchant_id, a.user_dept_id, a.merchant_dept_id, sum(a.pay_price) AS totalPayPrice, count(0) AS totalPayCount FROM hard_order a WHERE a.del_flag = '0' AND a.user_dept_id NOT IN (1875013738914156546, 1910218102049226753, 1910218128624336898, 1942046316044144642) AND a.order_st" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "A577C7372963DC99F31CA516DEBBD5CA", + "exec_cnt": 34, + "total_s": 0.019999999552965165, + "avg_ms": 0.5299999713897705, + "max_ms": 0.6430000066757202, + "table_scan_cnt": 34.0, + "avg_read_rows": 94.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.catgory_id = 2006254423101825025 AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "0634F31AAF585CA78923D241EF91AB7C", + "exec_cnt": 20, + "total_s": 0.019999999552965165, + "avg_ms": 0.9089999794960022, + "max_ms": 1.11899995803833, + "table_scan_cnt": 20.0, + "avg_read_rows": 266.45001220703127, + "avg_return_rows": 8.850000381469727, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "3CC4E4211ACF2F21F80D12F01085EBA7", + "exec_cnt": 1, + "total_s": 0.019999999552965165, + "avg_ms": 24.60700035095215, + "max_ms": 24.60700035095215, + "table_scan_cnt": 1.0, + "avg_read_rows": 1195.0, + "avg_return_rows": 10.0, + "sample_sql": "SELECT t.id, t.order_no, t.user_id, t.user_dept_id, t.merchant_id, t.merchant_type, t.merchant_dept_id, t.hard_id, t.dept_id, t.wallet_id, t.parent_car_id, t.order_source_type_id, t.order_type, t.order_status, t.pay_type, t.hour_type, t.appt_id, t.sys_type, t.total_price, t.extra_price, t.pay_price," + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "F3B83B175E6A8D1E9AEA3FC1C39D36C4", + "exec_cnt": 25, + "total_s": 0.009999999776482582, + "avg_ms": 0.29100000858306887, + "max_ms": 0.35499998927116396, + "table_scan_cnt": 0.0, + "avg_read_rows": 2.8399999141693117, + "avg_return_rows": 1.0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "407345B8B4FD51DD2B212C918799AABA", + "exec_cnt": 16, + "total_s": 0.009999999776482582, + "avg_ms": 0.878000020980835, + "max_ms": 1.0640000104904175, + "table_scan_cnt": 16.0, + "avg_read_rows": 164.94000244140626, + "avg_return_rows": 9.1899995803833, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "19940A1F06A778590A24A42D49C06923", + "exec_cnt": 9, + "total_s": 0.009999999776482582, + "avg_ms": 1.2589999437332154, + "max_ms": 6.591000080108643, + "table_scan_cnt": 9.0, + "avg_read_rows": 147.3300018310547, + "avg_return_rows": 1.0, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND t.name LIKE '%生鲜%' AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "3C48D5479F5FDC1112C5A04C32BE8DC2", + "exec_cnt": 1, + "total_s": 0.009999999776482582, + "avg_ms": 11.984000205993653, + "max_ms": 11.984000205993653, + "table_scan_cnt": 1.0, + "avg_read_rows": 760.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT COUNT(*) AS total FROM hard_order t WHERE t.del_flag = '0' AND (t.merchant_id IN (1948276446768889857)) AND t.tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "80BCBC95727FBE6464312DE02CF9E196", + "exec_cnt": 1, + "total_s": 0.009999999776482582, + "avg_ms": 5.068999767303467, + "max_ms": 5.068999767303467, + "table_scan_cnt": 1.0, + "avg_read_rows": 93.0, + "avg_return_rows": 0.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "64C62234D71CD0810A7719CDEB6F8F72", + "exec_cnt": 1, + "total_s": 0.009999999776482582, + "avg_ms": 5.236999988555908, + "max_ms": 5.236999988555908, + "table_scan_cnt": 1.0, + "avg_read_rows": 425.0, + "avg_return_rows": 381.0, + "sample_sql": "SELECT id, parent_id, dept_id, default_wallet_type_id, name, types, canteen_is_open, catgory_id, logo_pic, collection_code, collection_url_code, swiper_pic, phone, job_time, address_des, visible_mobile, is_sync_zy, sort, sup_type, discounts_price, cooperation_status, mch_count, create_by, create_tim" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "2C4AE8DCC737A2806BB612A4891D7A3D", + "exec_cnt": 17, + "total_s": 0.009999999776482582, + "avg_ms": 0.734000027179718, + "max_ms": 0.8679999709129334, + "table_scan_cnt": 17.0, + "avg_read_rows": 130.24000549316407, + "avg_return_rows": 8.880000114440918, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "5985A04701EA41E12546B3B563F231D2", + "exec_cnt": 2, + "total_s": 0.009999999776482582, + "avg_ms": 2.693000078201294, + "max_ms": 4.535999774932861, + "table_scan_cnt": 2.0, + "avg_read_rows": 111.0, + "avg_return_rows": 9.0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "5AA210099A17AD66BC52F5DFF4793ACA", + "exec_cnt": 7, + "total_s": 0.009999999776482582, + "avg_ms": 1.253999948501587, + "max_ms": 4.396999835968018, + "table_scan_cnt": 7.0, + "avg_read_rows": 100.56999969482422, + "avg_return_rows": 5.289999961853027, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "ECE7F270F89DE683F6E1B8980F8340E5", + "exec_cnt": 3, + "total_s": 0.009999999776482582, + "avg_ms": 1.690999984741211, + "max_ms": 4.368000030517578, + "table_scan_cnt": 3.0, + "avg_read_rows": 16.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "exec_cnt": 26, + "total_s": 0.009999999776482582, + "avg_ms": 0.5690000057220459, + "max_ms": 0.6729999780654907, + "table_scan_cnt": 26.0, + "avg_read_rows": 93.95999908447266, + "avg_return_rows": 1.0, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('3', types)) AND t.tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "153470DCBE2144612BC19937A758575F", + "exec_cnt": 6, + "total_s": 0.009999999776482582, + "avg_ms": 2.322999954223633, + "max_ms": 8.005000114440918, + "table_scan_cnt": 6.0, + "avg_read_rows": 389.0, + "avg_return_rows": 10.0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "DBB3F758E483F87C27ECFE73C3980216", + "exec_cnt": 34, + "total_s": 0.009999999776482582, + "avg_ms": 0.20200000703334809, + "max_ms": 0.24899999797344209, + "table_scan_cnt": 34.0, + "avg_read_rows": 5.0, + "avg_return_rows": 3.0, + "sample_sql": "SELECT id, name, icon, unique_code, is_rule, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_type WHERE del_flag = '0' AND tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "30E53CB2C758ED3B74795ECA38F6FA74", + "exec_cnt": 14, + "total_s": 0.009999999776482582, + "avg_ms": 0.42899999022483828, + "max_ms": 0.5170000195503235, + "table_scan_cnt": 0.0, + "avg_read_rows": 6.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT COUNT(*) AS total FROM wallet_manage WHERE del_flag = '0' AND (user_id = 1965333932604592130) AND tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "248A89F582F293AACB249474EFB5B8DB", + "exec_cnt": 4, + "total_s": 0.009999999776482582, + "avg_ms": 1.5609999895095826, + "max_ms": 3.7079999446868898, + "table_scan_cnt": 4.0, + "avg_read_rows": 34.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT id, user_id, user_type, biz_type, hard_id, hard_door_id, cabinet_no, order_id, auth_id, request_open_dto, request_open_vo, request_open_time, is_open, open_callback_time, open_callback_vo, video_callback_vo, video_callback_time, sku_submit_dto, sku_submit_vo, sku_submit_recog_id, sku_submit_t" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "01497E868223ADCCA4125A32F66797C5", + "exec_cnt": 1, + "total_s": 0.009999999776482582, + "avg_ms": 14.119999885559082, + "max_ms": 14.119999885559082, + "table_scan_cnt": 0.0, + "avg_read_rows": 1790.0, + "avg_return_rows": 0.0, + "sample_sql": "SELECT * FROM (SELECT a.merchant_id, a.user_dept_id, a.merchant_dept_id, sum(ifnull(r.refund_price, 0)) AS totalPayPrice, count(0) AS totalPayCount FROM hard_after_sale r INNER JOIN hard_order a ON a.id = r.order_id AND r.del_flag = '0' AND r.tenant_id = 1 AND a.tenant_id = 1 WHERE a.del_flag = '0' " + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "686DEAF4C5940FB6442B34F0C4B640AD", + "exec_cnt": 1, + "total_s": 0.009999999776482582, + "avg_ms": 9.003000259399414, + "max_ms": 9.003000259399414, + "table_scan_cnt": 1.0, + "avg_read_rows": 710.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT id, spu_category_id, name, cover, pic, price, sales_count, repertory_count, sort, status, is_default, specs_taste, specs_capacity, specs_weight, sku_type, ks_sku_id, ks_res_sku_id, ks_barcode, ks_has_sub_sku, ks_sub_sku_json, ks_status, ks_status_title, version, ks_comments, create_by, create" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "2A2D3A4640A31D4959FAB965FEADD481", + "exec_cnt": 1, + "total_s": 0.0, + "avg_ms": 0.6430000066757202, + "max_ms": 0.6430000066757202, + "table_scan_cnt": 1.0, + "avg_read_rows": 34.0, + "avg_return_rows": 7.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "942F44BEFB2624E6F3B1CF8D9D05BD2A", + "exec_cnt": 4, + "total_s": 0.0, + "avg_ms": 0.2590000033378601, + "max_ms": 0.27300000190734866, + "table_scan_cnt": 0.0, + "avg_read_rows": 1.0, + "avg_return_rows": 1.0, + "sample_sql": "SELECT id, hard_group_id, merchant_id, dept_id, name, type, mq_client_id, unique_code, main_topic, mq_socket_address, mq_socket_port, mq_username, mq_password, is_take_food, face_app_id, face_sdk_key, face_active_key, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM hard_mana" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "50782362421566F1A491229D93FE1436", + "exec_cnt": 1, + "total_s": 0.0, + "avg_ms": 3.4579999446868898, + "max_ms": 3.4579999446868898, + "table_scan_cnt": 0.0, + "avg_read_rows": 20.0, + "avg_return_rows": 10.0, + "sample_sql": "SELECT id, user_id, wallet_type_id, dept_id, card_number, balance, total_expense, total_recharge, freeze_price, is_freeze, active_bind_time, status, version, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_manage WHERE del_flag = '0' AND (id IN (2003307338708738049, 1" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "80EFF074740855D524A66272D79347EA", + "exec_cnt": 11, + "total_s": 0.0, + "avg_ms": 0.2590000033378601, + "max_ms": 0.30799999833106997, + "table_scan_cnt": 0.0, + "avg_read_rows": 2.0, + "avg_return_rows": 0.0, + "sample_sql": "UPDATE hard_order SET order_status = '5', pay_price = 7400, pay_time = '2026-06-17 12:07:31.082389', update_by = 'df17613167133', update_time = '2026-06-17 12:07:31.082535' WHERE id = 2067096776892731394 AND del_flag = '0' AND tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "6F2FC049FEF085B688506AEFFC440480", + "exec_cnt": 11, + "total_s": 0.0, + "avg_ms": 0.2800000011920929, + "max_ms": 0.3479999899864197, + "table_scan_cnt": 0.0, + "avg_read_rows": 0.0, + "avg_return_rows": 0.0, + "sample_sql": "INSERT INTO wallet_transaction (id, user_id, dept_id, wallet_id, biz_type, biz_id, title, price, balance, version, create_by, create_time, update_by, update_time, del_flag, tenant_id) VALUES (2067097153574793218, 1883359996002578434, 1883359809645457409, 1883359996132622338, '4', '206709715354123059" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "81C0BF564B80EB8D95217E765FAEC448", + "exec_cnt": 10, + "total_s": 0.0, + "avg_ms": 0.34599998593330386, + "max_ms": 0.39800000190734866, + "table_scan_cnt": 0.0, + "avg_read_rows": 0.0, + "avg_return_rows": 0.0, + "sample_sql": "INSERT INTO hard_order (id, user_id, user_dept_id, merchant_id, merchant_type, merchant_dept_id, wallet_id, order_type, order_status, pay_type, sys_type, total_price, extra_price, pay_price, is_offline_order, product_desc, create_by, create_time, update_by, update_time, del_flag, tenant_id) VALUES (" + } + ] +} \ No newline at end of file diff --git a/database/result-2-v1.json b/database/result-2-v1.json new file mode 100644 index 0000000..a89ff15 --- /dev/null +++ b/database/result-2-v1.json @@ -0,0 +1,70 @@ +{ + "RECORDS": [ + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "746EDD1C7EE905B0CA06DFAA320C7664", + "exec_cnt": 12, + "avg_ms": 61.494998931884769, + "max_ms": 64.072998046875, + "total_s": 0.7400000095367432, + "table_scan_cnt": 12.0, + "avg_read_rows": 45379.578125, + "sample_sql": "SELECT t.id, t.order_no, t.user_id, t.user_dept_id, t.merchant_id, t.merchant_type, t.merchant_dept_id, t.hard_id, t.dept_id, t.wallet_id, t.parent_car_id, t.order_source_type_id, t.order_type, t.order_status, t.pay_type, t.hour_type, t.appt_id, t.sys_type, t.total_price, t.extra_price, t.pay_price," + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "A9B65884654FD2500EC6A00E7AEFBD5B", + "exec_cnt": 12, + "avg_ms": 25.888999938964845, + "max_ms": 27.5049991607666, + "total_s": 0.3100000023841858, + "table_scan_cnt": 0.0, + "avg_read_rows": 2635.580078125, + "sample_sql": "SELECT COUNT(*) AS total FROM hard_order t WHERE t.del_flag = '0' AND (t.user_id = 1925715757013626882 AND t.merchant_type IN ('2', '3')) AND t.tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "4866A59C644AC806C8C8766566CB0057", + "exec_cnt": 7, + "avg_ms": 0.49900001287460329, + "max_ms": 0.5929999947547913, + "total_s": 0.0, + "table_scan_cnt": 7.0, + "avg_read_rows": 22.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "F3B83B175E6A8D1E9AEA3FC1C39D36C4", + "exec_cnt": 6, + "avg_ms": 0.2800000011920929, + "max_ms": 0.3449999988079071, + "total_s": 0.0, + "table_scan_cnt": 0.0, + "avg_read_rows": 2.3299999237060549, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "68C65430C5582C8802BE94318CAECE23", + "exec_cnt": 12, + "avg_ms": 0.2280000001192093, + "max_ms": 0.2919999957084656, + "total_s": 0.0, + "table_scan_cnt": 0.0, + "avg_read_rows": 2.0, + "sample_sql": "SELECT id, user_id, wallet_type_id, dept_id, card_number, balance, total_expense, total_recharge, freeze_price, is_freeze, active_bind_time, status, version, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_manage WHERE del_flag = '0' AND (id IN (1925717710934327298)) " + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "DBB3F758E483F87C27ECFE73C3980216", + "exec_cnt": 15, + "avg_ms": 0.19599999487400056, + "max_ms": 0.24899999797344209, + "total_s": 0.0, + "table_scan_cnt": 15.0, + "avg_read_rows": 5.0, + "sample_sql": "SELECT id, name, icon, unique_code, is_rule, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_type WHERE del_flag = '0' AND tenant_id = 1" + } + ] +} \ No newline at end of file diff --git a/database/result-3-v1.json b/database/result-3-v1.json new file mode 100644 index 0000000..8fed551 --- /dev/null +++ b/database/result-3-v1.json @@ -0,0 +1,294 @@ +{ + "RECORDS": [ + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "DBB3F758E483F87C27ECFE73C3980216", + "exec_cnt": 43, + "table_scan_cnt": 43.0, + "table_scan_pct": 100.0, + "avg_ms": 0.2029999941587448, + "avg_read_rows": 5.0, + "sample_sql": "SELECT id, name, icon, unique_code, is_rule, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_type WHERE del_flag = '0' AND tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "746EDD1C7EE905B0CA06DFAA320C7664", + "exec_cnt": 26, + "table_scan_cnt": 26.0, + "table_scan_pct": 100.0, + "avg_ms": 59.78900146484375, + "avg_read_rows": 42863.8515625, + "sample_sql": "SELECT t.id, t.order_no, t.user_id, t.user_dept_id, t.merchant_id, t.merchant_type, t.merchant_dept_id, t.hard_id, t.dept_id, t.wallet_id, t.parent_car_id, t.order_source_type_id, t.order_type, t.order_status, t.pay_type, t.hour_type, t.appt_id, t.sys_type, t.total_price, t.extra_price, t.pay_price," + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "0634F31AAF585CA78923D241EF91AB7C", + "exec_cnt": 15, + "table_scan_cnt": 15.0, + "table_scan_pct": 100.0, + "avg_ms": 0.8930000066757202, + "avg_read_rows": 238.3300018310547, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "exec_cnt": 15, + "table_scan_cnt": 15.0, + "table_scan_pct": 100.0, + "avg_ms": 0.5600000023841858, + "avg_read_rows": 94.0, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('3', types)) AND t.tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "4866A59C644AC806C8C8766566CB0057", + "exec_cnt": 15, + "table_scan_cnt": 15.0, + "table_scan_pct": 100.0, + "avg_ms": 0.49399998784065249, + "avg_read_rows": 22.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "456BC8375C4B7B6E222B78BADB7922FD", + "exec_cnt": 11, + "table_scan_cnt": 11.0, + "table_scan_pct": 100.0, + "avg_ms": 0.3019999861717224, + "avg_read_rows": 5.0, + "sample_sql": "SELECT a.id, a.coupon_id, a.user_id, a.user_name, a.coupon_code, a.status, a.coupon_name, a.coupon_type, a.face_value, a.min_point, a.start_time, a.end_time, a.use_time, a.order_id, a.use_amount, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.tenant_id FROM act_coupon_record a" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "E99DBD2BC95F860A5F3962DCAA8ADC45", + "exec_cnt": 10, + "table_scan_cnt": 10.0, + "table_scan_pct": 100.0, + "avg_ms": 0.3540000021457672, + "avg_read_rows": 7.0, + "sample_sql": "SELECT t.id, t.user_id, t.wallet_type_id, t.dept_id, t.card_number, t.balance, t.total_expense, t.total_recharge, t.freeze_price, t.is_freeze, t.active_bind_time, t.status, t.version, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id, t1.name AS walletTypeName, t1.uniqu" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "52717C90AF3126884CFCBD8313F107FF", + "exec_cnt": 10, + "table_scan_cnt": 10.0, + "table_scan_pct": 100.0, + "avg_ms": 0.34299999475479128, + "avg_read_rows": 64.0, + "sample_sql": "SELECT id, hard_group_id, merchant_id, dept_id, name, type, mq_client_id, unique_code, main_topic, mq_socket_address, mq_socket_port, mq_username, mq_password, is_take_food, face_app_id, face_sdk_key, face_active_key, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM hard_mana" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "70B3680CB005E4D795980EC7A9702F7F", + "exec_cnt": 10, + "table_scan_cnt": 10.0, + "table_scan_pct": 100.0, + "avg_ms": 0.2770000100135803, + "avg_read_rows": 13.0, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_catgory WHERE del_flag = '0' AND tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "18F76F7803AFE2016DB17EE86B1DE45F", + "exec_cnt": 10, + "table_scan_cnt": 10.0, + "table_scan_pct": 100.0, + "avg_ms": 0.24400000274181367, + "avg_read_rows": 13.0, + "sample_sql": "SELECT id, name, biz_type, sort, remark, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM mch_catgory WHERE del_flag = '0' AND tenant_id = 1 ORDER BY sort DESC, create_time DESC, id DESC LIMIT 1000" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "30426DCA72DAD943F19F2DB4C5320E5F", + "exec_cnt": 4, + "table_scan_cnt": 4.0, + "table_scan_pct": 100.0, + "avg_ms": 1.6770000457763672, + "avg_read_rows": 37.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "19940A1F06A778590A24A42D49C06923", + "exec_cnt": 4, + "table_scan_cnt": 4.0, + "table_scan_pct": 100.0, + "avg_ms": 1.184000015258789, + "avg_read_rows": 93.75, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND t.name LIKE '%鲜果%' AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "29153609C028E623D68990B307C24E35", + "exec_cnt": 3, + "table_scan_cnt": 3.0, + "table_scan_pct": 100.0, + "avg_ms": 0.49000000953674319, + "avg_read_rows": 25.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "5AA210099A17AD66BC52F5DFF4793ACA", + "exec_cnt": 2, + "table_scan_cnt": 2.0, + "table_scan_pct": 100.0, + "avg_ms": 2.502000093460083, + "avg_read_rows": 100.5, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "500EBBC4AD2D544F09B3D70E9C486278", + "exec_cnt": 2, + "table_scan_cnt": 2.0, + "table_scan_pct": 100.0, + "avg_ms": 0.5139999985694885, + "avg_read_rows": 31.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "2201B599823F872A8DF55592695A9488", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 799.3090209960938, + "avg_read_rows": 967093.0, + "sample_sql": "SELECT a.id, a.wallet_id, a.user_id, a.dept_id, a.biz_type, a.biz_id, a.title, a.price, a.balance, a.version, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.tenant_id FROM wallet_transaction a LEFT JOIN wallet_manage m ON m.id = a.wallet_id AND m.del_flag = '0' AND m.tenant_id" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "B69DCB5A1FD7632EFCA1D9FD2C2B6033", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 209.28399658203126, + "avg_read_rows": 790.0, + "sample_sql": "SELECT COUNT(*) AS total FROM (SELECT a.id, a.order_no, a.user_id, a.user_dept_id, a.merchant_id, a.merchant_type, a.merchant_dept_id, a.hard_id, a.dept_id, a.wallet_id, a.parent_car_id, a.order_source_type_id, a.order_type, a.order_status, a.pay_type, a.hour_type, a.sys_type, a.total_price, a.extra" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "52BC5BCC7C8E5AE4C2D0AD6FFB45A7FB", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 40.98400115966797, + "avg_read_rows": 4192.0, + "sample_sql": "SELECT * FROM (SELECT a.hard_id, a.merchant_id, a.user_dept_id, a.merchant_dept_id, sum(a.pay_price) AS totalPayPrice, count(0) AS totalPayCount FROM hard_order a LEFT JOIN hard_manager m ON a.hard_id = m.id AND m.tenant_id = 1 WHERE a.del_flag = '0' AND a.order_status IN ('5', '20', '10') AND a.mer" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "E35B8801C67C012BE090D08557908766", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 13.175000190734864, + "avg_read_rows": 1826.0, + "sample_sql": "SELECT id, parent_car_id, product_id, product_name, product_pic, product_price, product_nature, product_count, product_weight, is_discounts_product, total_price, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM hard_car WHERE del_flag = '0' AND (parent_car_id = 20641975388316" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "FA1B8969A5A1CE52BBC27574599652C4", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 7.491000175476074, + "avg_read_rows": 874.0, + "sample_sql": "SELECT COUNT(*) AS total FROM wallet_transaction a WHERE a.del_flag = '0' AND a.tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "1ADDE42FE2D78F8AA625DD2A847E989E", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 5.1579999923706059, + "avg_read_rows": 40.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "5985A04701EA41E12546B3B563F231D2", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 4.446000099182129, + "avg_read_rows": 103.0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "C725CE4D66BEF9EA77B58112C8C100D5", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 3.696000099182129, + "avg_read_rows": 94.0, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "44CF22DC2CF24605D864CC451DF8EF98", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 2.8559999465942385, + "avg_read_rows": 94.0, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.canteen_is_open = '1' AND t.parent_id = -1 AND FIND_IN_SET('1', types)) AND t.tenant_id = 1" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "5B2CAD01C87C606F1CD1F7AD11EDFA75", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 2.681999921798706, + "avg_read_rows": 1.0, + "sample_sql": "SELECT id, pay_amount_meal_limit, pay_amount_meal_times, pay_amount_enable, refresh_qr_code_enable, refresh_qr_code_fre, off_line_order_apply_enable, after_sale_refund_reasons, after_sale_return_reasons, topup_dept_str, topup_user_id, zb_default_xfj_discounts, zb_special_xfj_discounts, fzb_default_x" + }, + { + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "248A89F582F293AACB249474EFB5B8DB", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 0.8309999704360962, + "avg_read_rows": 34.0, + "sample_sql": "SELECT id, user_id, user_type, biz_type, hard_id, hard_door_id, cabinet_no, order_id, auth_id, request_open_dto, request_open_vo, request_open_time, is_open, open_callback_time, open_callback_vo, video_callback_vo, video_callback_time, sku_submit_dto, sku_submit_vo, sku_submit_recog_id, sku_submit_t" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "2A2D3A4640A31D4959FAB965FEADD481", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 0.5789999961853027, + "avg_read_rows": 34.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "ECE7F270F89DE683F6E1B8980F8340E5", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 0.38499999046325686, + "avg_read_rows": 16.0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperatio" + }, + { + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "E82DD7931019127A383DB3D879D92234", + "exec_cnt": 1, + "table_scan_cnt": 1.0, + "table_scan_pct": 100.0, + "avg_ms": 0.2150000035762787, + "avg_read_rows": 5.0, + "sample_sql": "SELECT id, name, icon, unique_code, is_rule, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_type WHERE del_flag = '0' AND (unique_code = '1') AND tenant_id = 1" + } + ] +} \ No newline at end of file diff --git a/database/result-4-v1.json b/database/result-4-v1.json new file mode 100644 index 0000000..7919d3d --- /dev/null +++ b/database/result-4-v1.json @@ -0,0 +1,328 @@ +{ + "RECORDS": [ + { + "req_time": "17/6/2026 12:17:08.1162", + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "3CC4E4211ACF2F21F80D12F01085EBA7", + "PLAN_ID": 62245248, + "elapsed_ms": 16.92099952697754, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 737, + "SSSTORE_READ_ROW_COUNT": 56, + "RETURN_ROWS": 1, + "sample_sql": "SELECT t.id, t.order_no, t.user_id, t.user_dept_id, t.merchant_id, t.merchant_type, t.merchant_dept_id, t.hard_id, t.dept_id, t.wallet_id, t.parent_car_id, t.order_source_type_id, t.order_type, t.order_status, t.pay_type, t.hour_type, t.appt_id, t.sys_type, t.total_price, t.extra_price, t.pay_price, t.pay_time, t.pay_refund_id, t.refund_price, t.refund_time, t.refund_status, t.apply_cancel_time, t.unfollow_time, t.android_order_code, t.is_offline_order, t.product_desc, t.offline_pay_success, t.c" + }, + { + "req_time": "17/6/2026 12:17:21.9731", + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "3CC4E4211ACF2F21F80D12F01085EBA7", + "PLAN_ID": 62245248, + "elapsed_ms": 16.841999053955079, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 737, + "SSSTORE_READ_ROW_COUNT": 56, + "RETURN_ROWS": 1, + "sample_sql": "SELECT t.id, t.order_no, t.user_id, t.user_dept_id, t.merchant_id, t.merchant_type, t.merchant_dept_id, t.hard_id, t.dept_id, t.wallet_id, t.parent_car_id, t.order_source_type_id, t.order_type, t.order_status, t.pay_type, t.hour_type, t.appt_id, t.sys_type, t.total_price, t.extra_price, t.pay_price, t.pay_time, t.pay_refund_id, t.refund_price, t.refund_time, t.refund_status, t.apply_cancel_time, t.unfollow_time, t.android_order_code, t.is_offline_order, t.product_desc, t.offline_pay_success, t.c" + }, + { + "req_time": "17/6/2026 12:17:21.9442", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "64C62234D71CD0810A7719CDEB6F8F72", + "PLAN_ID": 62245245, + "elapsed_ms": 2.6110000610351564, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 17, + "SSSTORE_READ_ROW_COUNT": 408, + "RETURN_ROWS": 381, + "sample_sql": "SELECT id, parent_id, dept_id, default_wallet_type_id, name, types, canteen_is_open, catgory_id, logo_pic, collection_code, collection_url_code, swiper_pic, phone, job_time, address_des, visible_mobile, is_sync_zy, sort, sup_type, discounts_price, cooperation_status, mch_count, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM mch_manage WHERE del_flag = '0' AND (types IN ('2', '5')) AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:08.0879", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "64C62234D71CD0810A7719CDEB6F8F72", + "PLAN_ID": 62245245, + "elapsed_ms": 2.38100004196167, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 17, + "SSSTORE_READ_ROW_COUNT": 408, + "RETURN_ROWS": 381, + "sample_sql": "SELECT id, parent_id, dept_id, default_wallet_type_id, name, types, canteen_is_open, catgory_id, logo_pic, collection_code, collection_url_code, swiper_pic, phone, job_time, address_des, visible_mobile, is_sync_zy, sort, sup_type, discounts_price, cooperation_status, mch_count, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM mch_manage WHERE del_flag = '0' AND (types IN ('2', '5')) AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:25.4368", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "153470DCBE2144612BC19937A758575F", + "PLAN_ID": 62245186, + "elapsed_ms": 1.2999999523162842, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 17, + "SSSTORE_READ_ROW_COUNT": 292, + "RETURN_ROWS": 10, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperation_status, t.mch_count, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIN" + }, + { + "req_time": "17/6/2026 12:17:13.5196", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "153470DCBE2144612BC19937A758575F", + "PLAN_ID": 62245186, + "elapsed_ms": 1.2519999742507935, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 17, + "SSSTORE_READ_ROW_COUNT": 292, + "RETURN_ROWS": 10, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperation_status, t.mch_count, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIN" + }, + { + "req_time": "17/6/2026 12:17:21.9556", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "80BCBC95727FBE6464312DE02CF9E196", + "PLAN_ID": 62245246, + "elapsed_ms": 0.6330000162124634, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 17, + "SSSTORE_READ_ROW_COUNT": 76, + "RETURN_ROWS": 0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperation_status, a.mch_count, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.tenant_id, c.name AS catgoryName FROM mch_manage a LEFT JOIN mch_catgory c ON c.id = a.catgory_id AND c.ten" + }, + { + "req_time": "17/6/2026 12:17:13.5171", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "PLAN_ID": 62235165, + "elapsed_ms": 0.5699999928474426, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 17, + "SSSTORE_READ_ROW_COUNT": 77, + "RETURN_ROWS": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:25.4353", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "PLAN_ID": 62235165, + "elapsed_ms": 0.5580000281333923, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 17, + "SSSTORE_READ_ROW_COUNT": 77, + "RETURN_ROWS": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:08.0991", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "80BCBC95727FBE6464312DE02CF9E196", + "PLAN_ID": 62245246, + "elapsed_ms": 0.5559999942779541, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 17, + "SSSTORE_READ_ROW_COUNT": 76, + "RETURN_ROWS": 0, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperation_status, a.mch_count, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.tenant_id, c.name AS catgoryName FROM mch_manage a LEFT JOIN mch_catgory c ON c.id = a.catgory_id AND c.ten" + }, + { + "req_time": "17/6/2026 12:17:18.0536", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "30E53CB2C758ED3B74795ECA38F6FA74", + "PLAN_ID": 62235181, + "elapsed_ms": 0.4189999997615814, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 2, + "SSSTORE_READ_ROW_COUNT": 4, + "RETURN_ROWS": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM wallet_manage WHERE del_flag = '0' AND (user_id = 1965333956314992642) AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:32.8154", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "30E53CB2C758ED3B74795ECA38F6FA74", + "PLAN_ID": 62235181, + "elapsed_ms": 0.33899998664855959, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 0, + "RETURN_ROWS": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM wallet_manage WHERE del_flag = '0' AND (user_id = 2049675104898211841) AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:08.1371", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "ECE7F270F89DE683F6E1B8980F8340E5", + "PLAN_ID": 62244247, + "elapsed_ms": 0.3370000123977661, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 1, + "SSSTORE_READ_ROW_COUNT": 15, + "RETURN_ROWS": 1, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperation_status, a.mch_count, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.tenant_id, c.name AS catgoryName FROM mch_manage a LEFT JOIN mch_catgory c ON c.id = a.catgory_id AND c.ten" + }, + { + "req_time": "17/6/2026 12:17:30.5651", + "DB_NAME": "pjcloudx_hardware", + "SQL_ID": "52717C90AF3126884CFCBD8313F107FF", + "PLAN_ID": 62235265, + "elapsed_ms": 0.335999995470047, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 64, + "RETURN_ROWS": 0, + "sample_sql": "SELECT id, hard_group_id, merchant_id, dept_id, name, type, mq_client_id, unique_code, main_topic, mq_socket_address, mq_socket_port, mq_username, mq_password, is_take_food, face_app_id, face_sdk_key, face_active_key, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM hard_manager WHERE del_flag = '0' AND (merchant_id = 1940702924622221314 AND type IN ('10', '11'))" + }, + { + "req_time": "17/6/2026 12:17:32.7464", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "30E53CB2C758ED3B74795ECA38F6FA74", + "PLAN_ID": 62235181, + "elapsed_ms": 0.3330000042915344, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 0, + "RETURN_ROWS": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM wallet_manage WHERE del_flag = '0' AND (user_id = 2049675104898211841) AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:30.5545", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "80E7A7B065C86D4A79B228382E761086", + "PLAN_ID": 62235262, + "elapsed_ms": 0.3310000002384186, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 2, + "SSSTORE_READ_ROW_COUNT": 2, + "RETURN_ROWS": 0, + "sample_sql": "UPDATE wallet_manage SET balance = balance - 1760, total_expense = total_expense + 1760, version = version + 1 WHERE del_flag = '0' AND (id = 1965341846136410113) AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:18.055", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "72232D3632B6E842E8DA58FC16E6EE4E", + "PLAN_ID": 62235182, + "elapsed_ms": 0.32899999618530276, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 2, + "SSSTORE_READ_ROW_COUNT": 4, + "RETURN_ROWS": 2, + "sample_sql": "SELECT id, user_id, wallet_type_id, dept_id, card_number, balance, total_expense, total_recharge, freeze_price, is_freeze, active_bind_time, status, version, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_manage WHERE del_flag = '0' AND (user_id = 1965333956314992642) AND tenant_id = 1 ORDER BY user_id DESC, wallet_type_id ASC, create_time DESC LIMIT 10" + }, + { + "req_time": "17/6/2026 12:17:21.9943", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "ECE7F270F89DE683F6E1B8980F8340E5", + "PLAN_ID": 62244247, + "elapsed_ms": 0.3269999921321869, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 1, + "SSSTORE_READ_ROW_COUNT": 15, + "RETURN_ROWS": 1, + "sample_sql": "SELECT a.id, a.parent_id, a.dept_id, a.default_wallet_type_id, a.name, a.types, a.canteen_is_open, a.catgory_id, a.logo_pic, a.collection_code, a.collection_url_code, a.swiper_pic, a.phone, a.address_des, a.job_time, a.is_sync_zy, a.visible_mobile, a.sort, a.sup_type, a.discounts_price, a.cooperation_status, a.mch_count, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.tenant_id, c.name AS catgoryName FROM mch_manage a LEFT JOIN mch_catgory c ON c.id = a.catgory_id AND c.ten" + }, + { + "req_time": "17/6/2026 12:17:30.5445", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "E99DBD2BC95F860A5F3962DCAA8ADC45", + "PLAN_ID": 62235257, + "elapsed_ms": 0.3230000138282776, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 1, + "SSSTORE_READ_ROW_COUNT": 6, + "RETURN_ROWS": 1, + "sample_sql": "SELECT t.id, t.user_id, t.wallet_type_id, t.dept_id, t.card_number, t.balance, t.total_expense, t.total_recharge, t.freeze_price, t.is_freeze, t.active_bind_time, t.status, t.version, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id, t1.name AS walletTypeName, t1.unique_code AS walletTypeUniqueCode, t1.icon AS walletTypeIcon FROM wallet_manage t LEFT JOIN wallet_type t1 ON (t1.id = t.wallet_type_id AND t1.del_flag = '0') AND t1.tenant_id = 1 WHERE t.del_flag = '0' " + }, + { + "req_time": "17/6/2026 12:17:18.2056", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "456BC8375C4B7B6E222B78BADB7922FD", + "PLAN_ID": 62237197, + "elapsed_ms": 0.26600000262260439, + "TABLE_SCAN": 1, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 5, + "RETURN_ROWS": 0, + "sample_sql": "SELECT a.id, a.coupon_id, a.user_id, a.user_name, a.coupon_code, a.status, a.coupon_name, a.coupon_type, a.face_value, a.min_point, a.start_time, a.end_time, a.use_time, a.order_id, a.use_amount, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.tenant_id FROM act_coupon_record a LEFT JOIN act_coupon c ON c.id = a.coupon_id AND c.del_flag = '0' AND c.tenant_id = 1 WHERE a.del_flag = '0' AND a.user_id = 1965333956314992642 AND a.status = '1' AND a.end_time >= now() AND a.start" + }, + { + "req_time": "17/6/2026 12:17:30.5216", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "F3B83B175E6A8D1E9AEA3FC1C39D36C4", + "PLAN_ID": 62235147, + "elapsed_ms": 0.25099998712539675, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 1, + "SSSTORE_READ_ROW_COUNT": 2, + "RETURN_ROWS": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperation_status, t.mch_count, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id FROM mch_manage t WHERE t.del_flag = '0' AND (t.id = 1940702924622221314) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:21.9938", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "68C65430C5582C8802BE94318CAECE23", + "PLAN_ID": 62242393, + "elapsed_ms": 0.25099998712539675, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 1, + "SSSTORE_READ_ROW_COUNT": 1, + "RETURN_ROWS": 1, + "sample_sql": "SELECT id, user_id, wallet_type_id, dept_id, card_number, balance, total_expense, total_recharge, freeze_price, is_freeze, active_bind_time, status, version, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_manage WHERE del_flag = '0' AND (id IN (1903406522238185473)) AND tenant_id = 1 ORDER BY user_id DESC, wallet_type_id ASC, create_time DESC" + }, + { + "req_time": "17/6/2026 12:17:14.5201", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "30E53CB2C758ED3B74795ECA38F6FA74", + "PLAN_ID": 62235181, + "elapsed_ms": 0.24400000274181367, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 0, + "RETURN_ROWS": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM wallet_manage WHERE del_flag = '0' AND (user_id = 2049675104898211841) AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:14.4521", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "30E53CB2C758ED3B74795ECA38F6FA74", + "PLAN_ID": 62235181, + "elapsed_ms": 0.2409999966621399, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 0, + "SSSTORE_READ_ROW_COUNT": 0, + "RETURN_ROWS": 1, + "sample_sql": "SELECT COUNT(*) AS total FROM wallet_manage WHERE del_flag = '0' AND (user_id = 2049675104898211841) AND tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:08.1372", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "68C65430C5582C8802BE94318CAECE23", + "PLAN_ID": 62242393, + "elapsed_ms": 0.23899999260902406, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 1, + "SSSTORE_READ_ROW_COUNT": 1, + "RETURN_ROWS": 1, + "sample_sql": "SELECT id, user_id, wallet_type_id, dept_id, card_number, balance, total_expense, total_recharge, freeze_price, is_freeze, active_bind_time, status, version, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_manage WHERE del_flag = '0' AND (id IN (1903406522238185473)) AND tenant_id = 1 ORDER BY user_id DESC, wallet_type_id ASC, create_time DESC" + }, + { + "req_time": "17/6/2026 12:17:18.0583", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "F3B83B175E6A8D1E9AEA3FC1C39D36C4", + "PLAN_ID": 62235147, + "elapsed_ms": 0.23000000417232514, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 1, + "SSSTORE_READ_ROW_COUNT": 2, + "RETURN_ROWS": 1, + "sample_sql": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperation_status, t.mch_count, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id FROM mch_manage t WHERE t.del_flag = '0' AND (t.id = 1940702924622221314) AND t.tenant_id = 1" + }, + { + "req_time": "17/6/2026 12:17:30.5521", + "DB_NAME": "pjcloudx_wallet", + "SQL_ID": "7523DB5CA61B44A6E48F81F4244E47A0", + "PLAN_ID": 62235260, + "elapsed_ms": 0.21899999678134919, + "TABLE_SCAN": 0, + "MEMSTORE_READ_ROW_COUNT": 1, + "SSSTORE_READ_ROW_COUNT": 1, + "RETURN_ROWS": 1, + "sample_sql": "SELECT id, user_id, wallet_type_id, dept_id, card_number, balance, total_expense, total_recharge, freeze_price, is_freeze, active_bind_time, status, version, create_by, create_time, update_by, update_time, del_flag, tenant_id FROM wallet_manage WHERE id = 1965341846136410113 AND del_flag = '0' AND tenant_id = 1" + } + ] +} \ No newline at end of file diff --git a/database/result-5-v1.json b/database/result-5-v1.json new file mode 100644 index 0000000..dace15a --- /dev/null +++ b/database/result-5-v1.json @@ -0,0 +1,46 @@ +{ + "RECORDS": [ + { + "SQL_ID": "0634F31AAF585CA78923D241EF91AB7C", + "PLAN_ID": 62254446, + "QUERY_SQL": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperation_status, t.mch_count, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1 ORDER BY t.sort DESC, t.create_time DESC, t.id DESC LIMIT 10", + "PARAMS_VALUE": "", + "elapsed_ms": 1.093999981880188 + }, + { + "SQL_ID": "0634F31AAF585CA78923D241EF91AB7C", + "PLAN_ID": 62254446, + "QUERY_SQL": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperation_status, t.mch_count, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1 ORDER BY t.sort DESC, t.create_time DESC, t.id DESC LIMIT 10", + "PARAMS_VALUE": "", + "elapsed_ms": 1.024999976158142 + }, + { + "SQL_ID": "0634F31AAF585CA78923D241EF91AB7C", + "PLAN_ID": 62254446, + "QUERY_SQL": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperation_status, t.mch_count, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1 ORDER BY t.sort DESC, t.create_time DESC, t.id DESC LIMIT 10", + "PARAMS_VALUE": "", + "elapsed_ms": 0.9350000023841858 + }, + { + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "PLAN_ID": 62254441, + "QUERY_SQL": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1", + "PARAMS_VALUE": "", + "elapsed_ms": 0.5960000157356262 + }, + { + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "PLAN_ID": 62254441, + "QUERY_SQL": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1", + "PARAMS_VALUE": "", + "elapsed_ms": 0.5920000076293945 + }, + { + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "PLAN_ID": 62254441, + "QUERY_SQL": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1", + "PARAMS_VALUE": "", + "elapsed_ms": 0.5609999895095825 + } + ] +} \ No newline at end of file diff --git a/database/sql-execute-map.js b/database/sql-execute-map.js new file mode 100644 index 0000000..2d83eb5 --- /dev/null +++ b/database/sql-execute-map.js @@ -0,0 +1,152 @@ +const map = [ + { + executeSql: ` + SELECT + DB_NAME, + SQL_ID, + COUNT(*) AS exec_cnt, + ROUND(SUM(ELAPSED_TIME) / 1000000, 2) AS total_s, + ROUND(AVG(ELAPSED_TIME) / 1000, 3) AS avg_ms, + ROUND(MAX(ELAPSED_TIME) / 1000, 3) AS max_ms, + SUM(CASE WHEN TABLE_SCAN = 1 THEN 1 ELSE 0 END) AS table_scan_cnt, + ROUND(AVG(MEMSTORE_READ_ROW_COUNT + SSSTORE_READ_ROW_COUNT), 2) AS avg_read_rows, + ROUND(AVG(RETURN_ROWS), 2) AS avg_return_rows, + MAX(LEFT(REPLACE(QUERY_SQL, '\n', ' '), 300)) AS sample_sql +FROM oceanbase.GV$OB_SQL_AUDIT +WHERE REQUEST_TIME >= UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 HOUR)) * 1000000 + AND DB_NAME IN ('pjcloudx_wallet', 'pjcloudx_hardware') + AND IS_INNER_SQL = 0 + AND QUERY_SQL NOT IN ('SET autocommit=1', 'SET autocommit=0', 'commit', 'SELECT @@session.transaction_read_only') +GROUP BY DB_NAME, SQL_ID +ORDER BY total_s DESC +LIMIT 30; + `, + resultJsonPath: './result-1-v1.json' + }, + { + executeSql: ` + SELECT + DB_NAME, + SQL_ID, + COUNT(*) AS exec_cnt, + ROUND(AVG(ELAPSED_TIME) / 1000, 3) AS avg_ms, + ROUND(MAX(ELAPSED_TIME) / 1000, 3) AS max_ms, + ROUND(SUM(ELAPSED_TIME) / 1000000, 2) AS total_s, + SUM(CASE WHEN TABLE_SCAN = 1 THEN 1 ELSE 0 END) AS table_scan_cnt, + ROUND(AVG(MEMSTORE_READ_ROW_COUNT + SSSTORE_READ_ROW_COUNT), 2) AS avg_read_rows, + MAX(LEFT(REPLACE(QUERY_SQL, '\n', ' '), 300)) AS sample_sql +FROM oceanbase.GV$OB_SQL_AUDIT +WHERE REQUEST_TIME >= UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 HOUR)) * 1000000 + AND DB_NAME IN ('pjcloudx_wallet', 'pjcloudx_hardware') + AND IS_INNER_SQL = 0 + AND QUERY_SQL NOT IN ('SET autocommit=1', 'SET autocommit=0', 'commit', 'SELECT @@session.transaction_read_only') +GROUP BY DB_NAME, SQL_ID +HAVING COUNT(*) >= 5 +ORDER BY avg_ms DESC +LIMIT 30; + `, + resultJsonPath: './result-2-v1.json' + }, + { + executeSql: ` + SELECT + DB_NAME, + SQL_ID, + COUNT(*) AS exec_cnt, + SUM(CASE WHEN TABLE_SCAN = 1 THEN 1 ELSE 0 END) AS table_scan_cnt, + ROUND(SUM(CASE WHEN TABLE_SCAN = 1 THEN 1 ELSE 0 END) / COUNT(*) * 100, 2) AS table_scan_pct, + ROUND(AVG(ELAPSED_TIME) / 1000, 3) AS avg_ms, + ROUND(AVG(MEMSTORE_READ_ROW_COUNT + SSSTORE_READ_ROW_COUNT), 2) AS avg_read_rows, + MAX(LEFT(REPLACE(QUERY_SQL, '\n', ' '), 300)) AS sample_sql +FROM oceanbase.GV$OB_SQL_AUDIT +WHERE REQUEST_TIME >= UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 HOUR)) * 1000000 + AND DB_NAME IN ('pjcloudx_wallet', 'pjcloudx_hardware') + AND IS_INNER_SQL = 0 + AND QUERY_SQL NOT IN ('SET autocommit=1', 'SET autocommit=0', 'commit', 'SELECT @@session.transaction_read_only') +GROUP BY DB_NAME, SQL_ID +HAVING table_scan_cnt > 0 +ORDER BY table_scan_cnt DESC, avg_ms DESC +LIMIT 30; + `, + resultJsonPath: './result-3-v1.json' + }, + { + executeSql: ` + SELECT + FROM_UNIXTIME(REQUEST_TIME / 1000000) AS req_time, + DB_NAME, + SQL_ID, + PLAN_ID, + ROUND(ELAPSED_TIME / 1000, 3) AS elapsed_ms, + TABLE_SCAN, + MEMSTORE_READ_ROW_COUNT, + SSSTORE_READ_ROW_COUNT, + RETURN_ROWS, + LEFT(REPLACE(QUERY_SQL, '\n', ' '), 500) AS sample_sql +FROM oceanbase.GV$OB_SQL_AUDIT +WHERE REQUEST_TIME >= UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 HOUR)) * 1000000 + AND DB_NAME IN ('pjcloudx_wallet', 'pjcloudx_hardware') + AND IS_INNER_SQL = 0 + AND ( + QUERY_SQL LIKE '%mch_manage%' + OR QUERY_SQL LIKE '%hard_manage%' + OR QUERY_SQL LIKE '%wallet_manage%' + OR QUERY_SQL LIKE '%act_coupon_record%' + ) +ORDER BY ELAPSED_TIME DESC +LIMIT 50; + `, + resultJsonPath: './result-4-v1.json' + }, + { + executeSql: ` + { + "RECORDS": [ + { + "SQL_ID": "0634F31AAF585CA78923D241EF91AB7C", + "PLAN_ID": 62254446, + "QUERY_SQL": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperation_status, t.mch_count, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1 ORDER BY t.sort DESC, t.create_time DESC, t.id DESC LIMIT 10", + "PARAMS_VALUE": "", + "elapsed_ms": 1.093999981880188 + }, + { + "SQL_ID": "0634F31AAF585CA78923D241EF91AB7C", + "PLAN_ID": 62254446, + "QUERY_SQL": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperation_status, t.mch_count, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1 ORDER BY t.sort DESC, t.create_time DESC, t.id DESC LIMIT 10", + "PARAMS_VALUE": "", + "elapsed_ms": 1.024999976158142 + }, + { + "SQL_ID": "0634F31AAF585CA78923D241EF91AB7C", + "PLAN_ID": 62254446, + "QUERY_SQL": "SELECT t.id, t.parent_id, t.dept_id, t.default_wallet_type_id, t.name, t.types, t.canteen_is_open, t.catgory_id, t.logo_pic, t.collection_code, t.collection_url_code, t.swiper_pic, t.phone, t.job_time, t.address_des, t.visible_mobile, t.is_sync_zy, t.sort, t.sup_type, t.discounts_price, t.cooperation_status, t.mch_count, t.create_by, t.create_time, t.update_by, t.update_time, t.del_flag, t.tenant_id FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1 ORDER BY t.sort DESC, t.create_time DESC, t.id DESC LIMIT 10", + "PARAMS_VALUE": "", + "elapsed_ms": 0.9350000023841858 + }, + { + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "PLAN_ID": 62254441, + "QUERY_SQL": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1", + "PARAMS_VALUE": "", + "elapsed_ms": 0.5960000157356262 + }, + { + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "PLAN_ID": 62254441, + "QUERY_SQL": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1", + "PARAMS_VALUE": "", + "elapsed_ms": 0.5920000076293945 + }, + { + "SQL_ID": "54A9BC12E3BC3126B48205A4A94DA01C", + "PLAN_ID": 62254441, + "QUERY_SQL": "SELECT COUNT(*) AS total FROM mch_manage t WHERE t.del_flag = '0' AND (t.visible_mobile = '1' AND t.parent_id = -1 AND FIND_IN_SET('2', types)) AND t.tenant_id = 1", + "PARAMS_VALUE": "", + "elapsed_ms": 0.5609999895095825 + } + ] +} + ` + resultJsonPath: './result-5-v1.json' + } +] \ No newline at end of file diff --git a/database/test/index.js b/database/test/index.js new file mode 100644 index 0000000..4029d86 --- /dev/null +++ b/database/test/index.js @@ -0,0 +1,283 @@ +const { spawn } = require("child_process"); +const fs = require("fs"); +const path = require("path"); + +const CONFIG = { + url: + process.env.API_URL || + "https://dzc-test-1.fy.takin.cc/wallet/wallet-setting/ad/get-discounts-list?userId=1875049673022279681&hardId=1887466308336488450", + headers: { + "CLIENT-TOC": process.env.CLIENT_TOC || "Y", + Authorization: + process.env.API_AUTHORIZATION || + "Bearer 2913ff2a-a570-46c2-adb4-26d397aa9725", + "TENANT-ID": process.env.API_TENANT_ID || "1", + }, + rounds: { + round1: { total: 10, concurrency: 2, description: "保守压测第一轮" }, + round2: { total: 15, concurrency: 3, description: "保守压测第二轮" }, + round3: { total: 20, concurrency: 4, description: "观察是否出现慢尖刺" }, + }, + outputDir: path.join(__dirname, "output"), +}; + +function ensureOutputDir() { + fs.mkdirSync(CONFIG.outputDir, { recursive: true }); +} + +function formatNow() { + const now = new Date(); + const pad = (value) => String(value).padStart(2, "0"); + return [ + now.getFullYear(), + pad(now.getMonth() + 1), + pad(now.getDate()), + "-", + pad(now.getHours()), + pad(now.getMinutes()), + pad(now.getSeconds()), + ].join(""); +} + +function getRoundName() { + const roundName = process.argv[2]; + if (!roundName || !CONFIG.rounds[roundName]) { + const available = Object.entries(CONFIG.rounds) + .map( + ([name, round]) => + ` - ${name}: total=${round.total}, concurrency=${round.concurrency}, ${round.description}`, + ) + .join("\n"); + console.log("请指定要执行的轮次,例如: node index.js round1"); + console.log("可用轮次:\n" + available); + process.exit(1); + } + return roundName; +} + +function buildCurlArgs(requestId) { + const writeOut = JSON.stringify({ + requestId, + http_code: "%{http_code}", + time_connect: "%{time_connect}", + time_starttransfer: "%{time_starttransfer}", + time_total: "%{time_total}", + }); + const args = ["-o", "/dev/null", "-sS"]; + + Object.entries(CONFIG.headers).forEach(([key, value]) => { + args.push("-H", `${key}: ${value}`); + }); + + args.push("-w", writeOut, CONFIG.url); + return args; +} + +function runCurl(requestId) { + return new Promise((resolve) => { + const startedAt = new Date().toISOString(); + const child = spawn("curl", buildCurlArgs(requestId), { + stdio: ["ignore", "pipe", "pipe"], + }); + + let stdout = ""; + let stderr = ""; + + child.stdout.on("data", (chunk) => { + stdout += chunk.toString(); + }); + + child.stderr.on("data", (chunk) => { + stderr += chunk.toString(); + }); + + child.on("close", (code) => { + let parsed = null; + + try { + parsed = JSON.parse(stdout.trim()); + } catch (error) { + parsed = null; + } + + const result = { + requestId, + startedAt, + finishedAt: new Date().toISOString(), + exitCode: code, + httpCode: Number(parsed?.http_code || 0), + connect: Number(parsed?.time_connect || 0), + starttransfer: Number(parsed?.time_starttransfer || 0), + total: Number(parsed?.time_total || 0), + ok: code === 0 && Number(parsed?.http_code || 0) === 200, + error: stderr.trim() || null, + raw: stdout.trim(), + }; + + const summary = [ + `#${String(requestId).padStart(2, "0")}`, + `code=${result.httpCode || code}`, + `connect=${result.connect.toFixed(3)}s`, + `ttfb=${result.starttransfer.toFixed(3)}s`, + `total=${result.total.toFixed(3)}s`, + ]; + + if (!result.ok && result.error) { + summary.push(`error=${result.error}`); + } + + console.log(summary.join(" | ")); + resolve(result); + }); + }); +} + +async function runWithConcurrency(total, concurrency) { + const results = []; + let nextId = 1; + + async function worker() { + while (nextId <= total) { + const current = nextId; + nextId += 1; + const result = await runCurl(current); + results.push(result); + } + } + + const workers = Array.from( + { length: Math.min(concurrency, total) }, + () => worker(), + ); + await Promise.all(workers); + results.sort((a, b) => a.requestId - b.requestId); + return results; +} + +function percentile(numbers, ratio) { + if (!numbers.length) return 0; + const sorted = [...numbers].sort((a, b) => a - b); + const index = Math.min( + sorted.length - 1, + Math.max(0, Math.ceil(sorted.length * ratio) - 1), + ); + return sorted[index]; +} + +function buildSummary(results) { + const totals = results.map((item) => item.total); + const avg = + totals.reduce((sum, current) => sum + current, 0) / (totals.length || 1); + const max = Math.max(...totals, 0); + const slow3 = results.filter((item) => item.total > 3).length; + const slow5 = results.filter((item) => item.total > 5).length; + const non200 = results.filter((item) => item.httpCode !== 200).length; + + return { + count: results.length, + avg, + p50: percentile(totals, 0.5), + p90: percentile(totals, 0.9), + p95: percentile(totals, 0.95), + max, + slow3, + slow5, + non200, + slowest: [...results] + .sort((a, b) => b.total - a.total) + .slice(0, 5) + .map((item) => ({ + requestId: item.requestId, + httpCode: item.httpCode, + connect: item.connect, + starttransfer: item.starttransfer, + total: item.total, + error: item.error, + })), + }; +} + +function writeOutputs(roundName, results, summary) { + ensureOutputDir(); + const suffix = `${formatNow()}-${roundName}`; + const jsonPath = path.join(CONFIG.outputDir, `${suffix}.json`); + const tsvPath = path.join(CONFIG.outputDir, `${suffix}.tsv`); + + fs.writeFileSync( + jsonPath, + JSON.stringify( + { + roundName, + url: CONFIG.url, + headers: { + "CLIENT-TOC": CONFIG.headers["CLIENT-TOC"], + Authorization: "***masked***", + "TENANT-ID": CONFIG.headers["TENANT-ID"], + }, + summary, + results, + }, + null, + 2, + ), + ); + + const headerLine = + "requestId\thttpCode\tconnect\tstarttransfer\ttotal\texitCode\tstartedAt\tfinishedAt\terror"; + const lines = results.map((item) => + [ + item.requestId, + item.httpCode, + item.connect, + item.starttransfer, + item.total, + item.exitCode, + item.startedAt, + item.finishedAt, + (item.error || "").replace(/\s+/g, " ").trim(), + ].join("\t"), + ); + fs.writeFileSync(tsvPath, [headerLine, ...lines].join("\n")); + + return { jsonPath, tsvPath }; +} + +async function main() { + const roundName = getRoundName(); + const round = CONFIG.rounds[roundName]; + + console.log(`开始执行 ${roundName}: ${round.description}`); + console.log(`URL: ${CONFIG.url}`); + console.log(`总请求数: ${round.total}, 并发数: ${round.concurrency}`); + + const results = await runWithConcurrency(round.total, round.concurrency); + const summary = buildSummary(results); + const files = writeOutputs(roundName, results, summary); + + console.log("\n=== 汇总 ==="); + console.log(`count: ${summary.count}`); + console.log(`avg_total: ${summary.avg.toFixed(3)}s`); + console.log(`p50_total: ${summary.p50.toFixed(3)}s`); + console.log(`p90_total: ${summary.p90.toFixed(3)}s`); + console.log(`p95_total: ${summary.p95.toFixed(3)}s`); + console.log(`max_total: ${summary.max.toFixed(3)}s`); + console.log(`over_3s: ${summary.slow3}`); + console.log(`over_5s: ${summary.slow5}`); + console.log(`non_200: ${summary.non200}`); + + console.log("\n=== 最慢 5 条 ==="); + summary.slowest.forEach((item) => { + console.log( + `#${String(item.requestId).padStart(2, "0")} | code=${item.httpCode} | connect=${item.connect.toFixed(3)}s | ttfb=${item.starttransfer.toFixed(3)}s | total=${item.total.toFixed(3)}s`, + ); + }); + + console.log("\n结果文件:"); + console.log(`JSON: ${files.jsonPath}`); + console.log(`TSV : ${files.tsvPath}`); +} + +main().catch((error) => { + console.error("执行失败:", error); + process.exit(1); +}); diff --git a/database/test/output/20260617-202016-round3.json b/database/test/output/20260617-202016-round3.json new file mode 100644 index 0000000..c7e9c8e --- /dev/null +++ b/database/test/output/20260617-202016-round3.json @@ -0,0 +1,324 @@ +{ + "roundName": "round3", + "url": "https://dzc-test-1.fy.takin.cc/wallet/wallet-setting/ad/get-discounts-list?userId=1875049673022279681&hardId=1887466308336488450", + "headers": { + "CLIENT-TOC": "Y", + "Authorization": "***masked***", + "TENANT-ID": "1" + }, + "summary": { + "count": 20, + "avg": 0.2744306, + "p50": 0.271551, + "p90": 0.2893, + "p95": 0.299232, + "max": 0.304493, + "slow3": 0, + "slow5": 0, + "non200": 0, + "slowest": [ + { + "requestId": 3, + "httpCode": 200, + "connect": 0.030842, + "starttransfer": 0.304438, + "total": 0.304493, + "error": null + }, + { + "requestId": 14, + "httpCode": 200, + "connect": 0.030383, + "starttransfer": 0.299171, + "total": 0.299232, + "error": null + }, + { + "requestId": 11, + "httpCode": 200, + "connect": 0.027583, + "starttransfer": 0.289248, + "total": 0.2893, + "error": null + }, + { + "requestId": 5, + "httpCode": 200, + "connect": 0.029901, + "starttransfer": 0.281172, + "total": 0.281265, + "error": null + }, + { + "requestId": 4, + "httpCode": 200, + "connect": 0.019759, + "starttransfer": 0.280199, + "total": 0.280263, + "error": null + } + ] + }, + "results": [ + { + "requestId": 1, + "startedAt": "2026-06-17T12:20:15.506Z", + "finishedAt": "2026-06-17T12:20:15.800Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.025205, + "starttransfer": 0.279962, + "total": 0.280025, + "ok": true, + "error": null, + "raw": "{\"requestId\":1,\"http_code\":\"200\",\"time_connect\":\"0.025205\",\"time_starttransfer\":\"0.279962\",\"time_total\":\"0.280025\"}" + }, + { + "requestId": 2, + "startedAt": "2026-06-17T12:20:15.509Z", + "finishedAt": "2026-06-17T12:20:15.798Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.021563, + "starttransfer": 0.279962, + "total": 0.280022, + "ok": true, + "error": null, + "raw": "{\"requestId\":2,\"http_code\":\"200\",\"time_connect\":\"0.021563\",\"time_starttransfer\":\"0.279962\",\"time_total\":\"0.280022\"}" + }, + { + "requestId": 3, + "startedAt": "2026-06-17T12:20:15.510Z", + "finishedAt": "2026-06-17T12:20:15.822Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.030842, + "starttransfer": 0.304438, + "total": 0.304493, + "ok": true, + "error": null, + "raw": "{\"requestId\":3,\"http_code\":\"200\",\"time_connect\":\"0.030842\",\"time_starttransfer\":\"0.304438\",\"time_total\":\"0.304493\"}" + }, + { + "requestId": 4, + "startedAt": "2026-06-17T12:20:15.511Z", + "finishedAt": "2026-06-17T12:20:15.801Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.019759, + "starttransfer": 0.280199, + "total": 0.280263, + "ok": true, + "error": null, + "raw": "{\"requestId\":4,\"http_code\":\"200\",\"time_connect\":\"0.019759\",\"time_starttransfer\":\"0.280199\",\"time_total\":\"0.280263\"}" + }, + { + "requestId": 5, + "startedAt": "2026-06-17T12:20:15.798Z", + "finishedAt": "2026-06-17T12:20:16.090Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.029901, + "starttransfer": 0.281172, + "total": 0.281265, + "ok": true, + "error": null, + "raw": "{\"requestId\":5,\"http_code\":\"200\",\"time_connect\":\"0.029901\",\"time_starttransfer\":\"0.281172\",\"time_total\":\"0.281265\"}" + }, + { + "requestId": 6, + "startedAt": "2026-06-17T12:20:15.800Z", + "finishedAt": "2026-06-17T12:20:16.080Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.027649, + "starttransfer": 0.271161, + "total": 0.271245, + "ok": true, + "error": null, + "raw": "{\"requestId\":6,\"http_code\":\"200\",\"time_connect\":\"0.027649\",\"time_starttransfer\":\"0.271161\",\"time_total\":\"0.271245\"}" + }, + { + "requestId": 7, + "startedAt": "2026-06-17T12:20:15.801Z", + "finishedAt": "2026-06-17T12:20:16.084Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.025341, + "starttransfer": 0.273389, + "total": 0.275688, + "ok": true, + "error": null, + "raw": "{\"requestId\":7,\"http_code\":\"200\",\"time_connect\":\"0.025341\",\"time_starttransfer\":\"0.273389\",\"time_total\":\"0.275688\"}" + }, + { + "requestId": 8, + "startedAt": "2026-06-17T12:20:15.822Z", + "finishedAt": "2026-06-17T12:20:16.088Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.024346, + "starttransfer": 0.256425, + "total": 0.256544, + "ok": true, + "error": null, + "raw": "{\"requestId\":8,\"http_code\":\"200\",\"time_connect\":\"0.024346\",\"time_starttransfer\":\"0.256425\",\"time_total\":\"0.256544\"}" + }, + { + "requestId": 9, + "startedAt": "2026-06-17T12:20:16.080Z", + "finishedAt": "2026-06-17T12:20:16.361Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.023355, + "starttransfer": 0.269559, + "total": 0.26997, + "ok": true, + "error": null, + "raw": "{\"requestId\":9,\"http_code\":\"200\",\"time_connect\":\"0.023355\",\"time_starttransfer\":\"0.269559\",\"time_total\":\"0.269970\"}" + }, + { + "requestId": 10, + "startedAt": "2026-06-17T12:20:16.084Z", + "finishedAt": "2026-06-17T12:20:16.359Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.019739, + "starttransfer": 0.265885, + "total": 0.265948, + "ok": true, + "error": null, + "raw": "{\"requestId\":10,\"http_code\":\"200\",\"time_connect\":\"0.019739\",\"time_starttransfer\":\"0.265885\",\"time_total\":\"0.265948\"}" + }, + { + "requestId": 11, + "startedAt": "2026-06-17T12:20:16.088Z", + "finishedAt": "2026-06-17T12:20:16.387Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.027583, + "starttransfer": 0.289248, + "total": 0.2893, + "ok": true, + "error": null, + "raw": "{\"requestId\":11,\"http_code\":\"200\",\"time_connect\":\"0.027583\",\"time_starttransfer\":\"0.289248\",\"time_total\":\"0.289300\"}" + }, + { + "requestId": 12, + "startedAt": "2026-06-17T12:20:16.090Z", + "finishedAt": "2026-06-17T12:20:16.363Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.022429, + "starttransfer": 0.26409, + "total": 0.264131, + "ok": true, + "error": null, + "raw": "{\"requestId\":12,\"http_code\":\"200\",\"time_connect\":\"0.022429\",\"time_starttransfer\":\"0.264090\",\"time_total\":\"0.264131\"}" + }, + { + "requestId": 13, + "startedAt": "2026-06-17T12:20:16.360Z", + "finishedAt": "2026-06-17T12:20:16.641Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.027372, + "starttransfer": 0.271496, + "total": 0.271551, + "ok": true, + "error": null, + "raw": "{\"requestId\":13,\"http_code\":\"200\",\"time_connect\":\"0.027372\",\"time_starttransfer\":\"0.271496\",\"time_total\":\"0.271551\"}" + }, + { + "requestId": 14, + "startedAt": "2026-06-17T12:20:16.361Z", + "finishedAt": "2026-06-17T12:20:16.668Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.030383, + "starttransfer": 0.299171, + "total": 0.299232, + "ok": true, + "error": null, + "raw": "{\"requestId\":14,\"http_code\":\"200\",\"time_connect\":\"0.030383\",\"time_starttransfer\":\"0.299171\",\"time_total\":\"0.299232\"}" + }, + { + "requestId": 15, + "startedAt": "2026-06-17T12:20:16.363Z", + "finishedAt": "2026-06-17T12:20:16.636Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.023181, + "starttransfer": 0.259253, + "total": 0.262199, + "ok": true, + "error": null, + "raw": "{\"requestId\":15,\"http_code\":\"200\",\"time_connect\":\"0.023181\",\"time_starttransfer\":\"0.259253\",\"time_total\":\"0.262199\"}" + }, + { + "requestId": 16, + "startedAt": "2026-06-17T12:20:16.387Z", + "finishedAt": "2026-06-17T12:20:16.671Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.026335, + "starttransfer": 0.273058, + "total": 0.275693, + "ok": true, + "error": null, + "raw": "{\"requestId\":16,\"http_code\":\"200\",\"time_connect\":\"0.026335\",\"time_starttransfer\":\"0.273058\",\"time_total\":\"0.275693\"}" + }, + { + "requestId": 17, + "startedAt": "2026-06-17T12:20:16.636Z", + "finishedAt": "2026-06-17T12:20:16.922Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.033043, + "starttransfer": 0.274456, + "total": 0.274692, + "ok": true, + "error": null, + "raw": "{\"requestId\":17,\"http_code\":\"200\",\"time_connect\":\"0.033043\",\"time_starttransfer\":\"0.274456\",\"time_total\":\"0.274692\"}" + }, + { + "requestId": 18, + "startedAt": "2026-06-17T12:20:16.641Z", + "finishedAt": "2026-06-17T12:20:16.904Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.019704, + "starttransfer": 0.25085, + "total": 0.250943, + "ok": true, + "error": null, + "raw": "{\"requestId\":18,\"http_code\":\"200\",\"time_connect\":\"0.019704\",\"time_starttransfer\":\"0.250850\",\"time_total\":\"0.250943\"}" + }, + { + "requestId": 19, + "startedAt": "2026-06-17T12:20:16.669Z", + "finishedAt": "2026-06-17T12:20:16.947Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.030294, + "starttransfer": 0.270231, + "total": 0.270277, + "ok": true, + "error": null, + "raw": "{\"requestId\":19,\"http_code\":\"200\",\"time_connect\":\"0.030294\",\"time_starttransfer\":\"0.270231\",\"time_total\":\"0.270277\"}" + }, + { + "requestId": 20, + "startedAt": "2026-06-17T12:20:16.671Z", + "finishedAt": "2026-06-17T12:20:16.943Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.025012, + "starttransfer": 0.265067, + "total": 0.265131, + "ok": true, + "error": null, + "raw": "{\"requestId\":20,\"http_code\":\"200\",\"time_connect\":\"0.025012\",\"time_starttransfer\":\"0.265067\",\"time_total\":\"0.265131\"}" + } + ] +} \ No newline at end of file diff --git a/database/test/output/20260617-202016-round3.tsv b/database/test/output/20260617-202016-round3.tsv new file mode 100644 index 0000000..742c5e9 --- /dev/null +++ b/database/test/output/20260617-202016-round3.tsv @@ -0,0 +1,21 @@ +requestId httpCode connect starttransfer total exitCode startedAt finishedAt error +1 200 0.025205 0.279962 0.280025 0 2026-06-17T12:20:15.506Z 2026-06-17T12:20:15.800Z +2 200 0.021563 0.279962 0.280022 0 2026-06-17T12:20:15.509Z 2026-06-17T12:20:15.798Z +3 200 0.030842 0.304438 0.304493 0 2026-06-17T12:20:15.510Z 2026-06-17T12:20:15.822Z +4 200 0.019759 0.280199 0.280263 0 2026-06-17T12:20:15.511Z 2026-06-17T12:20:15.801Z +5 200 0.029901 0.281172 0.281265 0 2026-06-17T12:20:15.798Z 2026-06-17T12:20:16.090Z +6 200 0.027649 0.271161 0.271245 0 2026-06-17T12:20:15.800Z 2026-06-17T12:20:16.080Z +7 200 0.025341 0.273389 0.275688 0 2026-06-17T12:20:15.801Z 2026-06-17T12:20:16.084Z +8 200 0.024346 0.256425 0.256544 0 2026-06-17T12:20:15.822Z 2026-06-17T12:20:16.088Z +9 200 0.023355 0.269559 0.26997 0 2026-06-17T12:20:16.080Z 2026-06-17T12:20:16.361Z +10 200 0.019739 0.265885 0.265948 0 2026-06-17T12:20:16.084Z 2026-06-17T12:20:16.359Z +11 200 0.027583 0.289248 0.2893 0 2026-06-17T12:20:16.088Z 2026-06-17T12:20:16.387Z +12 200 0.022429 0.26409 0.264131 0 2026-06-17T12:20:16.090Z 2026-06-17T12:20:16.363Z +13 200 0.027372 0.271496 0.271551 0 2026-06-17T12:20:16.360Z 2026-06-17T12:20:16.641Z +14 200 0.030383 0.299171 0.299232 0 2026-06-17T12:20:16.361Z 2026-06-17T12:20:16.668Z +15 200 0.023181 0.259253 0.262199 0 2026-06-17T12:20:16.363Z 2026-06-17T12:20:16.636Z +16 200 0.026335 0.273058 0.275693 0 2026-06-17T12:20:16.387Z 2026-06-17T12:20:16.671Z +17 200 0.033043 0.274456 0.274692 0 2026-06-17T12:20:16.636Z 2026-06-17T12:20:16.922Z +18 200 0.019704 0.25085 0.250943 0 2026-06-17T12:20:16.641Z 2026-06-17T12:20:16.904Z +19 200 0.030294 0.270231 0.270277 0 2026-06-17T12:20:16.669Z 2026-06-17T12:20:16.947Z +20 200 0.025012 0.265067 0.265131 0 2026-06-17T12:20:16.671Z 2026-06-17T12:20:16.943Z \ No newline at end of file diff --git a/database/test/output/20260617-202105-round3.json b/database/test/output/20260617-202105-round3.json new file mode 100644 index 0000000..1265d3b --- /dev/null +++ b/database/test/output/20260617-202105-round3.json @@ -0,0 +1,324 @@ +{ + "roundName": "round3", + "url": "https://dzc-test-1.fy.takin.cc/wallet/wallet-setting/ad/get-discounts-list?userId=1875049673022279681&hardId=1887466308336488450", + "headers": { + "CLIENT-TOC": "Y", + "Authorization": "***masked***", + "TENANT-ID": "1" + }, + "summary": { + "count": 20, + "avg": 3.687642799999999, + "p50": 0.285588, + "p90": 11.06534, + "p95": 13.040461, + "max": 13.195691, + "slow3": 8, + "slow5": 4, + "non200": 0, + "slowest": [ + { + "requestId": 2, + "httpCode": 200, + "connect": 0.02423, + "starttransfer": 13.194165, + "total": 13.195691, + "error": null + }, + { + "requestId": 5, + "httpCode": 200, + "connect": 0.029047, + "starttransfer": 13.040307, + "total": 13.040461, + "error": null + }, + { + "requestId": 9, + "httpCode": 200, + "connect": 0.028518, + "starttransfer": 11.065208, + "total": 11.06534, + "error": null + }, + { + "requestId": 8, + "httpCode": 200, + "connect": 0.025027, + "starttransfer": 11.06316, + "total": 11.063251, + "error": null + }, + { + "requestId": 10, + "httpCode": 200, + "connect": 0.025051, + "starttransfer": 4.67919, + "total": 4.681006, + "error": null + } + ] + }, + "results": [ + { + "requestId": 1, + "startedAt": "2026-06-17T12:20:46.694Z", + "finishedAt": "2026-06-17T12:20:51.381Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.027495, + "starttransfer": 4.675778, + "total": 4.675896, + "ok": true, + "error": null, + "raw": "{\"requestId\":1,\"http_code\":\"200\",\"time_connect\":\"0.027495\",\"time_starttransfer\":\"4.675778\",\"time_total\":\"4.675896\"}" + }, + { + "requestId": 2, + "startedAt": "2026-06-17T12:20:46.696Z", + "finishedAt": "2026-06-17T12:20:59.901Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.02423, + "starttransfer": 13.194165, + "total": 13.195691, + "ok": true, + "error": null, + "raw": "{\"requestId\":2,\"http_code\":\"200\",\"time_connect\":\"0.024230\",\"time_starttransfer\":\"13.194165\",\"time_total\":\"13.195691\"}" + }, + { + "requestId": 3, + "startedAt": "2026-06-17T12:20:46.697Z", + "finishedAt": "2026-06-17T12:20:51.384Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.054108, + "starttransfer": 4.674913, + "total": 4.675079, + "ok": true, + "error": null, + "raw": "{\"requestId\":3,\"http_code\":\"200\",\"time_connect\":\"0.054108\",\"time_starttransfer\":\"4.674913\",\"time_total\":\"4.675079\"}" + }, + { + "requestId": 4, + "startedAt": "2026-06-17T12:20:46.698Z", + "finishedAt": "2026-06-17T12:20:51.363Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.026639, + "starttransfer": 4.65487, + "total": 4.654948, + "ok": true, + "error": null, + "raw": "{\"requestId\":4,\"http_code\":\"200\",\"time_connect\":\"0.026639\",\"time_starttransfer\":\"4.654870\",\"time_total\":\"4.654948\"}" + }, + { + "requestId": 5, + "startedAt": "2026-06-17T12:20:51.364Z", + "finishedAt": "2026-06-17T12:21:04.417Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.029047, + "starttransfer": 13.040307, + "total": 13.040461, + "ok": true, + "error": null, + "raw": "{\"requestId\":5,\"http_code\":\"200\",\"time_connect\":\"0.029047\",\"time_starttransfer\":\"13.040307\",\"time_total\":\"13.040461\"}" + }, + { + "requestId": 6, + "startedAt": "2026-06-17T12:20:51.382Z", + "finishedAt": "2026-06-17T12:20:53.380Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.024126, + "starttransfer": 1.985479, + "total": 1.985544, + "ok": true, + "error": null, + "raw": "{\"requestId\":6,\"http_code\":\"200\",\"time_connect\":\"0.024126\",\"time_starttransfer\":\"1.985479\",\"time_total\":\"1.985544\"}" + }, + { + "requestId": 7, + "startedAt": "2026-06-17T12:20:51.384Z", + "finishedAt": "2026-06-17T12:20:53.376Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.026343, + "starttransfer": 1.979602, + "total": 1.979694, + "ok": true, + "error": null, + "raw": "{\"requestId\":7,\"http_code\":\"200\",\"time_connect\":\"0.026343\",\"time_starttransfer\":\"1.979602\",\"time_total\":\"1.979694\"}" + }, + { + "requestId": 8, + "startedAt": "2026-06-17T12:20:53.376Z", + "finishedAt": "2026-06-17T12:21:04.451Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.025027, + "starttransfer": 11.06316, + "total": 11.063251, + "ok": true, + "error": null, + "raw": "{\"requestId\":8,\"http_code\":\"200\",\"time_connect\":\"0.025027\",\"time_starttransfer\":\"11.063160\",\"time_total\":\"11.063251\"}" + }, + { + "requestId": 9, + "startedAt": "2026-06-17T12:20:53.381Z", + "finishedAt": "2026-06-17T12:21:04.457Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.028518, + "starttransfer": 11.065208, + "total": 11.06534, + "ok": true, + "error": null, + "raw": "{\"requestId\":9,\"http_code\":\"200\",\"time_connect\":\"0.028518\",\"time_starttransfer\":\"11.065208\",\"time_total\":\"11.065340\"}" + }, + { + "requestId": 10, + "startedAt": "2026-06-17T12:20:59.901Z", + "finishedAt": "2026-06-17T12:21:04.603Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.025051, + "starttransfer": 4.67919, + "total": 4.681006, + "ok": true, + "error": null, + "raw": "{\"requestId\":10,\"http_code\":\"200\",\"time_connect\":\"0.025051\",\"time_starttransfer\":\"4.679190\",\"time_total\":\"4.681006\"}" + }, + { + "requestId": 11, + "startedAt": "2026-06-17T12:21:04.418Z", + "finishedAt": "2026-06-17T12:21:04.702Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.025346, + "starttransfer": 0.274303, + "total": 0.274385, + "ok": true, + "error": null, + "raw": "{\"requestId\":11,\"http_code\":\"200\",\"time_connect\":\"0.025346\",\"time_starttransfer\":\"0.274303\",\"time_total\":\"0.274385\"}" + }, + { + "requestId": 12, + "startedAt": "2026-06-17T12:21:04.451Z", + "finishedAt": "2026-06-17T12:21:04.729Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.022944, + "starttransfer": 0.268488, + "total": 0.268571, + "ok": true, + "error": null, + "raw": "{\"requestId\":12,\"http_code\":\"200\",\"time_connect\":\"0.022944\",\"time_starttransfer\":\"0.268488\",\"time_total\":\"0.268571\"}" + }, + { + "requestId": 13, + "startedAt": "2026-06-17T12:21:04.457Z", + "finishedAt": "2026-06-17T12:21:04.740Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.017853, + "starttransfer": 0.274702, + "total": 0.274742, + "ok": true, + "error": null, + "raw": "{\"requestId\":13,\"http_code\":\"200\",\"time_connect\":\"0.017853\",\"time_starttransfer\":\"0.274702\",\"time_total\":\"0.274742\"}" + }, + { + "requestId": 14, + "startedAt": "2026-06-17T12:21:04.603Z", + "finishedAt": "2026-06-17T12:21:04.893Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.02356, + "starttransfer": 0.274524, + "total": 0.274581, + "ok": true, + "error": null, + "raw": "{\"requestId\":14,\"http_code\":\"200\",\"time_connect\":\"0.023560\",\"time_starttransfer\":\"0.274524\",\"time_total\":\"0.274581\"}" + }, + { + "requestId": 15, + "startedAt": "2026-06-17T12:21:04.702Z", + "finishedAt": "2026-06-17T12:21:04.996Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.029294, + "starttransfer": 0.280106, + "total": 0.280314, + "ok": true, + "error": null, + "raw": "{\"requestId\":15,\"http_code\":\"200\",\"time_connect\":\"0.029294\",\"time_starttransfer\":\"0.280106\",\"time_total\":\"0.280314\"}" + }, + { + "requestId": 16, + "startedAt": "2026-06-17T12:21:04.729Z", + "finishedAt": "2026-06-17T12:21:05.012Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.042143, + "starttransfer": 0.274824, + "total": 0.274868, + "ok": true, + "error": null, + "raw": "{\"requestId\":16,\"http_code\":\"200\",\"time_connect\":\"0.042143\",\"time_starttransfer\":\"0.274824\",\"time_total\":\"0.274868\"}" + }, + { + "requestId": 17, + "startedAt": "2026-06-17T12:21:04.740Z", + "finishedAt": "2026-06-17T12:21:05.023Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.030134, + "starttransfer": 0.274291, + "total": 0.275352, + "ok": true, + "error": null, + "raw": "{\"requestId\":17,\"http_code\":\"200\",\"time_connect\":\"0.030134\",\"time_starttransfer\":\"0.274291\",\"time_total\":\"0.275352\"}" + }, + { + "requestId": 18, + "startedAt": "2026-06-17T12:21:04.893Z", + "finishedAt": "2026-06-17T12:21:05.161Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.021488, + "starttransfer": 0.256222, + "total": 0.256435, + "ok": true, + "error": null, + "raw": "{\"requestId\":18,\"http_code\":\"200\",\"time_connect\":\"0.021488\",\"time_starttransfer\":\"0.256222\",\"time_total\":\"0.256435\"}" + }, + { + "requestId": 19, + "startedAt": "2026-06-17T12:21:04.997Z", + "finishedAt": "2026-06-17T12:21:05.283Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.025852, + "starttransfer": 0.27099, + "total": 0.27111, + "ok": true, + "error": null, + "raw": "{\"requestId\":19,\"http_code\":\"200\",\"time_connect\":\"0.025852\",\"time_starttransfer\":\"0.270990\",\"time_total\":\"0.271110\"}" + }, + { + "requestId": 20, + "startedAt": "2026-06-17T12:21:05.012Z", + "finishedAt": "2026-06-17T12:21:05.306Z", + "exitCode": 0, + "httpCode": 200, + "connect": 0.028911, + "starttransfer": 0.285534, + "total": 0.285588, + "ok": true, + "error": null, + "raw": "{\"requestId\":20,\"http_code\":\"200\",\"time_connect\":\"0.028911\",\"time_starttransfer\":\"0.285534\",\"time_total\":\"0.285588\"}" + } + ] +} \ No newline at end of file diff --git a/database/test/output/20260617-202105-round3.tsv b/database/test/output/20260617-202105-round3.tsv new file mode 100644 index 0000000..85c020b --- /dev/null +++ b/database/test/output/20260617-202105-round3.tsv @@ -0,0 +1,21 @@ +requestId httpCode connect starttransfer total exitCode startedAt finishedAt error +1 200 0.027495 4.675778 4.675896 0 2026-06-17T12:20:46.694Z 2026-06-17T12:20:51.381Z +2 200 0.02423 13.194165 13.195691 0 2026-06-17T12:20:46.696Z 2026-06-17T12:20:59.901Z +3 200 0.054108 4.674913 4.675079 0 2026-06-17T12:20:46.697Z 2026-06-17T12:20:51.384Z +4 200 0.026639 4.65487 4.654948 0 2026-06-17T12:20:46.698Z 2026-06-17T12:20:51.363Z +5 200 0.029047 13.040307 13.040461 0 2026-06-17T12:20:51.364Z 2026-06-17T12:21:04.417Z +6 200 0.024126 1.985479 1.985544 0 2026-06-17T12:20:51.382Z 2026-06-17T12:20:53.380Z +7 200 0.026343 1.979602 1.979694 0 2026-06-17T12:20:51.384Z 2026-06-17T12:20:53.376Z +8 200 0.025027 11.06316 11.063251 0 2026-06-17T12:20:53.376Z 2026-06-17T12:21:04.451Z +9 200 0.028518 11.065208 11.06534 0 2026-06-17T12:20:53.381Z 2026-06-17T12:21:04.457Z +10 200 0.025051 4.67919 4.681006 0 2026-06-17T12:20:59.901Z 2026-06-17T12:21:04.603Z +11 200 0.025346 0.274303 0.274385 0 2026-06-17T12:21:04.418Z 2026-06-17T12:21:04.702Z +12 200 0.022944 0.268488 0.268571 0 2026-06-17T12:21:04.451Z 2026-06-17T12:21:04.729Z +13 200 0.017853 0.274702 0.274742 0 2026-06-17T12:21:04.457Z 2026-06-17T12:21:04.740Z +14 200 0.02356 0.274524 0.274581 0 2026-06-17T12:21:04.603Z 2026-06-17T12:21:04.893Z +15 200 0.029294 0.280106 0.280314 0 2026-06-17T12:21:04.702Z 2026-06-17T12:21:04.996Z +16 200 0.042143 0.274824 0.274868 0 2026-06-17T12:21:04.729Z 2026-06-17T12:21:05.012Z +17 200 0.030134 0.274291 0.275352 0 2026-06-17T12:21:04.740Z 2026-06-17T12:21:05.023Z +18 200 0.021488 0.256222 0.256435 0 2026-06-17T12:21:04.893Z 2026-06-17T12:21:05.161Z +19 200 0.025852 0.27099 0.27111 0 2026-06-17T12:21:04.997Z 2026-06-17T12:21:05.283Z +20 200 0.028911 0.285534 0.285588 0 2026-06-17T12:21:05.012Z 2026-06-17T12:21:05.306Z \ No newline at end of file diff --git a/lib/common/utils/discounts/discounts_tool.dart b/lib/common/utils/discounts/discounts_tool.dart index 62eea2e..b1bc2b8 100644 --- a/lib/common/utils/discounts/discounts_tool.dart +++ b/lib/common/utils/discounts/discounts_tool.dart @@ -1,8 +1,12 @@ +import 'dart:convert'; + import 'package:common_utils/common_utils.dart'; import 'package:get/get.dart'; import 'package:pj_supermarket_cloud/common/index.dart'; class DiscountsTool { + static final String TAG = "优惠券工具类"; + /// 更新用户优惠列表 static Future?> updateUserDiscountsList({ required String userId, @@ -20,8 +24,10 @@ class DiscountsTool { "userId": userId, "hardId": sysSetting.serviceId, }; + logger.i("$TAG更新用户优惠列表, params: $params"); final discountsRes = await WalletApi.getDiscountsListByUserId(params); - if (ObjectUtil.isEmpty(discountsRes)) return null; + if (ObjectUtil.isEmptyList(discountsRes)) return null; + logger.i("$TAG 更新用户优惠列表, res: ${jsonEncode(discountsRes)}"); // 查询用户表 final userEntity = await userDao.findByUserId(userId); if (ObjectUtil.isEmpty(userEntity)) return discountsRes; diff --git a/lib/common/utils/logger/logger_tool.dart b/lib/common/utils/logger/logger_tool.dart index 9716a52..b1e55a3 100644 --- a/lib/common/utils/logger/logger_tool.dart +++ b/lib/common/utils/logger/logger_tool.dart @@ -19,6 +19,7 @@ final customPrinter = PrettyPrinter( colors: true, printEmojis: false, printTime: true, + noBoxingByDefault: true, ); class AppLogFilter extends LogFilter { @@ -32,32 +33,44 @@ class ConsoleOutput extends LogOutput { String? _filePath; IOSink? _sink; Timer? _timer; + Future _queue = Future.value(); + + Future _enqueue(Future Function() action) { + _queue = _queue.then((_) => action()).catchError((e, stack) { + print("写入日志错误error:|$e|stack:|$stack|"); + }); + return _queue; + } @override Future init() async { try { - // 关闭旧的sink并创建新的 - await _sink?.flush(); - await _sink?.close(); - _filePath = await AppFileTool.getLoggerBackupPath(); - if (ObjectUtil.isNotEmpty(_filePath)) { - _sink = File(_filePath!).openWrite( - mode: FileMode.writeOnlyAppend, - encoding: utf8, - ); - } + await _enqueue(() async { + await _sink?.flush(); + await _sink?.close(); + _filePath = await AppFileTool.getLoggerBackupPath(); + if (ObjectUtil.isNotEmpty(_filePath)) { + _sink = File(_filePath!).openWrite( + mode: FileMode.writeOnlyAppend, + encoding: utf8, + ); + } else { + _sink = null; + } + }); _timer = Timer.periodic(const Duration(seconds: 60 * 60 * 2), (Timer timer) async { final path = await AppFileTool.getLoggerBackupPath(); if (path == null) return; - // 关闭旧的sink并创建新的 - await _sink?.flush(); - await _sink?.close(); - _filePath = path; - _sink = File(_filePath!).openWrite( - mode: FileMode.writeOnlyAppend, - encoding: utf8, - ); + unawaited(_enqueue(() async { + await _sink?.flush(); + await _sink?.close(); + _filePath = path; + _sink = File(_filePath!).openWrite( + mode: FileMode.writeOnlyAppend, + encoding: utf8, + ); + })); }); } catch (e, stack) { print("初始化日志错误error:|$e|stack:|$stack|"); @@ -66,9 +79,13 @@ class ConsoleOutput extends LogOutput { @override Future destroy() async { - await _sink?.flush(); - await _sink?.close(); _timer?.cancel(); + _timer = null; + await _enqueue(() async { + await _sink?.flush(); + await _sink?.close(); + _sink = null; + }); } @override @@ -79,11 +96,13 @@ class ConsoleOutput extends LogOutput { print(v); } } - if (_filePath == null || _sink == null) return; - if (Level.debug == event.level) return; - _sink!.writeAll(event.lines, '\n'); - _sink!.writeln(); - unawaited(_sink!.flush()); + unawaited(_enqueue(() async { + if (_filePath == null || _sink == null) return; + if (Level.debug == event.level) return; + _sink!.writeAll(event.lines, '\n'); + _sink!.writeln(); + await _sink!.flush(); + })); } catch (e, stack) { print("写入日志错误error:|$e|stack:|$stack|"); } diff --git a/lib/common/utils/manage/http_manage.dart b/lib/common/utils/manage/http_manage.dart index ca28c61..c31073e 100644 --- a/lib/common/utils/manage/http_manage.dart +++ b/lib/common/utils/manage/http_manage.dart @@ -12,6 +12,8 @@ const ignoreMsg = ["账号未登录"]; class HttpManage { static const _tag = "http管理"; + static const _requestStartAtKey = "_requestStartAt"; + static const _maxLogLength = 1000; static final HttpManage _instance = HttpManage._internal(); @@ -22,7 +24,12 @@ class HttpManage { HttpManage._internal() { BaseOptions globalOptions = BaseOptions( baseUrl: Constants.apiUrl, + // TCP/SSL 建连超时 connectTimeout: const Duration(seconds: 10), + // 请求体发送超时 + sendTimeout: const Duration(seconds: 10), + // 等待服务端返回数据超时 + receiveTimeout: const Duration(seconds: 10), responseType: ResponseType.json, ); dio = Dio(globalOptions); @@ -30,6 +37,7 @@ class HttpManage { dio.interceptors.add( InterceptorsWrapper( onRequest: (RequestOptions options, handler) async { + options.extra[_requestStartAtKey] = DateTime.now(); options.headers["CLIENT-TOC"] = "Y"; final userInfo = await AppSettingTool.getUserSetting(); if (!options.path.contains(Constants.oauth2AppApiUrl)) { @@ -39,6 +47,12 @@ class HttpManage { } } options.headers["TENANT-ID"] = userInfo.tenantId ?? 1; + logger.i( + "|$_tag|请求开始 method:${options.method} url:${options.uri} " + "query:${_formatLogData(options.queryParameters)} " + "body:${_formatLogData(options.data)}", + ); + logger.i("|$_tag|请求头 ${_formatLogData(options.headers)}"); return handler.next(options); }, onResponse: (e, handler) async { @@ -65,10 +79,21 @@ class HttpManage { if (!e.realUri.path.contains("refresh-token")) { // _refreshToken(); } + _logResponse( + options: e.requestOptions, + response: serviceData.data, + ); e.data = serviceData.data; handler.next(e); }, onError: (e, handler) async { + _logError(e); + if (e.type == DioExceptionType.connectionTimeout || + e.type == DioExceptionType.sendTimeout || + e.type == DioExceptionType.receiveTimeout) { + Toast.error(msg: "网络请求超时"); + EasyLoading.dismiss(); + } final response = e.response; final statusCode = response?.statusCode; if (statusCode != null) { @@ -167,4 +192,43 @@ class HttpManage { logger.e("|$_tag|续存token意外的错误error:|$e|"); } } + + void _logResponse({ + required RequestOptions options, + dynamic response, + }) { + final cost = _calcRequestCost(options); + logger.i( + "|$_tag|请求完成 method:${options.method} url:${options.uri} " + "cost:${cost}ms response:${_formatLogData(response)}", + ); + } + + void _logError(DioException error) { + final options = error.requestOptions; + final cost = _calcRequestCost(options); + logger.e( + "|$_tag|请求失败 method:${options.method} url:${options.uri} " + "cost:${cost}ms type:${error.type.name} " + "query:${_formatLogData(options.queryParameters)} " + "body:${_formatLogData(options.data)} " + "response:${_formatLogData(error.response?.data)} " + "error:${error.message}", + ); + } + + int _calcRequestCost(RequestOptions options) { + final startAt = options.extra[_requestStartAtKey]; + if (startAt is DateTime) { + return DateTime.now().difference(startAt).inMilliseconds; + } + return 0; + } + + String _formatLogData(dynamic data) { + if (data == null) return "null"; + final text = data.toString(); + if (text.length <= _maxLogLength) return text; + return "${text.substring(0, _maxLogLength)}...(已截断,原长度:${text.length})"; + } } diff --git a/lib/common/utils/sync/sync_check_tool.dart b/lib/common/utils/sync/sync_check_tool.dart index 10fb819..87710e7 100644 --- a/lib/common/utils/sync/sync_check_tool.dart +++ b/lib/common/utils/sync/sync_check_tool.dart @@ -1,4 +1,5 @@ import 'dart:async'; +import 'dart:io'; import 'package:get/get.dart'; import 'package:mqtt_client/mqtt_client.dart'; @@ -39,6 +40,7 @@ class SyncCheckTool { checkMq(); checkPrint(); checkBroadcast(); + checkExpiredLog(); } void dispose() { @@ -129,4 +131,54 @@ class SyncCheckTool { } }); } + + // 检查过期日志(超过3个月的日志文件都要删除) + checkExpiredLog() async { + const logMsg = "检查过期日志"; + try { + final backupPath = await AppFileTool.getLoggerBackupPath(); + if (backupPath == null || backupPath.isEmpty) { + logger.w("|$_tag|$logMsg,日志备份路径为空"); + return; + } + final loggerBackupDir = Directory(backupPath).parent.parent; + if (!await loggerBackupDir.exists()) { + logger.i("|$_tag|$logMsg,日志目录不存在 path:${loggerBackupDir.path}"); + return; + } + final expireBefore = DateTime( + DateTime.now().year, + DateTime.now().month - 3, + DateTime.now().day, + ); + final entities = loggerBackupDir.listSync(recursive: true); + int deleteCount = 0; + for (final entity in entities) { + if (entity is! File) continue; + if (!entity.path.endsWith(".log")) continue; + final stat = await entity.stat(); + if (stat.modified.isBefore(expireBefore)) { + await entity.delete(); + deleteCount++; + logger.i("|$_tag|$logMsg,删除过期日志 path:${entity.path}"); + } + } + final monthDirs = loggerBackupDir + .listSync() + .whereType() + .toList() + ..sort((a, b) => b.path.compareTo(a.path)); + for (final dir in monthDirs) { + if (!await dir.exists()) continue; + final isEmpty = dir.listSync().isEmpty; + if (isEmpty) { + await dir.delete(); + logger.i("|$_tag|$logMsg,删除空目录 path:${dir.path}"); + } + } + logger.i("|$_tag|$logMsg,执行完成,删除日志数量:$deleteCount"); + } catch (e, stack) { + logger.e("|$_tag|$logMsg,执行失败,error:$e,stack:$stack"); + } + } } diff --git a/lib/common/values/constants.dart b/lib/common/values/constants.dart index bfdf805..81b5d74 100644 --- a/lib/common/values/constants.dart +++ b/lib/common/values/constants.dart @@ -1,4 +1,11 @@ /// 常量 +enum LoginVersion { + // 不需要加密 + v1, + // 需要加密 + v2, +} + class Constants { // oauth2 APP模式客户端信息 static const oauth2AppClient = 'mini:mini'; @@ -28,4 +35,6 @@ class Constants { /// 设备唯一编码 static const deviceUniqueCode = 'EjFJx0WQ'; + + static const loginVersion = LoginVersion.v1; } diff --git a/lib/pages/panel/controller.dart b/lib/pages/panel/controller.dart index 5129c2a..d6d5530 100644 --- a/lib/pages/panel/controller.dart +++ b/lib/pages/panel/controller.dart @@ -21,7 +21,7 @@ class PanelController extends GetxController { PanelItem(title: "开卡管理", visible: true, type: PanelType.cardActive), PanelItem(title: "设置", visible: true, type: PanelType.setting), PanelItem(title: "退出登录", visible: true, type: PanelType.logout), - PanelItem(title: "测试", visible: true, type: PanelType.test), + // PanelItem(title: "测试", visible: true, type: PanelType.test), ].obs; final canteenMenus = [ diff --git a/lib/sub_screen/page/sub_product.dart b/lib/sub_screen/page/sub_product.dart index 3f1650f..1fb9b94 100644 --- a/lib/sub_screen/page/sub_product.dart +++ b/lib/sub_screen/page/sub_product.dart @@ -156,14 +156,14 @@ class _SubProductPageState extends State { ), ]; if (_sysType == SysType.CANTEEN) { - columns.insert( - 1, - DataColumn2( - label: Text("是否额外收费", textAlign: TextAlign.center), - headingRowAlignment: MainAxisAlignment.center, - fixedWidth: hdWidth, - ), - ); + // columns.insert( + // 1, + // DataColumn2( + // label: Text("是否额外收费", textAlign: TextAlign.center), + // headingRowAlignment: MainAxisAlignment.center, + // fixedWidth: hdWidth, + // ), + // ); } final rows = _shopList.map((v) { final cells = [ @@ -189,15 +189,15 @@ class _SubProductPageState extends State { ), ]; if (_sysType == SysType.CANTEEN) { - cells.insert( - 1, - DataCell( - Text( - v.isPriceIncreased ? "是" : "否", - textAlign: TextAlign.center, - ).center(), - ), - ); + // cells.insert( + // 1, + // DataCell( + // Text( + // v.isPriceIncreased ? "是" : "否", + // textAlign: TextAlign.center, + // ).center(), + // ), + // ); } return DataRow(cells: cells); });