Skip to content

Commit

Permalink
Partition Removal
Browse files Browse the repository at this point in the history
  • Loading branch information
kristyelee committed Dec 4, 2024
1 parent 321fb40 commit e7bf0c7
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -476,10 +476,7 @@ private synchronized void bootstrap() {
aggVersionedStorageEngineStats.setStorageEngine(versionTopic, storageEngine);
StoreBackend storeBackend = getStoreOrThrow(storeName);
ComplementSet<Integer> persistedPartitionIds = ComplementSet.newSet(storageEngine.getPersistedPartitionIds());
ComplementSet<Integer> unassignedPartitionSet = ComplementSet.newSet(storeBackend.getSubscription());
// Set of partitions that are not included in the submitted set of partitions.
unassignedPartitionSet.removeAll(persistedPartitionIds);
storeBackend.unsubscribe(unassignedPartitionSet);
storeBackend.unsubscribe(persistedPartitionIds);
storeBackend.subscribe(ComplementSet.newSet(partitions), Optional.of(version));
});
}
Expand Down

0 comments on commit e7bf0c7

Please sign in to comment.