Skip to content

Commit 2984ceb

Browse files
authored
Merge pull request #349 from ydb-platform/improve-reader-logging
Remove "This shouldn't happen" from topic reader logs where it can actually happen
2 parents fbcf72a + f67f748 commit 2984ceb

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

topic/src/main/java/tech/ydb/topic/read/impl/ReaderImpl.java

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -456,9 +456,8 @@ private void onReadResponse(YdbTopic.StreamReadMessage.ReadResponse readResponse
456456
CompletableFuture<Void> readFuture = partitionSession.addBatches(data.getBatchesList());
457457
batchReadFutures.add(readFuture);
458458
} else {
459-
logger.error("[{}] Received PartitionData for unknown(closed?) PartitionSessionId={}. " +
460-
"This shouldn't happen",
461-
fullId, partitionId);
459+
logger.info("[{}] Received PartitionData for unknown(most likely already closed) " +
460+
"PartitionSessionId={}", fullId, partitionId);
462461
}
463462
});
464463
CompletableFuture.allOf(batchReadFutures.toArray(new CompletableFuture<?>[0]))
@@ -491,8 +490,8 @@ protected void onCommitOffsetResponse(YdbTopic.StreamReadMessage.CommitOffsetRes
491490
handleCommitResponse(partitionCommittedOffset.getCommittedOffset(),
492491
partitionSession.getSessionInfo());
493492
} else {
494-
logger.error("[{}] Received CommitOffsetResponse for unknown (closed?) partition session with " +
495-
"id={}. This shouldn't happen", fullId,
493+
logger.info("[{}] Received CommitOffsetResponse for unknown (most likely already closed) " +
494+
"partition session with id={}", fullId,
496495
partitionCommittedOffset.getPartitionSessionId());
497496
}
498497
}

0 commit comments

Comments
 (0)