You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2021/01/12 15:27:38 UTC

[GitHub] [incubator-doris] morningman commented on a change in pull request #5096: [Feature] Add a http interface to acquire the tablets distribution between different disks

morningman commented on a change in pull request #5096:
URL: https://github.com/apache/incubator-doris/pull/5096#discussion_r555856238



##########
File path: docs/zh-CN/administrator-guide/http-actions/tablets_distribution.md
##########
@@ -0,0 +1,124 @@
+---
+{
+    "title": "GET TABLETS DISTRIBUTION BETWEEN DIFFERENT DISKS",
+    "language": "zh-CN"
+}
+---
+
+<!-- 
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+# GET TABLETS DISTRIBUTION BETWEEN DIFFERENT DISKS
+   
+获取BE节点上每一个partition下的tablet在不同磁盘上的分布情况
+
+```
+curl -X GET http://be_host:webserver_port/tablets_distribution
+```
+
+返回值就是BE节点上每一个partition下的tablet在各个磁盘上的数量分布,只包含tablet数量。
+
+```
+{
+    msg: "OK",
+    code: 0,
+    data: {
+        host: "***",
+        tablets_distribution: [
+            {
+                partition_id:***,
+                disks:[
+                    {
+                        disk_path:"***",
+                        tablets_num:***,
+                    },
+                    {
+                        disk_path:"***",
+                        tablets_num:***,
+                    },
+
+                    ...
+
+                ]
+            },
+            {
+                partition_id:***,
+                disks:[
+                    {
+                        disk_path:"***",
+                        tablets_num:***,
+                    },
+                    {
+                        disk_path:"***",
+                        tablets_num:***,
+                    },
+
+                    ...
+
+                ]
+            },
+
+            ...
+
+        ]
+    },
+    count: ***
+}
+```
+
+```
+curl -X GET http://be_host:webserver_port/tablets_distribution?partition_id=xxx

Review comment:
       ```suggestion
   curl -X GET http://be_host:webserver_port/tablets_distribution?partition_id=xxx
   ```

##########
File path: docs/zh-CN/administrator-guide/http-actions/tablets_distribution.md
##########
@@ -0,0 +1,124 @@
+---
+{
+    "title": "GET TABLETS DISTRIBUTION BETWEEN DIFFERENT DISKS",
+    "language": "zh-CN"
+}
+---
+
+<!-- 
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+# GET TABLETS DISTRIBUTION BETWEEN DIFFERENT DISKS
+   
+获取BE节点上每一个partition下的tablet在不同磁盘上的分布情况
+
+```
+curl -X GET http://be_host:webserver_port/tablets_distribution

Review comment:
       How about:
   `/tablets_distribution?group_by=partition`
   `/tablets_distribution?group_by=partition&partition_id=10000`
   
   so that we can extent this api in future with some other kind of "group by"?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org