Skip to content

Commit

Permalink
Remove bogus assertion in CacheFile (#71174)
Browse files Browse the repository at this point in the history
There's a bogus assertion in CacheFile that expects a channel to be available whenever we continue writing to it. In case
where the range listener does not care about the write anymore (i.e. all reads are ok), it does not continues to hold onto
the file, however, which is ok.

Closes #71083
  • Loading branch information
ywelsch committed Apr 2, 2021
1 parent 6d0d447 commit d2aa194
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,6 @@ public Future<Integer> populateAndRead(
@Override
protected void doRun() throws Exception {
if (reference.tryIncRef() == false) {
assert false : "expected a non-closed channel reference";
throw new AlreadyClosedException("Cache file channel has been released and closed");
}
try {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -675,7 +675,6 @@ public StepListener<Integer> populateAndRead(
@Override
protected void doRun() throws Exception {
if (CacheFileRegion.this.tryIncRef() == false) {
// assert false : "expected a non-closed channel reference";
throw new AlreadyClosedException("Cache file channel has been released and closed");
}
try {
Expand Down

0 comments on commit d2aa194

Please sign in to comment.