Skip to content

HDFS-16866. Fix a typo in Dispatcher #5202

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

Merged
merged 3 commits into from
Dec 16, 2022
Merged
Show file tree
Hide file tree
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 @@ -708,12 +708,12 @@ public String toString() {

Result newResult(ExitStatus exitStatus, long bytesLeftToMove, long bytesBeingMoved) {
return new Result(exitStatus, bytesLeftToMove, bytesBeingMoved,
dispatcher.getBytesMoved(), dispatcher.getBblocksMoved());
dispatcher.getBytesMoved(), dispatcher.getBlocksMoved());
}

Result newResult(ExitStatus exitStatus) {
return new Result(exitStatus, -1, -1, dispatcher.getBytesMoved(),
dispatcher.getBblocksMoved());
dispatcher.getBlocksMoved());
}

/** Run an iteration for all datanodes. */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ synchronized int allocate(int n) {
}
}

/** Aloocate a single lot of items */
/** Allocate a single lot of items. */
int allocate() {
return allocate(lotSize);
}
Expand Down Expand Up @@ -1125,7 +1125,7 @@ long getBytesMoved() {
return nnc.getBytesMoved().get();
}

long getBblocksMoved() {
long getBlocksMoved() {
return nnc.getBlocksMoved().get();
}

Expand Down Expand Up @@ -1232,7 +1232,7 @@ public boolean dispatchAndCheckContinue() throws InterruptedException {
*/
private long dispatchBlockMoves() throws InterruptedException {
final long bytesLastMoved = getBytesMoved();
final long blocksLastMoved = getBblocksMoved();
final long blocksLastMoved = getBlocksMoved();
final Future<?>[] futures = new Future<?>[sources.size()];

int concurrentThreads = Math.min(sources.size(),
Expand Down Expand Up @@ -1282,7 +1282,7 @@ public void run() {
waitForMoveCompletion(targets);
LOG.info("Total bytes (blocks) moved in this iteration {} ({})",
StringUtils.byteDesc(getBytesMoved() - bytesLastMoved),
(getBblocksMoved() - blocksLastMoved));
(getBlocksMoved() - blocksLastMoved));

return getBytesMoved() - bytesLastMoved;
}
Expand Down