Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix empty block location #18385

Merged
merged 1 commit into from
Nov 9, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -389,15 +389,7 @@ public CacheManager.State getCacheManagerState() {
public void moveBlock(long sessionId, long blockId, AllocateOptions moveOptions)
throws IOException {
// TODO(bowen): implement actual move and replace placeholder values
int dirIndex = getDirIndexOfBlock(blockId);
BlockStoreLocation srcLocation = new BlockStoreLocation(DEFAULT_TIER, dirIndex);
BlockStoreLocation destLocation = moveOptions.getLocation();
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the destination location is empty alluxio.worker.block.BlockStoreLocation#ANY_MEDIUM, and is used by the moveBlock operation as a special place holder. It's not supposed to be the actual block location.

for (BlockStoreEventListener listener : mBlockStoreEventListeners) {
synchronized (listener) {
listener.onMoveBlockByClient(blockId, srcLocation, destLocation);
}
}
throw new UnsupportedOperationException();
throw new UnsupportedOperationException("moveBlock");
}

@Override
Expand Down
Loading