Skip to content
This repository has been archived by the owner on May 12, 2021. It is now read-only.

APEXMALHAR-2566 Fixed NPE in FSWindowDataManager #732

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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 @@ -484,6 +484,10 @@ private Object retrieve(FSWindowReplayWAL wal, long windowId) throws IOException

if (wal.retrievedWindow == null) {
wal.retrievedWindow = readNext(reader);
if(wal.retrievedWindow == null &&
reader.getCurrentPointer().compareTo(wal.walEndPointerAfterRecovery) < 0) {
Copy link
Member

Choose a reason for hiding this comment

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

What if wal.retrievedWindow == null && reader.getCurrentPointer().compareTo(wal.walEndPointerAfterRecovery) >= 0?

continue;
}
Preconditions.checkNotNull(wal.retrievedWindow);
Copy link
Member

Choose a reason for hiding this comment

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

There is an assumption that wal.retrievedWindow != null that does not seems to be valid.

}
currentWindow = Longs.fromByteArray(wal.retrievedWindow.toByteArray());
Expand Down