Skip to content

Commit

Permalink
feat: close catalog
Browse files Browse the repository at this point in the history
  • Loading branch information
zengbao committed Sep 5, 2024
1 parent a3204fc commit 7419b06
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -154,4 +154,12 @@ record ->
private CdcMultiplexRecord wrapRecord(String databaseName, String tableName, CdcRecord record) {
return CdcMultiplexRecord.fromCdcRecord(databaseName, tableName, record);
}

@Override
public void close() throws Exception {
if (catalog != null) {
catalog.close();
catalog = null;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,10 @@ public void close() throws Exception {
if (compactExecutor != null) {
compactExecutor.shutdownNow();
}
if (catalog != null) {
catalog.close();
catalog = null;
}
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,10 @@ public void close() throws Exception {
if (compactExecutor != null) {
compactExecutor.shutdownNow();
}
if (catalog != null) {
catalog.close();
catalog = null;
}
}

@Override
Expand Down

0 comments on commit 7419b06

Please sign in to comment.