doris icon indicating copy to clipboard operation
doris copied to clipboard

[feature](restapi) add broker operate rest api, including ADD/DROP/DROP_ALL

Open heguanhui opened this issue 5 months ago • 2 comments

What problem does this PR solve?

This PR introduces REST APIs for scaling the broker cluster, including ADD, DROP, and DROP_ALL, which are fully compatible with SQL commands. This resolves the limitation of performing scaling operations exclusively through SQL.

Problem Summary:

Currently, scaling operations for the broker in Doris can only be performed via SQL commands, which imposes limitations on usage methods and restricts users in certain scenarios.

Check List (For Author)

- [ ] Manual test (add detailed scripts or steps below)

broker扩缩容.docx

  • Behavior changed:

    • [ ] No.
  • Does this need documentation?

    • [ ] Yes.

heguanhui avatar Jun 16 '25 03:06 heguanhui

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

Please clearly describe your PR:

  1. What problem was fixed (it's best to include specific error reporting information). How it was fixed.
  2. Which behaviors were modified. What was the previous behavior, what is it now, why was it modified, and what possible impacts might there be.
  3. What features were added. Why was this function added?
  4. Which code was refactored and why was this part of the code refactored?
  5. Which functions were optimized and what is the difference before and after the optimization?

hello-stephen avatar Jun 16 '25 03:06 hello-stephen

run buildall

morningman avatar Jun 18 '25 12:06 morningman

run buildall

morningman avatar Jun 20 '25 05:06 morningman

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

------ Round 1 ----------------------------------
q1	17578	5118	5068	5068
q2	1942	286	197	197
q3	10291	1383	740	740
q4	10226	1034	516	516
q5	7551	2370	2400	2370
q6	182	166	134	134
q7	938	761	615	615
q8	9331	1510	1104	1104
q9	6745	5091	5148	5091
q10	6904	2390	1954	1954
q11	515	290	279	279
q12	344	351	217	217
q13	17784	3719	3173	3173
q14	243	225	213	213
q15	566	483	492	483
q16	426	428	380	380
q17	633	870	395	395
q18	7873	7342	7117	7117
q19	1231	935	553	553
q20	355	346	228	228
q21	4003	3191	2413	2413
q22	1058	1014	972	972
Total cold run time: 106719 ms
Total hot run time: 34212 ms

----- Round 2, with runtime_filter_mode=off -----
q1	5139	5082	5445	5082
q2	246	335	219	219
q3	2125	2680	2325	2325
q4	1389	1839	1344	1344
q5	4210	4131	4145	4131
q6	209	161	122	122
q7	1922	1834	1654	1654
q8	2625	2450	2381	2381
q9	6832	6738	6765	6738
q10	2952	3157	2732	2732
q11	568	500	497	497
q12	636	726	588	588
q13	3335	3743	3123	3123
q14	279	282	264	264
q15	530	471	461	461
q16	432	477	429	429
q17	1111	1466	1285	1285
q18	7282	7262	7106	7106
q19	797	805	895	805
q20	1910	1954	1873	1873
q21	4753	4347	4263	4263
q22	1072	1048	1022	1022
Total cold run time: 50354 ms
Total hot run time: 48444 ms

doris-robot avatar Jun 20 '25 06:06 doris-robot

TPC-DS: Total hot run time: 186004 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 424f9dc1ea2fc2b04a23f144f93e5f11e8654f56, data reload: false

query1	999	396	403	396
query2	6533	1866	1857	1857
query3	6753	221	219	219
query4	26275	23964	23448	23448
query5	5765	660	482	482
query6	328	230	214	214
query7	4635	503	298	298
query8	279	239	212	212
query9	8638	2641	2662	2641
query10	532	341	282	282
query11	15419	15061	14816	14816
query12	167	119	110	110
query13	1665	542	404	404
query14	10918	6268	6269	6268
query15	254	209	182	182
query16	7761	629	475	475
query17	1559	763	607	607
query18	2049	417	333	333
query19	286	197	177	177
query20	124	120	129	120
query21	225	131	115	115
query22	4111	4240	4077	4077
query23	34013	33082	33008	33008
query24	8070	2365	2392	2365
query25	505	472	402	402
query26	1224	284	151	151
query27	2684	506	351	351
query28	4283	2116	2108	2108
query29	726	564	446	446
query30	291	221	197	197
query31	941	848	748	748
query32	78	65	67	65
query33	565	370	308	308
query34	824	858	537	537
query35	801	853	723	723
query36	937	992	898	898
query37	121	99	77	77
query38	4111	4097	4072	4072
query39	1480	1448	1386	1386
query40	214	120	109	109
query41	65	61	57	57
query42	122	110	113	110
query43	504	524	484	484
query44	1371	842	846	842
query45	185	183	167	167
query46	868	1031	627	627
query47	1720	1801	1697	1697
query48	383	424	321	321
query49	733	483	383	383
query50	687	669	414	414
query51	4119	4121	4136	4121
query52	111	109	104	104
query53	239	260	184	184
query54	589	582	501	501
query55	88	87	92	87
query56	305	335	281	281
query57	1156	1205	1100	1100
query58	271	266	265	265
query59	2588	2753	2635	2635
query60	330	338	300	300
query61	129	122	128	122
query62	772	715	672	672
query63	234	193	187	187
query64	4232	1006	666	666
query65	4315	4147	4179	4147
query66	1010	417	341	341
query67	15804	15680	15322	15322
query68	8309	916	532	532
query69	513	307	274	274
query70	1208	1149	1099	1099
query71	504	329	320	320
query72	5280	4639	4566	4566
query73	689	572	355	355
query74	8952	9125	8754	8754
query75	4003	3214	2709	2709
query76	3784	1206	792	792
query77	800	397	291	291
query78	10057	10201	9327	9327
query79	1949	822	586	586
query80	608	517	453	453
query81	491	262	225	225
query82	445	130	100	100
query83	253	256	251	251
query84	250	101	84	84
query85	758	435	324	324
query86	337	299	291	291
query87	4444	4395	4313	4313
query88	3477	2263	2277	2263
query89	383	309	353	309
query90	1937	226	215	215
query91	142	141	116	116
query92	75	63	58	58
query93	1374	931	592	592
query94	671	395	293	293
query95	364	294	280	280
query96	499	584	287	287
query97	2693	2739	2673	2673
query98	233	221	202	202
query99	1428	1409	1249	1249
Total cold run time: 276983 ms
Total hot run time: 186004 ms

doris-robot avatar Jun 20 '25 06:06 doris-robot

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

query1	0.04	0.04	0.02
query2	0.07	0.03	0.04
query3	0.25	0.07	0.06
query4	1.61	0.11	0.10
query5	0.44	0.43	0.42
query6	1.15	0.67	0.67
query7	0.02	0.01	0.02
query8	0.05	0.04	0.03
query9	0.57	0.55	0.51
query10	0.59	0.59	0.57
query11	0.16	0.11	0.11
query12	0.15	0.11	0.12
query13	0.63	0.61	0.61
query14	0.82	0.82	0.82
query15	0.91	0.87	0.88
query16	0.38	0.39	0.42
query17	1.06	1.09	1.09
query18	0.23	0.22	0.21
query19	1.94	1.84	1.86
query20	0.01	0.01	0.01
query21	15.40	0.92	0.55
query22	0.77	1.14	0.73
query23	14.89	1.40	0.64
query24	6.55	1.40	0.63
query25	0.52	0.15	0.07
query26	0.66	0.16	0.14
query27	0.06	0.06	0.04
query28	10.17	0.93	0.45
query29	12.56	4.00	3.30
query30	0.26	0.09	0.07
query31	2.82	0.60	0.39
query32	3.24	0.56	0.46
query33	3.14	3.08	3.10
query34	16.12	5.37	4.76
query35	4.86	4.78	4.82
query36	0.70	0.50	0.49
query37	0.09	0.07	0.07
query38	0.05	0.04	0.04
query39	0.03	0.02	0.03
query40	0.17	0.15	0.14
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: 104.29 s
Total hot run time: 29.4 s

doris-robot avatar Jun 20 '25 06:06 doris-robot

FE UT Coverage Report

Increment line coverage 0.00% (0/26) :tada: Increment coverage report Complete coverage report

hello-stephen avatar Jun 20 '25 07:06 hello-stephen

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

github-actions[bot] avatar Jun 20 '25 13:06 github-actions[bot]

PR approved by anyone and no changes requested.

github-actions[bot] avatar Jun 20 '25 13:06 github-actions[bot]