feat(catalog): enrich catalog interface with more methods#102
feat(catalog): enrich catalog interface with more methods#102ChaomingZhangCN wants to merge 10 commits intoalibaba:mainfrom
Conversation
| /// Invalidates cached table metadata. | ||
| /// | ||
| /// @param identifier Identifier of the table to invalidate. | ||
| virtual void InvalidateTable(const Identifier& identifier) {} |
There was a problem hiding this comment.
Does InvalidateTable need a return status?
| /// @param instant Like snapshotId or tagName | ||
| /// @return A status indicating success or failure. | ||
| virtual Status RollbackTo(const Identifier& identifier, | ||
| const std::chrono::system_clock::time_point& instant) { |
There was a problem hiding this comment.
instant is a time point or a snapshot id or tag name? It seems param mismatches comments.
There was a problem hiding this comment.
+1, usingstd::variant is better than std::chrono::system_clock::time_point.
| /// status. | ||
| virtual Result<std::vector<std::string>> ListTables(const std::string& db_name) const = 0; | ||
|
|
||
| /// Drops a database. |
There was a problem hiding this comment.
This PR includes too many unimplemented APIs at once, which may make the API documentation confusing. Would it be better to submit only a few APIs with their implementations in each PR?
There was a problem hiding this comment.
Thank you for your suggestion. I will implement some of them in the filesystem catalog.
| /// ================== Table Metadata ===================== | ||
|
|
||
| /// A name to identify this database. | ||
| virtual std::string Name() = 0; |
There was a problem hiding this comment.
virtual std::string Name() const = 0;
| virtual ~View() = default; | ||
|
|
||
| /// A name to identify this view. | ||
| virtual std::string Name() = 0; |
There was a problem hiding this comment.
For all GetXXX() api, please add const,
like virtual std::string Name() const = 0;
Purpose
Close #84
API and Format
Documentation