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

HDFS-17455. Fix Client throw IndexOutOfBoundsException in DFSInputStream#fetchBlockAt #6710

Merged
merged 4 commits into from
Apr 11, 2024
Merged
Changes from 1 commit
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
Prev Previous commit
Next Next commit
HDFS-17455. Fix checkstytle
  • Loading branch information
haiyang1987 committed Apr 7, 2024
commit 2c9a6fbbebdb0d1beecee5000b3ee926ea93a4b8
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ public void testCreateBlockReaderWhenInvalidBlockTokenException() throws
long fileLen = 1024 * 64;
EnumSet<CreateFlag> createFlags = EnumSet.of(CREATE);
FSDataOutputStream out = fs.create(path, FsPermission.getFileDefault(), createFlags,
Copy link
Contributor

Choose a reason for hiding this comment

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

this out should be closed in the finally logic, right?

Copy link
Contributor

Choose a reason for hiding this comment

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

+1

fs.getConf().getInt(IO_FILE_BUFFER_SIZE_KEY, 4096),(short) 3,
fs.getConf().getInt(IO_FILE_BUFFER_SIZE_KEY, 4096), (short) 3,
fs.getDefaultBlockSize(path), null);
Copy link
Contributor

Choose a reason for hiding this comment

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

What's the default block size? 256MB? If so, please hardcode it.

int bufferLen = 1024;
byte[] toWrite = new byte[bufferLen];
Expand Down
Loading