Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Enhancement] Support move truncated old data to recycle bin #43107

Merged
merged 2 commits into from
Nov 28, 2024

Conversation

Vallishp
Copy link
Contributor

@Vallishp Vallishp commented Nov 1, 2024

What problem does this PR solve?

Added a new option for truncate table force.
if force is used then data will be deleted immediately.
if no force then data will be moved to recycle bin and use gets a chance to recover later if needed.

Issue Number: close #43104

Related PR: #xxx
NA
Problem Summary:

Check List (For Committer)

  • Test

    • [*] Regression test // added
    • Unit Test
    • Manual test (add detailed scripts or steps below)
    • No need to test or manual test. Explain why:
      • This is a refactor/code format and no logic has been changed.
      • Previous test can cover this change.
      • No colde files have been changed.
      • Other reason

mysql> use test;
Database changed
mysql> select * from test1;
+------+------+------------+
| id | name | da |
+------+------+------------+
| 1 | a | 2022-01-02 |
| 1 | a | 2022-01-02 |
+------+------+------------+
2 rows in set (0.03 sec)

mysql> show catalog recycle bin;
Empty set (0.02 sec)

mysql> truncate table test1 force;
Query OK, 0 rows affected (0.23 sec)

mysql> show catalog recycle bin;
Empty set (0.00 sec)

mysql> select * from test5;
+------+------+------------+
| id | name | da |
+------+------+------------+
| 2 | a | 2023-01-02 |
| 1 | a | 2022-01-02 |
| 1 | a | 2022-01-02 |
+------+------+------------+
3 rows in set (0.04 sec)

mysql> truncate table test5;
Query OK, 0 rows affected (0.10 sec)

mysql> show catalog recycle bin;
+-----------+------+-------+---------+-------------+---------------------+-----------+----------------+
| Type | Name | DbId | TableId | PartitionId | DropTime | DataSize | RemoteDataSize |
+-----------+------+-------+---------+-------------+---------------------+-----------+----------------+
| Partition | p3 | 10021 | 12023 | 12020 | 2024-11-01 13:07:25 | 1.307 KB | 0.000 |
| Partition | p4 | 10021 | 12023 | 12021 | 2024-11-01 13:07:25 | 667.000 B | 0.000 |
+-----------+------+-------+---------+-------------+---------------------+-----------+----------------+
2 rows in set (0.00 sec)

  • Behavior changed:

    • No.
    • [* ] Yes.
      After Truncate table, older version delete data directly. newer version old data will be moved to recycle bin
  • Does this need documentation?

    • No.
    • Yes.
  • Release note

    None

Check List (For Reviewer who merge this PR)

  • Confirm the release note
  • Confirm test cases
  • Confirm document
  • Add branch pick label

@doris-robot
Copy link

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR

Since 2024-03-18, the Document has been moved to doris-website.
See Doris Document.

@Vallishp
Copy link
Contributor Author

Vallishp commented Nov 1, 2024

run buildall

@doris-robot
Copy link

TPC-H: Total hot run time: 41673 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit 0b29c92f47071d6053cc4508e8117802bedb36fa, data reload: false

------ Round 1 ----------------------------------
q1	17608	7500	7365	7365
q2	2047	160	153	153
q3	10828	1083	1128	1083
q4	10556	832	832	832
q5	7738	3101	3109	3101
q6	237	150	149	149
q7	1015	607	602	602
q8	9353	1996	2068	1996
q9	6671	6445	6435	6435
q10	7135	2419	2402	2402
q11	461	258	252	252
q12	417	219	214	214
q13	17797	3034	2994	2994
q14	258	219	207	207
q15	586	522	513	513
q16	669	596	614	596
q17	987	585	576	576
q18	7215	6806	6806	6806
q19	1348	1003	992	992
q20	473	184	194	184
q21	4001	3225	3219	3219
q22	1134	1002	1042	1002
Total cold run time: 108534 ms
Total hot run time: 41673 ms

----- Round 2, with runtime_filter_mode=off -----
q1	7323	7287	7297	7287
q2	321	227	227	227
q3	3061	2975	3005	2975
q4	2101	1879	1868	1868
q5	5789	5785	5848	5785
q6	237	142	140	140
q7	2255	1804	1828	1804
q8	3409	3487	3556	3487
q9	8970	8897	8919	8897
q10	3574	3600	3564	3564
q11	600	503	513	503
q12	832	621	650	621
q13	9512	3205	3195	3195
q14	309	286	288	286
q15	582	534	524	524
q16	687	660	643	643
q17	1866	1641	1657	1641
q18	8410	7926	7717	7717
q19	1720	1608	1619	1608
q20	2132	1869	1918	1869
q21	5545	5277	5395	5277
q22	1143	1051	1078	1051
Total cold run time: 70378 ms
Total hot run time: 60969 ms

@doris-robot
Copy link

TPC-DS: Total hot run time: 196664 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit 0b29c92f47071d6053cc4508e8117802bedb36fa, data reload: false

query1	1184	919	888	888
query2	6234	2174	2139	2139
query3	10766	3968	4063	3968
query4	67132	29201	23649	23649
query5	4981	439	460	439
query6	390	188	173	173
query7	5628	291	283	283
query8	306	222	219	219
query9	9193	2760	2727	2727
query10	451	259	245	245
query11	17549	15297	15823	15297
query12	152	108	108	108
query13	1553	421	415	415
query14	10548	7206	7531	7206
query15	205	197	191	191
query16	7110	443	454	443
query17	1032	556	570	556
query18	1810	319	304	304
query19	189	154	147	147
query20	115	118	112	112
query21	207	98	100	98
query22	4739	4349	4585	4349
query23	34534	33916	34072	33916
query24	5979	2788	2730	2730
query25	504	385	407	385
query26	655	156	162	156
query27	1684	279	286	279
query28	3761	2424	2403	2403
query29	693	422	417	417
query30	237	154	155	154
query31	988	814	762	762
query32	63	55	54	54
query33	420	273	262	262
query34	914	508	508	508
query35	867	735	730	730
query36	1081	945	976	945
query37	119	79	73	73
query38	4340	4233	4193	4193
query39	1485	1405	1567	1405
query40	202	98	97	97
query41	47	44	47	44
query42	105	105	101	101
query43	556	521	516	516
query44	1236	826	826	826
query45	182	167	162	162
query46	1124	697	704	697
query47	1943	1854	1862	1854
query48	443	318	328	318
query49	742	401	388	388
query50	820	415	407	407
query51	7341	7177	7085	7085
query52	102	91	87	87
query53	267	181	178	178
query54	520	419	417	417
query55	78	76	75	75
query56	250	230	226	226
query57	1258	1150	1154	1150
query58	204	203	195	195
query59	3507	3302	3236	3236
query60	262	245	240	240
query61	103	100	106	100
query62	804	666	680	666
query63	219	193	182	182
query64	1369	632	612	612
query65	3257	3222	3221	3221
query66	742	309	302	302
query67	15989	15677	15710	15677
query68	3794	556	561	556
query69	405	247	250	247
query70	1176	1147	1146	1146
query71	340	248	257	248
query72	6221	4059	3972	3972
query73	764	353	351	351
query74	10059	9124	9075	9075
query75	3399	2676	2652	2652
query76	1815	1165	1161	1161
query77	493	272	264	264
query78	10360	9436	9435	9435
query79	1256	586	587	586
query80	846	415	424	415
query81	510	241	238	238
query82	1268	116	112	112
query83	157	138	143	138
query84	278	66	70	66
query85	816	291	290	290
query86	315	288	293	288
query87	4779	4731	4735	4731
query88	3599	2197	2187	2187
query89	411	294	288	288
query90	2025	191	188	188
query91	138	102	99	99
query92	64	49	46	46
query93	1793	547	530	530
query94	755	282	291	282
query95	341	251	248	248
query96	613	273	290	273
query97	2890	2701	2647	2647
query98	222	205	192	192
query99	1594	1332	1326	1326
Total cold run time: 316966 ms
Total hot run time: 196664 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 32.42 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 0b29c92f47071d6053cc4508e8117802bedb36fa, data reload: false

query1	0.04	0.03	0.02
query2	0.07	0.04	0.03
query3	0.23	0.06	0.06
query4	1.64	0.10	0.10
query5	0.42	0.40	0.41
query6	1.14	0.66	0.64
query7	0.02	0.01	0.02
query8	0.04	0.03	0.03
query9	0.57	0.50	0.49
query10	0.55	0.56	0.55
query11	0.14	0.10	0.10
query12	0.14	0.11	0.13
query13	0.60	0.60	0.59
query14	2.83	2.74	2.82
query15	0.90	0.83	0.83
query16	0.40	0.38	0.39
query17	0.98	1.05	1.05
query18	0.21	0.19	0.20
query19	1.96	1.81	1.94
query20	0.02	0.00	0.01
query21	15.36	0.57	0.58
query22	2.62	2.44	1.70
query23	17.04	1.02	0.83
query24	2.94	1.09	1.24
query25	0.30	0.04	0.23
query26	0.45	0.14	0.14
query27	0.04	0.05	0.04
query28	10.59	1.10	1.08
query29	12.61	3.26	3.24
query30	0.25	0.06	0.06
query31	2.85	0.39	0.38
query32	3.26	0.46	0.45
query33	2.96	2.98	3.03
query34	17.13	4.44	4.52
query35	4.51	4.56	4.48
query36	0.67	0.47	0.48
query37	0.09	0.06	0.06
query38	0.04	0.03	0.04
query39	0.04	0.02	0.02
query40	0.16	0.13	0.12
query41	0.07	0.02	0.02
query42	0.03	0.02	0.03
query43	0.04	0.03	0.03
Total cold run time: 106.95 s
Total hot run time: 32.42 s

@Vallishp
Copy link
Contributor Author

Vallishp commented Nov 2, 2024

run buildall

@doris-robot
Copy link

TPC-H: Total hot run time: 41504 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit cd197f854edbb4df9759080f0db57e11601695d3, data reload: false

------ Round 1 ----------------------------------
q1	17583	7385	7313	7313
q2	2043	162	155	155
q3	10577	1103	1195	1103
q4	10816	844	770	770
q5	7755	3014	3081	3014
q6	243	147	149	147
q7	1043	623	608	608
q8	9384	2024	2033	2024
q9	6804	6482	6550	6482
q10	7034	2468	2478	2468
q11	469	262	258	258
q12	411	216	203	203
q13	17833	3028	3036	3028
q14	247	211	209	209
q15	572	507	506	506
q16	661	587	575	575
q17	970	531	538	531
q18	7373	6779	6764	6764
q19	1331	961	957	957
q20	447	188	183	183
q21	4228	3141	3185	3141
q22	1162	1065	1078	1065
Total cold run time: 108986 ms
Total hot run time: 41504 ms

----- Round 2, with runtime_filter_mode=off -----
q1	7385	7489	7404	7404
q2	336	243	243	243
q3	3293	3134	3151	3134
q4	2193	1907	1912	1907
q5	5902	5930	5881	5881
q6	232	154	147	147
q7	2267	1797	1799	1797
q8	3392	3665	3573	3573
q9	8836	8928	8845	8845
q10	3590	3538	3572	3538
q11	623	498	525	498
q12	825	636	644	636
q13	14044	3200	3239	3200
q14	300	272	281	272
q15	570	520	522	520
q16	697	642	640	640
q17	1856	1647	1597	1597
q18	8440	7900	7524	7524
q19	1749	1642	1463	1463
q20	2134	1891	1833	1833
q21	5703	5470	5458	5458
q22	1217	1060	1031	1031
Total cold run time: 75584 ms
Total hot run time: 61141 ms

@doris-robot
Copy link

TPC-DS: Total hot run time: 196727 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit cd197f854edbb4df9759080f0db57e11601695d3, data reload: false

query1	1201	921	895	895
query2	6239	2178	2166	2166
query3	10781	4124	3922	3922
query4	67629	33975	24043	24043
query5	4876	452	439	439
query6	299	184	169	169
query7	4914	304	315	304
query8	291	229	220	220
query9	6511	2730	2717	2717
query10	403	257	241	241
query11	15718	15289	15737	15289
query12	151	102	102	102
query13	1036	430	422	422
query14	10495	7243	7532	7243
query15	211	194	185	185
query16	7067	483	466	466
query17	1036	560	569	560
query18	1840	295	285	285
query19	196	153	150	150
query20	118	117	111	111
query21	203	99	101	99
query22	4695	4471	4330	4330
query23	34439	34054	34382	34054
query24	6019	2783	2760	2760
query25	506	396	409	396
query26	652	158	155	155
query27	1696	283	290	283
query28	4039	2428	2431	2428
query29	685	425	420	420
query30	235	154	161	154
query31	979	796	841	796
query32	66	56	57	56
query33	456	272	270	270
query34	925	504	511	504
query35	873	750	736	736
query36	1063	930	975	930
query37	115	80	76	76
query38	4381	4212	4270	4212
query39	1472	1477	1423	1423
query40	205	98	98	98
query41	47	44	45	44
query42	110	96	102	96
query43	543	499	516	499
query44	1180	811	820	811
query45	178	164	168	164
query46	1117	695	695	695
query47	1934	1861	1900	1861
query48	408	326	322	322
query49	710	421	414	414
query50	811	376	390	376
query51	7299	7050	7108	7050
query52	98	86	83	83
query53	253	173	180	173
query54	510	411	398	398
query55	79	72	75	72
query56	236	229	234	229
query57	1276	1183	1169	1169
query58	210	200	201	200
query59	3201	3095	3109	3095
query60	264	248	247	247
query61	107	104	101	101
query62	809	666	675	666
query63	218	186	183	183
query64	1370	633	632	632
query65	3247	3219	3277	3219
query66	732	305	290	290
query67	16052	15764	15549	15549
query68	3646	583	580	580
query69	415	251	255	251
query70	1208	1127	1128	1127
query71	354	255	250	250
query72	6336	3991	3995	3991
query73	772	353	359	353
query74	10048	8950	9172	8950
query75	3421	2707	2673	2673
query76	1571	1150	1072	1072
query77	470	288	260	260
query78	10414	9410	9424	9410
query79	1854	578	580	578
query80	876	428	419	419
query81	522	236	241	236
query82	1308	117	111	111
query83	158	142	139	139
query84	277	69	64	64
query85	905	289	299	289
query86	332	292	310	292
query87	4882	4667	4789	4667
query88	3722	2176	2152	2152
query89	417	293	283	283
query90	2031	184	180	180
query91	133	99	100	99
query92	66	47	50	47
query93	2240	532	534	532
query94	840	297	292	292
query95	347	255	245	245
query96	621	271	281	271
query97	2931	2673	2704	2673
query98	209	199	198	198
query99	1795	1352	1296	1296
Total cold run time: 312836 ms
Total hot run time: 196727 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 32.88 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit cd197f854edbb4df9759080f0db57e11601695d3, data reload: false

query1	0.04	0.04	0.03
query2	0.06	0.04	0.03
query3	0.24	0.06	0.06
query4	1.64	0.10	0.10
query5	0.41	0.41	0.40
query6	1.13	0.65	0.64
query7	0.02	0.02	0.02
query8	0.04	0.03	0.03
query9	0.56	0.50	0.50
query10	0.55	0.55	0.56
query11	0.14	0.10	0.11
query12	0.14	0.10	0.10
query13	0.61	0.60	0.59
query14	2.74	2.74	2.83
query15	0.90	0.83	0.84
query16	0.38	0.37	0.38
query17	1.06	1.03	1.06
query18	0.20	0.19	0.20
query19	1.97	1.87	1.92
query20	0.02	0.02	0.01
query21	15.38	0.58	0.58
query22	2.62	2.42	1.67
query23	16.86	0.93	0.75
query24	3.12	1.55	1.48
query25	0.29	0.20	0.15
query26	0.45	0.14	0.14
query27	0.04	0.05	0.05
query28	9.71	1.11	1.07
query29	12.54	3.26	3.22
query30	0.25	0.05	0.06
query31	2.88	0.38	0.39
query32	3.26	0.46	0.46
query33	3.00	3.04	3.02
query34	17.03	4.44	4.45
query35	4.52	4.46	4.46
query36	0.68	0.47	0.49
query37	0.09	0.06	0.06
query38	0.04	0.03	0.04
query39	0.03	0.02	0.02
query40	0.17	0.12	0.12
query41	0.08	0.03	0.02
query42	0.03	0.02	0.03
query43	0.04	0.03	0.03
Total cold run time: 105.96 s
Total hot run time: 32.88 s

@Vallishp
Copy link
Contributor Author

Vallishp commented Nov 2, 2024

run buildall

@doris-robot
Copy link

TPC-H: Total hot run time: 41109 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit dffdb0d685643be548afa03abd575b310395e93c, data reload: false

------ Round 1 ----------------------------------
q1	17576	7338	7223	7223
q2	2049	185	158	158
q3	10772	1074	1193	1074
q4	10492	885	750	750
q5	7774	3058	3063	3058
q6	235	144	143	143
q7	1024	627	614	614
q8	9386	1953	1996	1953
q9	6671	6462	6441	6441
q10	7103	2398	2427	2398
q11	471	269	254	254
q12	405	217	207	207
q13	17775	2983	3006	2983
q14	242	209	206	206
q15	567	522	520	520
q16	665	596	582	582
q17	987	568	553	553
q18	7204	6698	6767	6698
q19	1338	999	1027	999
q20	467	182	184	182
q21	4028	3303	3091	3091
q22	1112	1023	1022	1022
Total cold run time: 108343 ms
Total hot run time: 41109 ms

----- Round 2, with runtime_filter_mode=off -----
q1	7291	7233	7211	7211
q2	318	228	224	224
q3	2977	2997	2976	2976
q4	2073	1911	1735	1735
q5	5771	5798	5791	5791
q6	228	145	139	139
q7	2263	1803	1776	1776
q8	3362	3527	3437	3437
q9	8924	8945	8855	8855
q10	3624	3545	3544	3544
q11	617	509	496	496
q12	835	606	639	606
q13	9524	3207	3174	3174
q14	323	268	273	268
q15	567	531	526	526
q16	716	637	673	637
q17	1871	1629	1615	1615
q18	8153	7930	7681	7681
q19	1696	1596	1488	1488
q20	2158	1840	1926	1840
q21	5649	5513	5515	5513
q22	1147	1072	1048	1048
Total cold run time: 70087 ms
Total hot run time: 60580 ms

@doris-robot
Copy link

TPC-DS: Total hot run time: 195175 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit dffdb0d685643be548afa03abd575b310395e93c, data reload: false

query1	1220	899	886	886
query2	6233	2170	2117	2117
query3	10769	4073	3964	3964
query4	67596	28854	23588	23588
query5	4913	444	428	428
query6	398	175	174	174
query7	5508	295	289	289
query8	317	228	222	222
query9	8765	2757	2731	2731
query10	455	257	241	241
query11	17323	15332	15866	15332
query12	152	99	98	98
query13	1550	430	433	430
query14	10469	7155	7182	7155
query15	213	186	187	186
query16	7033	472	505	472
query17	1027	559	564	559
query18	1774	294	297	294
query19	194	150	148	148
query20	122	113	110	110
query21	200	101	101	101
query22	4837	4568	4588	4568
query23	34516	34243	34130	34130
query24	6054	2746	2727	2727
query25	516	398	393	393
query26	644	161	156	156
query27	1662	286	280	280
query28	4075	2439	2432	2432
query29	686	421	428	421
query30	231	152	155	152
query31	980	793	837	793
query32	69	54	60	54
query33	391	269	295	269
query34	917	504	500	500
query35	856	733	743	733
query36	1061	931	975	931
query37	117	81	67	67
query38	4323	4210	4287	4210
query39	1469	1433	1444	1433
query40	203	99	98	98
query41	49	45	47	45
query42	107	98	94	94
query43	543	496	501	496
query44	1153	804	818	804
query45	185	172	164	164
query46	1125	695	683	683
query47	2001	1867	1921	1867
query48	424	312	315	312
query49	738	408	392	392
query50	809	398	390	390
query51	7299	7138	7200	7138
query52	98	87	87	87
query53	257	181	180	180
query54	524	407	417	407
query55	73	73	74	73
query56	256	227	238	227
query57	1301	1162	1168	1162
query58	204	193	202	193
query59	3378	3042	3222	3042
query60	265	242	241	241
query61	107	108	102	102
query62	804	658	681	658
query63	218	187	185	185
query64	1362	672	619	619
query65	3277	3198	3208	3198
query66	737	330	304	304
query67	16019	15670	15936	15670
query68	3952	575	559	559
query69	409	259	247	247
query70	1227	1122	1150	1122
query71	362	247	251	247
query72	6370	2534	3854	2534
query73	768	344	348	344
query74	10028	9074	9068	9068
query75	3398	2677	2675	2675
query76	1933	1055	1101	1055
query77	486	270	263	263
query78	10556	9468	9447	9447
query79	1277	578	575	575
query80	831	421	432	421
query81	531	239	243	239
query82	1315	116	117	116
query83	150	142	139	139
query84	281	67	65	65
query85	845	308	294	294
query86	336	273	284	273
query87	4775	4598	4742	4598
query88	3342	2178	2156	2156
query89	406	285	289	285
query90	1991	185	181	181
query91	136	101	101	101
query92	63	46	49	46
query93	1686	538	549	538
query94	760	282	292	282
query95	351	245	253	245
query96	624	274	283	274
query97	2890	2684	2727	2684
query98	215	203	202	202
query99	1613	1327	1295	1295
Total cold run time: 317058 ms
Total hot run time: 195175 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 32.05 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit dffdb0d685643be548afa03abd575b310395e93c, data reload: false

query1	0.04	0.04	0.03
query2	0.06	0.03	0.03
query3	0.23	0.06	0.07
query4	1.63	0.10	0.10
query5	0.43	0.42	0.41
query6	1.14	0.64	0.66
query7	0.01	0.03	0.02
query8	0.04	0.04	0.03
query9	0.56	0.49	0.50
query10	0.56	0.55	0.53
query11	0.14	0.10	0.10
query12	0.14	0.12	0.11
query13	0.62	0.59	0.60
query14	2.83	2.76	2.79
query15	0.90	0.83	0.82
query16	0.38	0.35	0.38
query17	1.00	1.05	1.01
query18	0.20	0.19	0.20
query19	1.86	1.82	1.92
query20	0.01	0.00	0.02
query21	15.37	0.59	0.56
query22	2.32	1.80	2.47
query23	17.04	1.09	0.88
query24	3.20	0.60	2.21
query25	0.31	0.20	0.04
query26	0.35	0.14	0.14
query27	0.04	0.05	0.03
query28	9.94	1.09	1.07
query29	12.56	3.25	3.23
query30	0.24	0.06	0.06
query31	2.86	0.38	0.38
query32	3.28	0.47	0.45
query33	2.96	3.07	3.05
query34	17.14	4.46	4.45
query35	4.52	4.44	4.54
query36	0.66	0.49	0.48
query37	0.09	0.06	0.05
query38	0.05	0.04	0.04
query39	0.03	0.02	0.03
query40	0.15	0.13	0.12
query41	0.08	0.02	0.02
query42	0.03	0.03	0.02
query43	0.03	0.03	0.03
Total cold run time: 106.03 s
Total hot run time: 32.05 s

}

public TableRef getTblRef() {
return tblRef;
}

public boolean isForceDrop() {
return forceDrop;
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

handle force in toSQL.

@Vallishp
Copy link
Contributor Author

Vallishp commented Nov 2, 2024

run buildall

@doris-robot
Copy link

TPC-H: Total hot run time: 41369 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit 3946ee4077f395e6f32af94e15e31f987a620c5a, data reload: false

------ Round 1 ----------------------------------
q1	17585	7463	7243	7243
q2	2050	179	165	165
q3	10556	1093	1163	1093
q4	10559	852	862	852
q5	7731	3055	3082	3055
q6	235	151	150	150
q7	1018	614	621	614
q8	9365	1951	2066	1951
q9	6550	6447	6446	6446
q10	7111	2394	2440	2394
q11	468	264	263	263
q12	415	218	211	211
q13	17769	3060	3093	3060
q14	238	207	209	207
q15	579	519	509	509
q16	679	582	576	576
q17	978	541	557	541
q18	7373	6684	6769	6684
q19	1344	979	998	979
q20	483	178	181	178
q21	4014	3203	3199	3199
q22	1143	1032	999	999
Total cold run time: 108243 ms
Total hot run time: 41369 ms

----- Round 2, with runtime_filter_mode=off -----
q1	7275	7207	7241	7207
q2	323	229	237	229
q3	2985	2923	2958	2923
q4	2100	1907	1773	1773
q5	5759	5771	5762	5762
q6	242	149	144	144
q7	2264	1835	1847	1835
q8	3386	3515	3469	3469
q9	8949	8907	8893	8893
q10	3595	3540	3592	3540
q11	602	504	520	504
q12	829	643	603	603
q13	11198	3179	3174	3174
q14	328	287	273	273
q15	573	512	519	512
q16	704	657	638	638
q17	1846	1632	1631	1631
q18	8368	7744	7533	7533
q19	1717	1563	1558	1558
q20	2147	1859	1914	1859
q21	5500	5252	5466	5252
q22	1170	1057	1096	1057
Total cold run time: 71860 ms
Total hot run time: 60369 ms

@doris-robot
Copy link

TPC-DS: Total hot run time: 196468 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit 3946ee4077f395e6f32af94e15e31f987a620c5a, data reload: false

query1	1187	923	910	910
query2	6230	2165	2035	2035
query3	10909	3963	4196	3963
query4	67792	28168	23559	23559
query5	4939	445	434	434
query6	397	174	169	169
query7	5491	301	295	295
query8	312	227	223	223
query9	8302	2757	2719	2719
query10	435	261	246	246
query11	17352	15222	15891	15222
query12	155	110	104	104
query13	1522	442	420	420
query14	10543	6917	7451	6917
query15	208	191	186	186
query16	7130	498	517	498
query17	1026	568	588	568
query18	1824	305	287	287
query19	201	156	150	150
query20	124	111	109	109
query21	200	100	98	98
query22	4463	4397	4419	4397
query23	34263	34091	34236	34091
query24	6020	2790	2748	2748
query25	514	400	411	400
query26	653	158	157	157
query27	1664	277	286	277
query28	4214	2438	2421	2421
query29	686	419	417	417
query30	234	156	159	156
query31	994	807	816	807
query32	66	55	57	55
query33	457	263	283	263
query34	906	512	501	501
query35	843	755	731	731
query36	1078	951	963	951
query37	117	74	73	73
query38	4411	4384	4226	4226
query39	1529	1424	1439	1424
query40	204	99	99	99
query41	46	51	45	45
query42	109	96	94	94
query43	542	496	503	496
query44	1144	809	822	809
query45	188	166	168	166
query46	1134	685	687	685
query47	1975	1886	1866	1866
query48	426	315	334	315
query49	725	409	419	409
query50	814	397	389	389
query51	7262	7139	7157	7139
query52	104	89	89	89
query53	256	182	177	177
query54	516	405	413	405
query55	74	73	75	73
query56	229	221	238	221
query57	1324	1207	1171	1171
query58	211	213	198	198
query59	3317	3054	3217	3054
query60	267	238	246	238
query61	109	104	101	101
query62	778	696	676	676
query63	213	183	184	183
query64	1337	623	601	601
query65	3265	3231	3219	3219
query66	708	295	294	294
query67	15887	15969	16040	15969
query68	3568	608	597	597
query69	422	267	247	247
query70	1237	1152	1138	1138
query71	358	272	246	246
query72	6361	4062	3964	3964
query73	759	347	348	347
query74	10151	9056	9055	9055
query75	3393	2682	2672	2672
query76	1842	1065	1014	1014
query77	480	276	257	257
query78	10437	9458	9390	9390
query79	1738	595	574	574
query80	1459	433	428	428
query81	543	238	241	238
query82	1287	122	115	115
query83	156	141	146	141
query84	285	72	76	72
query85	984	302	299	299
query86	402	301	311	301
query87	4886	4669	4777	4669
query88	3799	2188	2161	2161
query89	429	304	289	289
query90	2003	189	187	187
query91	140	101	100	100
query92	66	47	46	46
query93	2060	545	536	536
query94	852	274	280	274
query95	354	244	250	244
query96	621	281	274	274
query97	2926	2770	2703	2703
query98	214	204	187	187
query99	1614	1315	1329	1315
Total cold run time: 318381 ms
Total hot run time: 196468 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 32.11 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 3946ee4077f395e6f32af94e15e31f987a620c5a, data reload: false

query1	0.04	0.03	0.03
query2	0.07	0.02	0.04
query3	0.23	0.07	0.06
query4	1.63	0.10	0.10
query5	0.40	0.38	0.39
query6	1.16	0.65	0.65
query7	0.02	0.02	0.01
query8	0.04	0.03	0.04
query9	0.57	0.49	0.50
query10	0.56	0.54	0.55
query11	0.14	0.10	0.11
query12	0.14	0.11	0.11
query13	0.62	0.59	0.59
query14	2.87	2.72	2.73
query15	0.91	0.83	0.85
query16	0.38	0.38	0.38
query17	1.02	1.06	1.07
query18	0.20	0.20	0.20
query19	1.98	1.90	1.98
query20	0.02	0.01	0.01
query21	15.36	0.58	0.55
query22	2.58	2.98	1.14
query23	16.86	0.96	0.91
query24	2.76	1.03	1.20
query25	0.18	0.11	0.12
query26	0.56	0.14	0.14
query27	0.05	0.04	0.04
query28	10.79	1.10	1.07
query29	12.56	3.23	3.28
query30	0.24	0.07	0.05
query31	2.88	0.39	0.39
query32	3.26	0.46	0.44
query33	2.96	3.03	3.06
query34	16.96	4.51	4.50
query35	4.57	4.56	4.49
query36	0.68	0.49	0.51
query37	0.10	0.06	0.06
query38	0.05	0.03	0.03
query39	0.04	0.03	0.02
query40	0.16	0.13	0.12
query41	0.08	0.02	0.03
query42	0.04	0.02	0.02
query43	0.04	0.03	0.02
Total cold run time: 106.76 s
Total hot run time: 32.11 s

Copy link
Contributor

@dataroaring dataroaring left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add document in doris-website and add cases for empty partition, because there is an optimization for empty partition.

@@ -1196,6 +1196,75 @@ public Partition dropPartition(long dbId, String partitionName, boolean isForceD
return dropPartition(dbId, partitionName, isForceDrop, !isForceDrop);
}

public Partition dropPartitionForTruncate(long dbId, boolean isForceDrop,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OlapTable has a function dropPartition, its code seem much like this, can refactor code to reuse them ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thank you. i will refactor it

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, this had resolved

// 2. If "ifForceDrop" is true, the partition will be dropped immediately
Partition partition = recyclePartitionParam.partition;
if (partition != null) {
idToPartition.remove(partition.getId());
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need add nameToPartition.remove(partitionName), just like OlapTable.dropPartition function.

so refactor dropPartition and dropPartitionForTruncate to reuse code;

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

replacePartition had already removed old partition from nameToPartition and added new partition created by truncate process. so it should not be called in truncate process.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, this had resolved

truncateTableInternal(olapTable, info.getPartitions(), info.isEntireTable());

// add tablet to inverted index
TabletInvertedIndex invertedIndex = Env.getCurrentInvertedIndex();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this code is to add tablets meta of the new partitions to TabletInvertIndex.
why delete this code

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this code is to add tablets meta of the new partitions to TabletInvertIndex. why delete this code
Thanks. its adding the tabletInvertIndex for info.getPartitions() , which is old partitions. i think now it is not necessary to added.

i have tested like,

truncate table, restart FE , and check table content and recover table from recycle bin.
Any thing extra need to test?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

after truncating table, restart fe, have you check TabletInvertIndex contains all new tablets of this Table ?

In my options, line 3786 ~ 3806 should not delete. It's used to add new partitions's tablet meta into TabletInvertIndex.

You can see function InternalCatalog.replayAddPartition, it's doing the same things, for replaying the new partition, it should put its tablet meta into TabletInvertIndex.

@Vallishp
Copy link
Contributor Author

run buildall

1 similar comment
@Vallishp
Copy link
Contributor Author

run buildall

@Vallishp
Copy link
Contributor Author

run buildall

@doris-robot
Copy link

TPC-H: Total hot run time: 39821 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit 7addadd6bdd53e58663dcdbcc79543785de977b3, data reload: false

------ Round 1 ----------------------------------
q1	17841	7630	7319	7319
q2	2047	188	173	173
q3	10749	1094	1167	1094
q4	10332	759	724	724
q5	7616	2749	2736	2736
q6	238	147	149	147
q7	1000	640	597	597
q8	9231	1889	1948	1889
q9	6604	6400	6377	6377
q10	6964	2315	2331	2315
q11	474	265	260	260
q12	411	223	217	217
q13	17783	3011	3011	3011
q14	241	213	214	213
q15	563	530	507	507
q16	671	576	594	576
q17	993	549	603	549
q18	7236	6679	6705	6679
q19	1344	1028	871	871
q20	487	184	186	184
q21	4021	3243	3061	3061
q22	395	323	322	322
Total cold run time: 107241 ms
Total hot run time: 39821 ms

----- Round 2, with runtime_filter_mode=off -----
q1	7220	7239	7275	7239
q2	322	228	227	227
q3	2929	2804	2966	2804
q4	2048	1784	1817	1784
q5	5713	5681	5647	5647
q6	221	143	137	137
q7	2261	1813	1815	1813
q8	3385	3555	3546	3546
q9	8941	8804	8922	8804
q10	3600	3587	3583	3583
q11	597	497	493	493
q12	867	623	622	622
q13	11331	3361	3187	3187
q14	314	278	266	266
q15	582	509	524	509
q16	678	624	649	624
q17	1866	1636	1635	1635
q18	8393	7722	7647	7647
q19	1665	1543	1494	1494
q20	2146	1875	1895	1875
q21	5546	5420	5364	5364
q22	658	592	567	567
Total cold run time: 71283 ms
Total hot run time: 59867 ms

@doris-robot
Copy link

TPC-DS: Total hot run time: 196996 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit 7addadd6bdd53e58663dcdbcc79543785de977b3, data reload: false

query1	1274	918	921	918
query2	6254	2068	2050	2050
query3	10801	4157	4015	4015
query4	67910	29064	23511	23511
query5	4950	460	446	446
query6	411	192	180	180
query7	5455	307	295	295
query8	314	229	240	229
query9	8620	2767	2749	2749
query10	443	252	266	252
query11	17240	15082	15806	15082
query12	154	105	104	104
query13	1464	434	418	418
query14	11001	7577	7377	7377
query15	202	187	197	187
query16	6732	438	458	438
query17	1364	576	585	576
query18	1693	310	291	291
query19	195	161	150	150
query20	119	111	113	111
query21	205	103	102	102
query22	4717	4674	4703	4674
query23	34763	34055	34279	34055
query24	5476	2519	2448	2448
query25	532	443	419	419
query26	664	158	152	152
query27	1728	298	304	298
query28	4584	2518	2505	2505
query29	698	439	446	439
query30	215	157	153	153
query31	1012	849	847	847
query32	63	54	59	54
query33	403	288	280	280
query34	919	503	513	503
query35	835	742	756	742
query36	1104	982	981	981
query37	125	78	114	78
query38	4486	4508	4471	4471
query39	1542	1473	1470	1470
query40	201	98	109	98
query41	45	41	47	41
query42	109	99	101	99
query43	544	505	496	496
query44	1185	839	843	839
query45	187	169	170	169
query46	1146	697	705	697
query47	2046	1891	1936	1891
query48	423	314	330	314
query49	753	392	392	392
query50	846	391	393	391
query51	7304	7196	7053	7053
query52	97	89	86	86
query53	259	177	173	173
query54	499	397	403	397
query55	78	75	77	75
query56	253	236	234	234
query57	1270	1159	1122	1122
query58	223	215	215	215
query59	3237	3086	3000	3000
query60	267	251	244	244
query61	106	108	107	107
query62	786	679	673	673
query63	209	186	195	186
query64	1368	671	640	640
query65	3277	3228	3212	3212
query66	710	303	312	303
query67	15939	15720	15775	15720
query68	4059	554	554	554
query69	441	251	257	251
query70	1232	1129	1152	1129
query71	374	244	248	244
query72	6320	4033	4063	4033
query73	751	364	365	364
query74	10225	9188	9001	9001
query75	3400	2701	2667	2667
query76	1805	1106	1015	1015
query77	486	277	262	262
query78	10565	9482	9649	9482
query79	2484	589	616	589
query80	1444	429	420	420
query81	540	335	229	229
query82	1318	118	116	116
query83	273	149	141	141
query84	279	79	72	72
query85	1027	309	297	297
query86	439	291	293	291
query87	4775	4607	4533	4533
query88	3588	2243	2216	2216
query89	430	293	306	293
query90	1953	190	211	190
query91	137	104	100	100
query92	75	49	46	46
query93	2964	547	543	543
query94	780	298	303	298
query95	348	247	253	247
query96	636	283	282	282
query97	2856	2713	2668	2668
query98	223	199	192	192
query99	1882	1334	1314	1314
Total cold run time: 322143 ms
Total hot run time: 196996 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 33.3 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 7addadd6bdd53e58663dcdbcc79543785de977b3, data reload: false

query1	0.03	0.03	0.04
query2	0.06	0.04	0.03
query3	0.23	0.07	0.07
query4	1.62	0.10	0.11
query5	0.41	0.43	0.41
query6	1.14	0.66	0.66
query7	0.02	0.02	0.02
query8	0.04	0.03	0.04
query9	0.58	0.50	0.50
query10	0.55	0.56	0.56
query11	0.14	0.10	0.11
query12	0.15	0.12	0.12
query13	0.61	0.60	0.59
query14	2.83	2.73	2.86
query15	0.90	0.83	0.82
query16	0.38	0.39	0.39
query17	1.07	1.07	1.03
query18	0.22	0.22	0.21
query19	1.94	1.90	2.00
query20	0.02	0.01	0.01
query21	15.37	0.59	0.58
query22	2.59	1.69	2.26
query23	16.86	0.88	0.91
query24	2.92	1.53	1.68
query25	0.25	0.17	0.31
query26	0.41	0.13	0.14
query27	0.04	0.04	0.04
query28	9.77	1.11	1.08
query29	12.55	3.24	3.25
query30	0.25	0.06	0.06
query31	2.85	0.38	0.38
query32	3.27	0.46	0.47
query33	3.18	3.05	3.11
query34	17.12	4.44	4.46
query35	4.56	4.48	4.48
query36	0.67	0.48	0.48
query37	0.09	0.06	0.06
query38	0.04	0.03	0.04
query39	0.04	0.02	0.02
query40	0.16	0.12	0.13
query41	0.08	0.03	0.02
query42	0.03	0.02	0.03
query43	0.03	0.03	0.03
Total cold run time: 106.07 s
Total hot run time: 33.3 s

@Vallishp
Copy link
Contributor Author

run buildall

@doris-robot
Copy link

TPC-H: Total hot run time: 39925 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit d916a66c1d8460da0465c07c4ab0c0e210f372dc, data reload: false

------ Round 1 ----------------------------------
q1	17637	7571	7254	7254
q2	2043	177	166	166
q3	10558	1146	1161	1146
q4	10233	736	724	724
q5	7611	2791	2649	2649
q6	238	147	150	147
q7	992	604	596	596
q8	9252	1875	1935	1875
q9	6572	6430	6427	6427
q10	6960	2285	2303	2285
q11	469	263	248	248
q12	414	212	208	208
q13	17766	3051	3012	3012
q14	252	211	214	211
q15	566	530	503	503
q16	642	605	586	586
q17	983	595	538	538
q18	7584	6748	6755	6748
q19	1351	1055	985	985
q20	489	189	186	186
q21	4136	3164	3126	3126
q22	382	316	305	305
Total cold run time: 107130 ms
Total hot run time: 39925 ms

----- Round 2, with runtime_filter_mode=off -----
q1	7218	7254	7255	7254
q2	328	229	230	229
q3	2904	2873	2856	2856
q4	1946	1704	1670	1670
q5	5419	5437	5479	5437
q6	220	138	139	138
q7	2153	1720	1752	1720
q8	3273	3439	3401	3401
q9	8527	8570	8526	8526
q10	3534	3469	3414	3414
q11	597	502	498	498
q12	823	576	572	572
q13	12157	3024	3015	3015
q14	291	260	262	260
q15	563	511	525	511
q16	673	627	623	623
q17	1821	1612	1575	1575
q18	7750	7537	7449	7449
q19	1696	1599	1552	1552
q20	2062	1809	1782	1782
q21	5403	5155	5047	5047
q22	639	531	527	527
Total cold run time: 69997 ms
Total hot run time: 58056 ms

dataroaring
dataroaring previously approved these changes Nov 26, 2024
Copy link
Contributor

@dataroaring dataroaring left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@github-actions github-actions bot added the approved Indicates a PR has been approved by one committer. label Nov 26, 2024
Copy link
Contributor

PR approved by at least one committer and no changes requested.

@doris-robot
Copy link

TPC-DS: Total hot run time: 191583 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit d916a66c1d8460da0465c07c4ab0c0e210f372dc, data reload: false

query1	978	387	362	362
query2	6520	2096	2033	2033
query3	6706	211	216	211
query4	34181	23591	23666	23591
query5	4393	466	470	466
query6	284	188	177	177
query7	4615	295	302	295
query8	302	234	225	225
query9	9667	2660	2648	2648
query10	479	257	259	257
query11	18199	15337	15377	15337
query12	161	99	100	99
query13	1640	399	390	390
query14	10816	7508	7189	7189
query15	281	171	183	171
query16	7928	443	472	443
query17	1806	559	548	548
query18	2096	288	300	288
query19	362	146	145	145
query20	115	108	106	106
query21	209	102	113	102
query22	4443	4235	4228	4228
query23	35679	34752	34247	34247
query24	11278	2354	2410	2354
query25	544	410	408	408
query26	1248	160	160	160
query27	2695	284	287	284
query28	7626	2454	2448	2448
query29	672	434	435	434
query30	306	152	152	152
query31	1035	820	838	820
query32	98	60	63	60
query33	787	305	288	288
query34	928	495	515	495
query35	862	705	727	705
query36	1124	956	975	956
query37	130	85	118	85
query38	4352	4234	4192	4192
query39	1496	1424	1433	1424
query40	282	102	100	100
query41	44	45	43	43
query42	111	98	102	98
query43	548	499	490	490
query44	1255	815	820	815
query45	188	164	169	164
query46	1148	701	689	689
query47	1932	1792	1812	1792
query48	408	324	317	317
query49	1250	425	384	384
query50	812	387	391	387
query51	7335	7095	7035	7035
query52	103	92	89	89
query53	252	178	181	178
query54	1129	417	408	408
query55	88	75	75	75
query56	259	238	246	238
query57	1289	1150	1158	1150
query58	243	217	223	217
query59	3226	3252	3064	3064
query60	261	250	248	248
query61	130	107	111	107
query62	919	666	659	659
query63	221	187	190	187
query64	5221	659	630	630
query65	3309	3245	3296	3245
query66	1303	360	309	309
query67	16116	15887	15574	15574
query68	4996	564	556	556
query69	449	259	251	251
query70	1189	1128	1165	1128
query71	392	247	248	247
query72	6096	4111	4015	4015
query73	748	353	362	353
query74	10536	9029	9108	9029
query75	3457	2661	2665	2661
query76	3038	1125	1077	1077
query77	529	268	269	268
query78	10402	9416	9469	9416
query79	1592	587	604	587
query80	717	446	422	422
query81	503	239	232	232
query82	616	120	123	120
query83	170	146	148	146
query84	239	69	70	69
query85	1596	298	305	298
query86	449	310	312	310
query87	4790	4609	4551	4551
query88	3964	2197	2133	2133
query89	415	313	296	296
query90	2146	187	186	186
query91	139	104	102	102
query92	65	51	51	51
query93	1507	546	556	546
query94	954	285	270	270
query95	358	266	257	257
query96	624	286	279	279
query97	2906	2717	2708	2708
query98	210	190	203	190
query99	1553	1345	1314	1314
Total cold run time: 303768 ms
Total hot run time: 191583 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 32.55 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit d916a66c1d8460da0465c07c4ab0c0e210f372dc, data reload: false

query1	0.03	0.03	0.03
query2	0.06	0.04	0.03
query3	0.23	0.08	0.07
query4	1.63	0.10	0.10
query5	0.42	0.40	0.41
query6	1.14	0.67	0.65
query7	0.02	0.01	0.02
query8	0.04	0.03	0.03
query9	0.58	0.53	0.51
query10	0.56	0.56	0.56
query11	0.15	0.12	0.10
query12	0.14	0.11	0.11
query13	0.61	0.61	0.60
query14	2.72	2.75	2.74
query15	0.90	0.82	0.82
query16	0.40	0.37	0.38
query17	1.07	1.08	1.08
query18	0.23	0.21	0.21
query19	1.99	1.90	2.07
query20	0.02	0.01	0.01
query21	15.36	0.60	0.60
query22	2.67	2.50	1.58
query23	17.32	0.89	0.82
query24	2.74	1.67	0.92
query25	0.18	0.06	0.17
query26	0.48	0.13	0.14
query27	0.05	0.04	0.04
query28	10.47	1.09	1.07
query29	12.52	3.26	3.24
query30	0.25	0.06	0.06
query31	2.86	0.38	0.38
query32	3.29	0.47	0.46
query33	3.01	3.08	3.11
query34	17.04	4.50	4.50
query35	4.53	4.49	4.54
query36	0.71	0.50	0.49
query37	0.09	0.06	0.06
query38	0.04	0.04	0.03
query39	0.03	0.02	0.03
query40	0.16	0.13	0.13
query41	0.08	0.02	0.02
query42	0.04	0.02	0.02
query43	0.04	0.03	0.02
Total cold run time: 106.9 s
Total hot run time: 32.55 s

@Vallishp
Copy link
Contributor Author

run p0

1 similar comment
@Vallishp
Copy link
Contributor Author

run p0

@Vallishp
Copy link
Contributor Author

run buildall

@github-actions github-actions bot removed the approved Indicates a PR has been approved by one committer. label Nov 27, 2024
@doris-robot
Copy link

TPC-H: Total hot run time: 39678 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit 65b69a870f0bcf2d0b6b742dc0d8a8915a305e87, data reload: false

------ Round 1 ----------------------------------
q1	17602	7430	7262	7262
q2	2041	172	167	167
q3	10713	1083	1175	1083
q4	10522	711	773	711
q5	7585	2734	2759	2734
q6	242	147	150	147
q7	989	638	597	597
q8	9236	1889	1929	1889
q9	6577	6442	6335	6335
q10	7011	2314	2298	2298
q11	475	252	262	252
q12	420	220	215	215
q13	17779	3024	3020	3020
q14	248	208	207	207
q15	580	526	525	525
q16	656	570	578	570
q17	973	580	543	543
q18	7176	6590	6672	6590
q19	1354	1019	918	918
q20	491	187	177	177
q21	3977	3215	3121	3121
q22	379	320	317	317
Total cold run time: 107026 ms
Total hot run time: 39678 ms

----- Round 2, with runtime_filter_mode=off -----
q1	7283	7255	7621	7255
q2	325	230	227	227
q3	2902	2819	2949	2819
q4	2039	1766	1836	1766
q5	5702	5687	5648	5648
q6	221	141	139	139
q7	2247	1805	1796	1796
q8	3430	3598	3493	3493
q9	8899	8924	8951	8924
q10	3629	3547	3605	3547
q11	592	527	505	505
q12	818	612	676	612
q13	12686	3269	3170	3170
q14	315	281	278	278
q15	584	528	535	528
q16	710	635	664	635
q17	1867	1642	1609	1609
q18	8284	7691	7844	7691
q19	1791	1597	1518	1518
q20	2123	1880	1856	1856
q21	5631	5479	5346	5346
q22	645	579	626	579
Total cold run time: 72723 ms
Total hot run time: 59941 ms

@doris-robot
Copy link

TPC-DS: Total hot run time: 198474 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit 65b69a870f0bcf2d0b6b742dc0d8a8915a305e87, data reload: false

query1	1263	962	974	962
query2	6261	2199	2160	2160
query3	10906	4177	4131	4131
query4	67680	28860	23790	23790
query5	4983	482	457	457
query6	405	199	211	199
query7	5482	315	287	287
query8	314	233	228	228
query9	8691	2712	2699	2699
query10	471	264	252	252
query11	17362	15432	16020	15432
query12	144	100	104	100
query13	1442	436	412	412
query14	10695	7601	7722	7601
query15	216	195	210	195
query16	7764	474	478	474
query17	1070	563	561	561
query18	1866	292	286	286
query19	210	150	154	150
query20	123	112	125	112
query21	205	101	98	98
query22	4900	4398	4395	4395
query23	35360	34557	34530	34530
query24	5584	2443	2511	2443
query25	527	413	434	413
query26	653	155	158	155
query27	1768	297	291	291
query28	4562	2492	2465	2465
query29	709	445	420	420
query30	223	145	143	143
query31	1002	829	851	829
query32	66	57	60	57
query33	418	293	285	285
query34	939	527	496	496
query35	861	777	804	777
query36	1101	975	994	975
query37	128	82	78	78
query38	4456	4361	4532	4361
query39	1537	1500	1460	1460
query40	208	101	101	101
query41	47	42	43	42
query42	106	98	97	97
query43	557	523	504	504
query44	1210	838	834	834
query45	204	181	170	170
query46	1136	698	697	697
query47	2028	1941	1921	1921
query48	428	323	335	323
query49	721	418	390	390
query50	866	404	431	404
query51	7446	7176	7156	7156
query52	96	89	93	89
query53	264	195	186	186
query54	536	414	426	414
query55	82	73	77	73
query56	268	260	258	258
query57	1330	1184	1155	1155
query58	260	219	212	212
query59	3311	3205	3003	3003
query60	267	247	251	247
query61	107	105	109	105
query62	797	665	677	665
query63	213	190	193	190
query64	1379	670	666	666
query65	3347	3215	3246	3215
query66	698	301	313	301
query67	16030	15737	15665	15665
query68	4054	551	569	551
query69	426	256	254	254
query70	1159	1160	1034	1034
query71	356	250	247	247
query72	6379	4115	3996	3996
query73	797	361	363	361
query74	10394	9124	9114	9114
query75	3408	2666	2690	2666
query76	1787	1108	1103	1103
query77	518	272	293	272
query78	10555	9476	9390	9390
query79	1612	603	605	603
query80	1094	438	527	438
query81	542	237	243	237
query82	244	125	118	118
query83	180	162	156	156
query84	283	81	71	71
query85	994	307	306	306
query86	401	273	299	273
query87	4848	4672	4654	4654
query88	3662	2232	2259	2232
query89	427	301	286	286
query90	2006	187	194	187
query91	142	107	104	104
query92	65	50	53	50
query93	2366	537	537	537
query94	855	289	319	289
query95	357	249	250	249
query96	620	287	281	281
query97	2856	2691	2664	2664
query98	214	192	200	192
query99	1628	1326	1317	1317
Total cold run time: 321518 ms
Total hot run time: 198474 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 33.04 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 65b69a870f0bcf2d0b6b742dc0d8a8915a305e87, data reload: false

query1	0.03	0.03	0.03
query2	0.07	0.03	0.04
query3	0.23	0.07	0.07
query4	1.61	0.10	0.10
query5	0.46	0.41	0.41
query6	1.13	0.67	0.66
query7	0.02	0.02	0.01
query8	0.05	0.03	0.03
query9	0.57	0.53	0.51
query10	0.55	0.55	0.56
query11	0.14	0.11	0.11
query12	0.14	0.11	0.11
query13	0.63	0.60	0.60
query14	2.80	2.82	2.72
query15	0.91	0.84	0.83
query16	0.40	0.38	0.38
query17	1.04	1.06	1.05
query18	0.23	0.21	0.21
query19	1.88	1.81	2.02
query20	0.01	0.01	0.01
query21	15.37	0.59	0.58
query22	2.48	1.93	2.37
query23	17.11	0.92	0.87
query24	3.17	1.27	1.38
query25	0.25	0.11	0.04
query26	0.52	0.14	0.14
query27	0.04	0.05	0.05
query28	10.32	1.10	1.07
query29	12.61	3.29	3.24
query30	0.25	0.07	0.06
query31	2.87	0.39	0.38
query32	3.25	0.46	0.47
query33	2.96	3.03	3.06
query34	17.12	4.43	4.45
query35	4.56	4.50	4.48
query36	0.68	0.50	0.48
query37	0.08	0.06	0.06
query38	0.05	0.03	0.03
query39	0.03	0.02	0.03
query40	0.15	0.12	0.12
query41	0.07	0.02	0.02
query42	0.03	0.02	0.02
query43	0.03	0.04	0.03
Total cold run time: 106.9 s
Total hot run time: 33.04 s

Copy link
Contributor

@dataroaring dataroaring left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@github-actions github-actions bot added the approved Indicates a PR has been approved by one committer. label Nov 28, 2024
Copy link
Contributor

PR approved by at least one committer and no changes requested.

@dataroaring dataroaring merged commit 47a7414 into apache:master Nov 28, 2024
23 of 24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by one committer. dev/3.0.x kind/behavior-changed reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Enhancement] Support move truncated old data to recycle bin
4 participants