World's most powerful open data catalog for building a high-performance, geo-distributed and federated metadata lake.
Java ai-catalogdata-catalogdatalakefederated-querylakehousemetadatametalakemodel-catalogopendatacatalogskycomputingstratosphere
[#5568] Update help content for Gravitino CLI (#5809)
Justin Mclean08f7d91d1b48
diff --git a/clients/cli/src/main/resources/column_help.txt b/clients/cli/src/main/resources/column_help.txtnew file mode 100644index 0000000000..ccc2fb3906--- /dev/null+++ b/clients/cli/src/main/resources/column_help.txt@@ -0,0 +1,33 @@+gcli column [list|details|create|delete|update]++Please set the metalake in the Gravitino configuration file or the environment variable before running any of these commands.++Note that some commands are not supported depending on what the database supports.++When setting the datatype of a column the following basic types are currently supported:+null, boolean, byte, ubyte, short, ushort, integer, uinteger, long, ulong, float, double, date, time, timestamp, tztimestamp, intervalyear, intervalday, uuid, string, binary++In addition decimal(precision,scale), fixed(length), fixedchar(length) and varchar(length).++Example commands++Show all columns+gcli column list --name catalog_postgres.hr.departments++Show column's audit information+gcli column details --name catalog_postgres.hr.departments.name --audit++Add a column+gcli column create --name catalog_postgres.hr.departments.value --datatype long+gcli column create --name catalog_postgres.hr.departments.money --datatype "decimal(10,2)"+gcli column create --name catalog_postgres.hr.departments.name --datatype "varchar(100)"+gcli column create --name catalog_postgres.hr.departments.fullname --datatype "varchar(250)" --default "Fred Smith" --null=false++Delete a column+gcli column delete --name catalog_postgres.hr.departments.money++Update a column+gcli column update --name catalog_postgres.hr.departments.value --rename values+gcli column update --name catalog_postgres.hr.departments.values --datatype "varchar(500)"+gcli column update --name catalog_postgres.hr.departments.values --position name+gcli column update --name catalog_postgres.hr.departments.name --null truediff --git a/clients/cli/src/main/resources/fileset_help.txt b/clients/cli/src/main/resources/fileset_help.txtnew file mode 100644index 0000000000..758eda2e3f--- /dev/null+++ b/clients/cli/src/main/resources/fileset_help.txt@@ -0,0 +1,33 @@+gcli fileset [list|details|create|delete|update|properties|set|remove]++Please set the metalake in the Gravitino configuration file or the environment variable before running any of these commands.++Example commands++Create a fileset+gcli fileset create --name hadoop.schema.fileset --properties managed=true,location=file:/tmp/root/schema/example++List filesets+gcli fileset list --name hadoop.schema++Display a fileset's details+gcli fileset details --name hadoop.schema.fileset++Delete a fileset+gcli fileset delete --name hadoop.schema.fileset++Update a fileset's comment+gcli fileset update --name hadoop.schema.fileset --comment new_comment++Rename a fileset+gcli fileset update --name hadoop.schema.fileset --rename new_name++Display a fileset's properties+gcli fileset properties --name hadoop.schema.fileset++Set a fileset's property+gcli fileset set --name hadoop.schema.fileset --property test --value value++Remove a fileset's property+gcli fileset remove --name hadoop.schema.fileset --property test+diff --git a/clients/cli/src/main/resources/group_help.txt b/clients/cli/src/main/resources/group_help.txtnew file mode 100644index 0000000000..cbac95747a--- /dev/null+++ b/clients/cli/src/main/resources/group_help.txt@@ -0,0 +1,20 @@+gcli group [details|list|create|delete]++Please set the metalake in the Gravitino configuration file or the environment variable before running any of these commands.++Example commands++Create a group+gcli group create --group new_group++Display a group's details+gcli group details --group new_group++List all groups+gcli group list++Show a groups's audit information+gcli group details --group new_group --audit++Delete a group+gcli group delete --group new_groupdiff --git a/clients/cli/src/main/resources/role_help.txt b/clients/cli/src/main/resources/role_help.txtnew file mode 100644index 0000000000..d0838cfa40--- /dev/null+++ b/clients/cli/src/main/resources/role_help.txt@@ -0,0 +1,44 @@+gcli role [details|list|create|delete|grant|revoke]++Please set the metalake in the Gravitino configuration file or the environment variable before running any of these commands.++When granting or revoking privileges the following privileges can be used.++create_catalog, use_catalog, create_schema, use_schema, create_table, modify_table, select_table, create_fileset, write_fileset, read_fileset, create_topic, produce_topic, consume_topic, manage_users, create_role, manage_grants++Note that some are only valid for certain entities.++Example commands++Display role details+gcli role details --role admin++List all roles+gcli role list++Show a roles's audit information+gcli role details --role admin --audit++Create a role+gcli role create --role admin++Delete a role+gcli role delete --role admin++Add a role to a user+gcli user grant --user new_user --role admin++Remove a role from a user+gcli user revoke --user new_user --role admin++Add a role to a group+gcli group grant --group groupA --role admin++Remove a role from a group+gcli group revoke --group groupA --role admin++Grant a privilege+gcli role grant --name catalog_postgres --role admin --privilege create_table modify_table++Revoke a privilege+gcli role revoke --metalake metalake_demo --name catalog_postgres --role admin --privilege create_table modify_tablediff --git a/clients/cli/src/main/resources/schema_help.txt b/clients/cli/src/main/resources/schema_help.txtindex 2f8fa3e8b2..b4691f1636 100644--- a/clients/cli/src/main/resources/schema_help.txt+++ b/clients/cli/src/main/resources/schema_help.txt@@ -18,4 +18,4 @@ Create a schemagcli schema create --name catalog_postgres.new_dbDisplay schema properties-gcli schema properties --name catalog_postgres.hr -i\ No newline at end of file+gcli schema properties --name catalog_postgres.hr\ No newline at end of filediff --git a/clients/cli/src/main/resources/table_help.txt b/clients/cli/src/main/resources/table_help.txtnew file mode 100644index 0000000000..2a648f05ac--- /dev/null+++ b/clients/cli/src/main/resources/table_help.txt@@ -0,0 +1,49 @@+gcli table [list|details|create|delete|properties|set|remove]++Please set the metalake in the Gravitino configuration file or the environment variable before running any of these commands.++When creating a table the columns are specified in CSV file specifying the name of the column, the datatype, a comment, true or false if the column is nullable, true or false if the column is auto incremented, a default value and a default type. Not all of the columns need to be specifed just the name and datatype columns. If not specified comment default to null, nullability to true and auto increment to false. If only the default value is specified it defaults to the same data type as the column.++Example CSV file+Name,Datatype,Comment,Nullable,AutoIncrement,DefaultValue,DefaultType+name,String,person's name+ID,Integer,unique id,false,true+location,String,city they work in,false,false,Sydney,String++Example commands++Show all tables+gcli table list --name catalog_postgres.hr++Show tables details+gcli table details --name catalog_postgres.hr.departments++Show tables audit information+gcli table details --name catalog_postgres.hr.departments --audit++Show tables distribution information+gcli table details --name catalog_postgres.hr.departments --distribution++Show tables partition information+gcli table details --name catalog_postgres.hr.departments --partition++Show tables sort order information+gcli table details --name catalog_postgres.hr.departments --sortorder++Show table indexes+gcli table details --name catalog_mysql.db.iceberg_namespace_properties --index++Create a table+gcli table create --name catalog_postgres.hr.salaries --comment "comment" --columnfile ~/table.csv++Delete a table+gcli table delete --name catalog_postgres.hr.salaries++Display a tables's properties+gcli table properties --name catalog_postgres.hr.salaries++Set a tables's property+gcli table set --name catalog_postgres.hr.salaries --property test --value value++Remove a tables's property+gcli table remove --name catalog_postgres.hr.salaries --property testdiff --git a/clients/cli/src/main/resources/tag_help.txt b/clients/cli/src/main/resources/tag_help.txtnew file mode 100644index 0000000000..fea0a6697f--- /dev/null+++ b/clients/cli/src/main/resources/tag_help.txt@@ -0,0 +1,44 @@+gcli tag [list|details|create|delete|update|set|remove|properties]++Please set the metalake in the Gravitino configuration file or the environment variable before running any of these commands.++Example commands++Display a tag's details+gcli tag details --tag tagA++Create tags+gcli tag create --tag tagA tagB++List all tags+gcli tag list++Delete tags+gcli tag delete --tag tagA tagB++Add tags to an entity+gcli tag set --name catalog_postgres.hr --tag tagA tagB++Remove tags from an entity+gcli tag remove --name catalog_postgres.hr --tag tagA tagB++Remove all tags from an entity+gcli tag remove --name catalog_postgres.hr++List all tags on an entity+gcli tag list --name catalog_postgres.hr++List the properties of a tag+gcli tag properties --tag tagA++Set a properties of a tag+gcli tag set --tag tagA --property test --value value++Delete a property of a tag+gcli tag remove --tag tagA --property test++Rename a tag+gcli tag update --tag tagA --rename newTag++Update a tag's comment+gcli tag update --tag tagA --comment "new comment"diff --git a/clients/cli/src/main/resources/topic_help.txt b/clients/cli/src/main/resources/topic_help.txtnew file mode 100644index 0000000000..2e43c0e924--- /dev/null+++ b/clients/cli/src/main/resources/topic_help.txt@@ -0,0 +1,29 @@+gcli topic [list|details|create|delete|update|properties|set|remove]++Please set the metalake in the Gravitino configuration file or the environment variable before running any of these commands.++Example commands++Display a topic's details+gcli topic details --name kafka.default.topic3++Create a topic+gcli topic create --name kafka.default.topic3++List all topics+gcli topic list --name kafka.default++Delete a topic+gcli topic delete --name kafka.default.topic3++Change a topic's comment+gcli topic update --name kafka.default.topic3 --comment new_comment++Display a topics's properties+gcli topic properties --name kafka.default.topic3++Set a topics's property+gcli topic set --name kafka.default.topic3 --property test --value value++Remove a topics's property+gcli topic remove --name kafka.default.topic3 --property testdiff --git a/clients/cli/src/main/resources/user_help.txt b/clients/cli/src/main/resources/user_help.txtnew file mode 100644index 0000000000..bd08bea59f--- /dev/null+++ b/clients/cli/src/main/resources/user_help.txt@@ -0,0 +1,21 @@+gcli user [details|list|create|delete]++Please set the metalake in the Gravitino configuration file or the environment variable before running any of these commands.++Example commands++Create a user+gcli user create --user new_user++Show a user's details+gcli user details --user new_user++List all users+gcli user list++Show a roles's audit information+gcli user details --user new_user --audit++Delete a user+gcli user delete --user new_user+diff --git a/docs/cli.md b/docs/cli.mdindex 11b9f18e50..b01ea47756 100644--- a/docs/cli.md+++ b/docs/cli.md@@ -419,7 +419,7 @@ gcli schema create --name catalog_postgres.new_db#### Display schema properties```bash-gcli schema properties --name catalog_postgres.hr -i+gcli schema properties --name catalog_postgres.hr```Setting and removing schema properties is not currently supported by the Java API or the Gravitino CLI.@@ -581,10 +581,10 @@ gcli tag details --tag tagA#### Create tags```bash- gcli tag create --tag tagA tagB- ```+gcli tag create --tag tagA tagB+```-#### List all tag+#### List all tags```bashgcli tag list@@ -733,7 +733,7 @@ gcli group revoke --group groupA --role admingcli topic details --name kafka.default.topic3```-#### Create a tag+#### Create a topic```bashgcli topic create --name kafka.default.topic3@@ -838,7 +838,20 @@ Note that some commands are not supported depending on what the database supportWhen setting the datatype of a column the following basic types are currently supported:null, boolean, byte, ubyte, short, ushort, integer, uinteger, long, ulong, float, double, date, time, timestamp, tztimestamp, intervalyear, intervalday, uuid, string, binary-In addition decimal(precision,scale) and varchar(length).+In addition decimal(precision,scale), fixed(length), fixedchar(length) and varchar(length).+++#### Show all columns++```bash+gcli column list --name catalog_postgres.hr.departments+```++#### Show column's audit information++```bash+gcli column details --name catalog_postgres.hr.departments.name --audit+```#### Show a column's audit information