sijia-w commented on a change in pull request #13118:
URL: https://github.com/apache/pulsar/pull/13118#discussion_r766083167



##########
File path: site2/docs/admin-api-packages.md
##########
@@ -109,142 +124,168 @@ bin/pulsar-admin packages download 
functions://public/default/[email protected] --pat
 
 <!--REST API-->
 
-{@inject: 
endpoint|GET|/admin/v3/packages/:type/:tenant/:namespace/:packageName/:version/?version=[[pulsar:version_number]]}
+{@inject: 
endpoint|GET|/admin/v3/packages/:type/:tenant/:namespace/:packageName/:version}
 
 <!--JAVA-->
-Download a package to the package management service synchronously.
+Download a package from the package management service synchronously.
 
 ```java
-   void download(String packageName, String path) throws PulsarAdminException;
+  void download(String packageName, String path) throws PulsarAdminException;
 ```
 
-Download a package to the package management service asynchronously.
+Download a package from the package management service asynchronously.
+
 ```java
-   CompletableFuture<Void> downloadAsync(String packageName, String path);
+  CompletableFuture<Void> downloadAsync(String packageName, String path);
 ```
 <!--END_DOCUSAURUS_CODE_TABS-->
 
-### List all versions of a package
-You can get a list of all versions of a package in the following ways.
+### Delete a package
+
+You can use the following commands to delete a package.
+
 <!--DOCUSAURUS_CODE_TABS-->
 <!--pulsar-admin-->
+The following command deletes a package of version 0.1.
+
 ```shell
-bin/pulsar-admin packages list --type function public/default
+bin/pulsar-admin packages delete functions://public/default/[email protected]
 ```
 
 <!--REST API-->
 
-{@inject: 
endpoint|GET|/admin/v3/packages/:type/:tenant/:namespace/:packageName/?version=[[pulsar:version_number]]}
+{@inject: 
endpoint|DELETE|/admin/v3/packages/:type/:tenant/:namespace/:packageName/:version}
 
 <!--JAVA-->
-List all versions of a package synchronously.
+Delete a specified package synchronously.
 
 ```java
-   List<String> listPackageVersions(String packageName) throws 
PulsarAdminException;
+  void delete(String packageName) throws PulsarAdminException;
 ```
-List all versions of a package asynchronously.
+
+Delete a specified package asynchronously.
+
 ```java
-   CompletableFuture<List<String>> listPackageVersionsAsync(String 
packageName);
+  CompletableFuture<Void> deleteAsync(String packageName);
 ```
 <!--END_DOCUSAURUS_CODE_TABS-->
 
-### List all the specified type packages under a namespace
-You can get a list of all the packages with the given type in a namespace in 
the following ways.
+### Get the metadata of a package
+
+You can use the following commands to get the metadate of a package.
+
 <!--DOCUSAURUS_CODE_TABS-->
 <!--pulsar-admin-->
+
 ```shell
-bin/pulsar-admin packages list --type function public/default
+bin/pulsar-admin packages get-metadata function://public/default/test@v1
 ```
 
 <!--REST API-->
 
-{@inject: 
endpoint|PUT|/admin/v3/packages/:type/:tenant/:namespace/?version=[[pulsar:version_number]]}
+{@inject: 
endpoint|GET|/admin/v3/packages/:type/:tenant/:namespace/:packageName/:version/metadata}
 
 <!--JAVA-->
-List all the packages with the given type in a namespace synchronously.
+Get the metadata of a package synchronously.
 
 ```java
-   List<String> listPackages(String type, String namespace) throws 
PulsarAdminException;
+  PackageMetadata getMetadata(String packageName) throws PulsarAdminException;
 ```
-List all the packages with the given type in a namespace asynchronously.
+
+Get the metadata of a package asynchronously.
+
 ```java
-   CompletableFuture<List<String>> listPackagesAsync(String type, String 
namespace);
+  CompletableFuture<PackageMetadata> getMetadataAsync(String packageName);
 ```
 <!--END_DOCUSAURUS_CODE_TABS-->
 
-### Get the metadata of a package
-You can get the metadata of a package in the following ways.
+### Update the metadata of a package
+
+You can use the following commands to update the metadata of a package.
 
 <!--DOCUSAURUS_CODE_TABS-->
 <!--pulsar-admin-->
-
 ```shell
-bin/pulsar-admin packages get-metadata function://public/default/test@v1
+bin/pulsar-admin packages update-metadata 
function://public/default/[email protected] --description update-description
 ```
 
 <!--REST API-->
 
-{@inject: 
endpoint|GET|/admin/v3/packages/:type/:tenant/:namespace/:packageName/:version/metadata/?version=[[pulsar:version_number]]}
+{@inject: 
endpoint|PUT|/admin/v3/packages/:type/:tenant/:namespace/:packageName/:version/metadata}
 
 <!--JAVA-->
-Get the metadata of a package synchronously.
+Update the metadata of a package synchronously.
 
 ```java
-   PackageMetadata getMetadata(String packageName) throws PulsarAdminException;
+  void updateMetadata(String packageName, PackageMetadata metadata) throws 
PulsarAdminException;
 ```
-Get the metadata of a package asynchronously.
+
+Update the metadata of a package asynchronously.
+
 ```java
-   CompletableFuture<PackageMetadata> getMetadataAsync(String packageName);
+  CompletableFuture<Void> updateMetadataAsync(String packageName, 
PackageMetadata metadata);
 ```
 <!--END_DOCUSAURUS_CODE_TABS-->
 
-### Update the metadata of a package
-You can update the metadata of a package in the following ways.
+### List all versions of a package
+
+You can use the following commands to list all versions of a package.
+
 <!--DOCUSAURUS_CODE_TABS-->
 <!--pulsar-admin-->
 ```shell
-bin/pulsar-admin packages update-metadata 
function://public/default/[email protected] --description update-description
+bin/pulsar-admin packages list-versions type://tenant/namespace/packageName
 ```
 
 <!--REST API-->
 
-{@inject: 
endpoint|PUT|/admin/v3/packages/:type/:tenant/:namespace/:packageName/:version/metadata/?version=[[pulsar:version_number]]}
+{@inject: 
endpoint|GET|/admin/v3/packages/:type/:tenant/:namespace/:packageName}
 
 <!--JAVA-->
-Update a package metadata information synchronously.
+List all versions of a package synchronously.
 
 ```java
-   void updateMetadata(String packageName, PackageMetadata metadata) throws 
PulsarAdminException;
+  List<String> listPackageVersions(String packageName) throws 
PulsarAdminException;
 ```
-Update a package metadata information asynchronously.
+
+List all versions of a package asynchronously.
 ```java
-   CompletableFuture<Void> updateMetadataAsync(String packageName, 
PackageMetadata metadata);
+  CompletableFuture<List<String>> listPackageVersionsAsync(String packageName);
 ```
 <!--END_DOCUSAURUS_CODE_TABS-->
 
-### Delete a specified package
-You can delete a specified package with its package name in the following ways.
+### List all packages of a specific type under a namespace
+
+You can use the following commands to list all packages of a specific type 
under a namespace.
 
 <!--DOCUSAURUS_CODE_TABS-->
-<!--pulsar-admin-->
-The following command example deletes a package of version 0.1.
 
+<!--pulsar-admin-->
 ```shell
-bin/pulsar-admin packages delete functions://public/default/[email protected]
+bin/pulsar-admin packages list --type function public/default
 ```
 
 <!--REST API-->
 
-{@inject: 
endpoint|DELETE|/admin/v3/packages/:type/:tenant/:namespace/:packageName/:version/?version=[[pulsar:version_number]]}
+{@inject: endpoint|PUT|/admin/v3/packages/:type/:tenant/:namespace}
 
 <!--JAVA-->
-Delete a specified package synchronously.
+List all packages of a specific type under a namespace synchronously.
 
 ```java
-   void delete(String packageName) throws PulsarAdminException;
+  List<String> listPackages(String type, String namespace) throws 
PulsarAdminException;
 ```
-Delete a specified package asynchronously.
+
+List all packages of a specific type under a namespace asynchronously.
+
 ```java
-   CompletableFuture<Void> deleteAsync(String packageName);
+  CompletableFuture<List<String>> listPackagesAsync(String type, String 
namespace);
 ```
 <!--END_DOCUSAURUS_CODE_TABS-->
+
+
+> **Note**  
+> This page only includes some of the most frequently used operations.
+> * For more information about the commands, flags, descriptions, and more in 
Pulsar administrator, see [Pulsar 
admin](https://pulsar.apache.org/tools/pulsar-admin/) page.
+> * For more information about the parameters, responses, samples, and more in 
REST API, see [REST API](https://pulsar.incubator.apache.org/admin-rest-api#/) 
page.
+> * For more information about the classes, methods, descriptions, and more 
Java administrator API, see [Java admin 
API](https://pulsar.apache.org/api/admin/2.8.0-SNAPSHOT/) page.

Review comment:
       I don't think it's appropriate to put Note at the beginning of a page 
before you presenting anything.




-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to