This is an automated email from the ASF dual-hosted git repository.

haonan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iotdb.git


The following commit(s) were added to refs/heads/master by this push:
     new b5d13d1876 Delete abandoned API in document (#9773)
b5d13d1876 is described below

commit b5d13d1876b50f69184a09c181899302315e40e1
Author: wanghui42 <[email protected]>
AuthorDate: Mon May 8 14:08:26 2023 +0800

    Delete abandoned API in document (#9773)
---
 docs/UserGuide/API/Programming-Java-Native-API.md  | 98 ----------------------
 .../UserGuide/API/Programming-Java-Native-API.md   | 93 --------------------
 2 files changed, 191 deletions(-)

diff --git a/docs/UserGuide/API/Programming-Java-Native-API.md 
b/docs/UserGuide/API/Programming-Java-Native-API.md
index 4fffd270b0..59f9889172 100644
--- a/docs/UserGuide/API/Programming-Java-Native-API.md
+++ b/docs/UserGuide/API/Programming-Java-Native-API.md
@@ -509,101 +509,3 @@ Examples: 
```session/src/test/java/org/apache/iotdb/session/pool/SessionPoolTest
 
 Or `example/session/src/main/java/org/apache/iotdb/SessionPoolExample.java`
 
-
-## Cluster information related APIs (only works in the cluster mode)
-
-Cluster information related APIs allow users get the cluster info like where a 
database will be 
-partitioned to, the status of each node in the cluster.
-
-To use the APIs, add dependency in your pom file:
-
-```xml
-<dependencies>
-    <dependency>
-      <groupId>org.apache.iotdb</groupId>
-      <artifactId>iotdb-thrift-cluster</artifactId>
-      <version>1.0.0</version>
-    </dependency>
-</dependencies>
-```
-
-How to open a connection:
-
-```java
-import org.apache.thrift.protocol.TBinaryProtocol;
-import org.apache.thrift.transport.TSocket;
-import org.apache.thrift.transport.TTransport;
-import org.apache.thrift.transport.TTransportException;
-import org.apache.iotdb.rpc.RpcTransportFactory;
-
-public class CluserInfoClient {
-  TTransport transport;
-  ClusterInfoService.Client client;
-  public void connect() {
-    transport =
-            RpcTransportFactory.INSTANCE.getTransport(
-                    new TSocket(
-                            // the RPC address
-                            
IoTDBDescriptor.getInstance().getConfig().getRpcAddress(),
-                            // the RPC port
-                            
ClusterDescriptor.getInstance().getConfig().getClusterRpcPort()));
-    try {
-      transport.open();
-    } catch (TTransportException e) {
-      Assert.fail(e.getMessage());
-    }
-    //get the client
-    client = new ClusterInfoService.Client(new TBinaryProtocol(transport));
-  }
-  public void close() {
-    transport.close();
-  }
-}
-```
-
-APIs in `ClusterInfoService.Client`:
-
-
-* Get the physical hash ring of the cluster:
-
-``` java
-list<Node> getRing();
-```
-
-* Get data partition information of input path and time range:
-
-```java 
-/**
- * @param path input path (should contains a database name as its prefix)
- * @return the data partition info. If the time range only covers one data 
partition, the the size
- * of the list is one.
- */
-list<DataPartitionEntry> getDataPartition(1:string path, 2:long startTime, 
3:long endTime);
-```
-
-* Get metadata partition information of input path:
-```java  
-/**
- * @param path input path (should contains a database name as its prefix)
- * @return metadata partition information
- */
-list<Node> getMetaPartition(1:string path);
-```
-
-* Get the status (alive or not) of all nodes:
-``` java
-/**
- * @return key: node, value: live or not
- */
-map<Node, bool> getAllNodeStatus();
-```
-
-* get the raft group info (voteFor, term, etc..) of the connected node
-  (Notice that this API is rarely used by users):
-```java  
-/**
- * @return A multi-line string with each line representing the total time 
consumption, invocation
- *     number, and average time consumption.
- */
-string getInstrumentingInfo();
-```
diff --git a/docs/zh/UserGuide/API/Programming-Java-Native-API.md 
b/docs/zh/UserGuide/API/Programming-Java-Native-API.md
index e3469590de..80bd76bf04 100644
--- a/docs/zh/UserGuide/API/Programming-Java-Native-API.md
+++ b/docs/zh/UserGuide/API/Programming-Java-Native-API.md
@@ -502,96 +502,3 @@ void testInsertTablets(Map<String, Tablet> tablets)
 
 或 `example/session/src/main/java/org/apache/iotdb/SessionPoolExample.java`
 
-### 集群信息相关的接口 (仅在集群模式下可用)
-
-集群信息相关的接口允许用户获取如数据分区情况、节点是否当机等信息。
-要使用该 API,需要增加依赖:
-
-```xml
-<dependencies>
-    <dependency>
-      <groupId>org.apache.iotdb</groupId>
-      <artifactId>iotdb-thrift-cluster</artifactId>
-      <version>1.0.0</version>
-    </dependency>
-</dependencies>
-```
-
-建立连接与关闭连接的示例:
-
-```java
-import org.apache.thrift.protocol.TBinaryProtocol;
-import org.apache.thrift.transport.TSocket;
-import org.apache.thrift.transport.TTransport;
-import org.apache.thrift.transport.TTransportException;
-import org.apache.iotdb.rpc.RpcTransportFactory;
-
-public class CluserInfoClient {
-  TTransport transport;
-  ClusterInfoService.Client client;
-  public void connect() {
-    transport =
-      RpcTransportFactory.INSTANCE.getTransport(
-        new TSocket(
-          // the RPC address
-          IoTDBDescriptor.getInstance().getConfig().getRpcAddress(),
-          // the RPC port
-          ClusterDescriptor.getInstance().getConfig().getClusterRpcPort()));
-    try {
-      transport.open();
-    } catch (TTransportException e) {
-      Assert.fail(e.getMessage());
-    }
-    //get the client
-    client = new ClusterInfoService.Client(new TBinaryProtocol(transport));
-   }
-  public void close() {
-    transport.close();
-  }  
-}
-```
-
-API 列表:
-
-* 获取集群中的各个节点的信息(构成哈希环)
-
-``` java
-list<Node> getRing();
-```
-
-* 给定一个路径(应包括一个 SG 作为前缀)和起止时间,获取其覆盖的数据分区情况:
-
-```java 
-/**
- * @param path input path (should contains a database name as its prefix)
- * @return the data partition info. If the time range only covers one data 
partition, the the size
- * of the list is one.
- */
-list<DataPartitionEntry> getDataPartition(1:string path, 2:long startTime, 
3:long endTime);
-```
-
-* 给定一个路径(应包括一个 SG 作为前缀),获取其被分到了哪个节点上:
-```java  
-/**
- * @param path input path (should contains a database name as its prefix)
- * @return metadata partition information
- */
-list<Node> getMetaPartition(1:string path);
-```
-
-* 获取所有节点的死活状态:
-``` java
-/**
- * @return key: node, value: live or not
- */
-map<Node, bool> getAllNodeStatus();
-```
-
-* 获取当前连接节点的 Raft 组信息(投票编号等)(一般用户无需使用该接口):
-```java  
-/**
- * @return A multi-line string with each line representing the total time 
consumption, invocation
- *     number, and average time consumption.
- */
-string getInstrumentingInfo();
-```

Reply via email to