Skip to content

Commit

Permalink
[#1667] feat(hadoop-catalog, core): Adapt the fileset catalog to Cata…
Browse files Browse the repository at this point in the history
…logOperationsDispatcher (#1714)

### What changes were proposed in this pull request?

This PR add the Hadoop catalog adaption to the
CatalogOperationsDispatcher

### Why are the changes needed?

Part of fileset catalog support work

Fix: #1667

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

UTs.
  • Loading branch information
jerryshao authored Jan 29, 2024
1 parent 3f6c051 commit 912f8d7
Show file tree
Hide file tree
Showing 6 changed files with 582 additions and 131 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,11 @@ public void initialize(Map<String, String> config) throws RuntimeException {
@Override
public NameIdentifier[] listFilesets(Namespace namespace) throws NoSuchSchemaException {
try {
NameIdentifier schemaIdent = NameIdentifier.of(namespace.levels());
if (!store.exists(schemaIdent, Entity.EntityType.SCHEMA)) {
throw new NoSuchSchemaException("Schema " + schemaIdent + " does not exist");
}

List<FilesetEntity> filesets =
store.list(namespace, FilesetEntity.class, Entity.EntityType.FILESET);
return filesets.stream()
Expand Down
Loading

0 comments on commit 912f8d7

Please sign in to comment.