zymap commented on a change in pull request #8375:
URL: https://github.com/apache/pulsar/pull/8375#discussion_r514256993



##########
File path: site2/docs/admin-api-persistent-topics.md
##########
@@ -1,80 +1,78 @@
 ---
 id: admin-api-persistent-topics
-title: Managing persistent topics
-sidebar_label: Persistent topics
+title: Manage topics
+sidebar_label: Topics
 ---
 
-Persistent helps to access topic which is a logical endpoint for publishing 
and consuming messages. Producers publish messages to the topic and consumers 
subscribe to the topic, to consume messages published to the topic.
-
-In all of the instructions and commands below, the topic name structure is:
-
+Pulsar has persistent and non-persistent topics. Persistent topic is a logical 
endpoint for publishing and consuming messages. The topic name structure for 
persistent topics is:
 
 ```shell
 persistent://tenant/namespace/topic
 ```
 
-## Persistent topics resources
+Non-persistent topics are used in applications that only consume real-time 
published messages and do not need persistent guarantee. In this way, it 
reduces message-publish latency by removing overhead of persisting messages. 
The topic name structure for non-persistent topics is:
 
-### List of topics
+```shell
+non-persistent://tenant/namespace/topic
+```
+## Manage topic resources
+Whether it is persistent or non-persistent topic, you can obtain the topic 
resources through `pulsar-admin` tool, REST API and Java.
 
-It provides a list of persistent topics exist under a given namespace.
+### List of topics
 
-#### pulsar-admin
+You can get the list of topics under a given namespace in the following ways.
 
-List of topics can be fetched using [`list`](../../reference/CliTools#list) 
command.
+<!--DOCUSAURUS_CODE_TABS-->
+<!--pulsar-admin-->
 
 ```shell
-$ pulsar-admin persistent list \
+$ pulsar-admin topics list \
   my-tenant/my-namespace
 ```
 
-#### REST API
-
-{@inject: 
endpoint|GET|/admin/v2/persistent/:tenant/:namespace|operation/getList}
-
-#### Java
+<!--REST API-->
+{@inject: endpoint|GET|/admin/v2/topics/:tenant/:namespace|operation/getList}

Review comment:
       I don't think we have the `topics` endpoint to get all the topics. 
Actually, there have two steps on the client-side, the client will get the 
persistent topics and non-persistent topics then combine the result at the 
client-side.
   I am not sure how to add two REST API endpoints. @tuteng Any ideas?

##########
File path: site2/docs/admin-api-persistent-topics.md
##########
@@ -1,80 +1,78 @@
 ---
 id: admin-api-persistent-topics
-title: Managing persistent topics
-sidebar_label: Persistent topics
+title: Manage topics
+sidebar_label: Topics
 ---
 
-Persistent helps to access topic which is a logical endpoint for publishing 
and consuming messages. Producers publish messages to the topic and consumers 
subscribe to the topic, to consume messages published to the topic.
-
-In all of the instructions and commands below, the topic name structure is:
-
+Pulsar has persistent and non-persistent topics. Persistent topic is a logical 
endpoint for publishing and consuming messages. The topic name structure for 
persistent topics is:
 
 ```shell
 persistent://tenant/namespace/topic
 ```
 
-## Persistent topics resources
+Non-persistent topics are used in applications that only consume real-time 
published messages and do not need persistent guarantee. In this way, it 
reduces message-publish latency by removing overhead of persisting messages. 
The topic name structure for non-persistent topics is:
 
-### List of topics
+```shell
+non-persistent://tenant/namespace/topic
+```
+## Manage topic resources
+Whether it is persistent or non-persistent topic, you can obtain the topic 
resources through `pulsar-admin` tool, REST API and Java.
 
-It provides a list of persistent topics exist under a given namespace.
+### List of topics
 
-#### pulsar-admin
+You can get the list of topics under a given namespace in the following ways.
 
-List of topics can be fetched using [`list`](../../reference/CliTools#list) 
command.
+<!--DOCUSAURUS_CODE_TABS-->
+<!--pulsar-admin-->
 
 ```shell
-$ pulsar-admin persistent list \
+$ pulsar-admin topics list \
   my-tenant/my-namespace
 ```
 
-#### REST API
-
-{@inject: 
endpoint|GET|/admin/v2/persistent/:tenant/:namespace|operation/getList}
-
-#### Java
+<!--REST API-->
+{@inject: endpoint|GET|/admin/v2/topics/:tenant/:namespace|operation/getList}
 
+<!--Java-->
 ```java
 String namespace = "my-tenant/my-namespace";
-admin.persistentTopics().getList(namespace);
+admin.topics().getList(namespace);
 ```
+<!--END_DOCUSAURUS_CODE_TABS-->
 
 ### Grant permission
 
-It grants permissions on a client role to perform specific actions on a given 
topic.
-
-#### pulsar-admin
-
-Permission can be granted using 
[`grant-permission`](../../reference/CliTools#grant-permission) command.
+You can grant permissions on a client role to perform specific actions on a 
given topic in the following ways.
 
+<!--DOCUSAURUS_CODE_TABS-->
+<!--pulsar-admin-->
 ```shell
-$ pulsar-admin persistent grant-permission \
+$ pulsar-admin topics grant-permission \
   --actions produce,consume --role application1 \
   persistent://test-tenant/ns1/tp1 \
-
 ```
 
-#### REST API
-
-{@inject: 
endpoint|POST|/admin/v2/persistent/:tenant/:namespace/:topic/permissions/:role|operation/grantPermissionsOnTopic}
-
-#### Java
+<!--REST API-->
+{@inject: 
endpoint|POST|/admin/v2/topics/:tenant/:namespace/:topic/permissions/:role|operation/grantPermissionsOnTopic}

Review comment:
       similar issue with the previous comments. We don't have the `topics` 
endpoint. All the following REST API endpoint has the same issue.




----------------------------------------------------------------
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:
[email protected]


Reply via email to