[Feature](show) show backend config using ShowStmt#36525
[Feature](show) show backend config using ShowStmt#36525morrySnow merged 6 commits intoapache:masterfrom
Conversation
|
Thank you for your contribution to Apache Doris. Since 2024-03-18, the Document has been moved to doris-website. |
|
run buildall |
TPC-H: Total hot run time: 39959 ms |
TPC-DS: Total hot run time: 174356 ms |
ClickBench: Total hot run time: 30.98 s |
|
PR approved by at least one committer and no changes requested. |
|
PR approved by anyone and no changes requested. |
|
run p0 |
zclllyybb
left a comment
There was a problem hiding this comment.
Is this feature(show config) supported in Nereids?
ShowStmt does not differentiate between old and new optimizers,so it works with both. |
should what |
The NereidsParser can't parse all ShowStmt (e.g., |
I think so. But if all ShowStmt are not supported now for nereids, it's also good for this pr. The optimizer group may look forward for nereids compatible in the future |
I have optimized the implementation and now it supports nereids. |
|
run buildall |
TPC-H: Total hot run time: 39823 ms |
TPC-DS: Total hot run time: 173010 ms |
ClickBench: Total hot run time: 31 s |
75b5602 to
d6163b5
Compare
80b39e9 to
bc28826
Compare
|
run buildall |
TPC-H: Total hot run time: 38478 ms |
TPC-DS: Total hot run time: 190313 ms |
ClickBench: Total hot run time: 31.24 s |
|
PR approved by at least one committer and no changes requested. |
Currently, Doris only supports accessing backend configurations via HTTP
APIs. To enhance this functionality, I have added some syntax extensions
to allow displaying backend configurations using SQL commands.
The SQL syntax for displaying backend configurations is similar to that
for displaying frontend configurations:
1. Display backend configurations matching a pattern:
This statement will display all active backend configurations that match
the specified pattern.
show backend config like ${pattern}
3. Display backend configurations for a specific BE using the backend ID
show backend config from ${beId}
4. Use both a pattern and a backend ID:
show backend config like ${pattern} from ${backendID}
The output of these statements consists of 6 columns: BE ID, BE host IP,
configuration key, configuration value, configuration type, and whether
it is mutable or not.
+-----------+---------------+---------+-------+---------+-----------+
| BackendId | Host | Key | Value | Type | IsMutable |
+-----------+---------------+---------+-------+---------+-----------+
| 10001 | xx.xx.xxx.xxx | be_port | 9060 | int32_t | false |
+-----------+---------------+---------+-------+---------+-----------+
This provides an additional way to access backend configurations within
Doris.
Co-authored-by: duanxujian <duanxujian@jd.com>
# Versions PR apache/doris#36525 has implemented showing backend config by ShowStmt, add some docs. - [x] dev - [x] 3.0 - [ ] 2.1 - [ ] 2.0 # Languages - [x] Chinese - [x] English
) ### What problem does this PR solve? This PR #36525 introduced the `show backend config` statement to get BE config via http api. But it only support http api without auth. If BE enable auth by setting `enable_all_http_auth=true`, this command will fail. This PR fix it by adding `Auth-Token` in http request, so to support both auth/no-auth http api.
…che#51887) This PR apache#36525 introduced the `show backend config` statement to get BE config via http api. But it only support http api without auth. If BE enable auth by setting `enable_all_http_auth=true`, this command will fail. This PR fix it by adding `Auth-Token` in http request, so to support both auth/no-auth http api.
…che#51887) ### What problem does this PR solve? This PR apache#36525 introduced the `show backend config` statement to get BE config via http api. But it only support http api without auth. If BE enable auth by setting `enable_all_http_auth=true`, this command will fail. This PR fix it by adding `Auth-Token` in http request, so to support both auth/no-auth http api.
…che#51887) This PR apache#36525 introduced the `show backend config` statement to get BE config via http api. But it only support http api without auth. If BE enable auth by setting `enable_all_http_auth=true`, this command will fail. This PR fix it by adding `Auth-Token` in http request, so to support both auth/no-auth http api.
…che#51887) This PR apache#36525 introduced the `show backend config` statement to get BE config via http api. But it only support http api without auth. If BE enable auth by setting `enable_all_http_auth=true`, this command will fail. This PR fix it by adding `Auth-Token` in http request, so to support both auth/no-auth http api.
Proposed changes
Issue Number: close #36445
Currently, Doris only supports accessing backend configurations via HTTP APIs. To enhance this functionality, I have added some syntax extensions to allow displaying backend configurations using SQL commands.
The SQL syntax for displaying backend configurations is similar to that for displaying frontend configurations:
This statement will display all active backend configurations that match the specified pattern.
The output of these statements consists of 6 columns: BE ID, BE host IP, configuration key, configuration value, configuration type, and whether it is mutable or not.
This provides an additional way to access backend configurations within Doris.