apache / gravitino

World's most powerful open data catalog for building a high-performance, geo-distributed and federated metadata lake.
https://gravitino.apache.org
Apache License 2.0
1.07k stars 334 forks source link

[FEATURE] Add formatted output to Gravitino CLI #5506

Open waukin opened 6 days ago

waukin commented 6 days ago

Describe the feature

The current output of the Gravitino CLI is as follows:

image

I plan to enhance the Gravitino CLI with formatted output to make it look more readable, e.g.

image

Motivation

No response

Additional context

No response

justinmclean commented 6 days ago

Thanks for the idea, while that is more readable, that format would be harder to parse via a script. I'd suggest that if you want to do this, then you make it available via a format option. A possible extension would be to add the users default format to the gravitino CLI configuration file.

xunliu commented 6 days ago

I think we just need to support standard output format, like MySQL client, The Gravitino already have a lot of configuration, make it difficult for user to understand.

justinmclean commented 6 days ago

The Gravitino CLI configuration file currently has 3 properties in it; this would add a fourth - it's not that complex. The MySQL client has multiple forms of output, and the default for batch mode (similar to how the Gravitino CLi would be used) is tab-delimited output, not ACSII table output. It's output format is determined by an option or optional aliases.

waukin commented 1 day ago

I will start by implementing a single standard output format. If needed, we can add multiple forms of output in a future PR.