Skip to content

Commit 9de8453

Browse files
committed
adapt logging
1 parent 51c4f43 commit 9de8453

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

  • x-pack/plugin/searchable-snapshots/src/main/java/org/elasticsearch/xpack/searchablesnapshots/cache

x-pack/plugin/searchable-snapshots/src/main/java/org/elasticsearch/xpack/searchablesnapshots/cache/CacheDirectory.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -251,12 +251,11 @@ int readCacheFile(FileChannel fc, long end, long position, byte[] buffer, int of
251251
@SuppressForbidden(reason = "Use positional writes on purpose")
252252
void writeCacheFile(FileChannel fc, long start, long end) throws IOException {
253253
assert assertFileChannelOpen(fc);
254-
final String fileName = cacheFileReference.getFileName();
255254
final byte[] copyBuffer = new byte[Math.toIntExact(Math.min(COPY_BUFFER_SIZE, end - start))];
256-
logger.trace(() -> new ParameterizedMessage("writing range [{}-{}] of file [{}] to cache file", start, end, fileName));
255+
logger.trace(() -> new ParameterizedMessage("writing range [{}-{}] to cache file [{}]", start, end, cacheFileReference));
257256

258257
int bytesCopied = 0;
259-
try (IndexInput input = in.openInput(fileName, ioContext)) {
258+
try (IndexInput input = in.openInput(cacheFileReference.getFileName(), ioContext)) {
260259
stats.incrementInnerOpenCount();
261260
if (start > 0) {
262261
input.seek(start);

0 commit comments

Comments
 (0)