THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
Code Block | ||
---|---|---|
| ||
@Internal public class ClickHouseCatalog extends AbstractCatalog { public ClickHouseCatalog( String catalogName, @Nullable String defaultDatabase, String baseUrl, String username, String password, Map<String, String> properties) { super(...); //... } @Override public void open() throws CatalogException { } @Override public synchronized void close() throws CatalogException { } @Override public Optional<Factory> getFactory() { return Optional.of(...); } // ------------- databases ------------- @Override public synchronized List<String> listDatabases() throws CatalogException {} @Override public CatalogDatabase getDatabase(String databaseName) throws DatabaseNotExistException, CatalogException { } @Override public boolean databaseExists(String databaseName) throws CatalogException { } // ------------- tables ------------- @Override public synchronized List<String> listTables(String databaseName) throws DatabaseNotExistException, CatalogException { } @Override public CatalogBaseTable getTable(ObjectPath tablePath) throws TableNotExistException, CatalogException { } @Override public boolean tableExists(ObjectPath tablePath) throws CatalogException {} // -------other unsupport methods placeholders. ... } |
Using the
...
ClickHouseCatalog
Table API
Code Block |
---|
// java tEnv.registerCatalog(name, new ClickHouseCatalog(...)) |
...