keith-turner commented on code in PR #3079:
URL: https://github.com/apache/accumulo/pull/3079#discussion_r1023248061
##########
core/src/main/java/org/apache/accumulo/core/file/blockfile/impl/CachableBlockFile.java:
##########
@@ -83,8 +84,27 @@ public CachableBuilder conf(Configuration hadoopConf) {
}
public CachableBuilder fsPath(FileSystem fs, Path dataFile) {
+ return fsPath(fs, dataFile, false);
+ }
+
+ public CachableBuilder fsPath(FileSystem fs, Path dataFile, boolean
dropCacheBehind) {
this.cacheId = pathToCacheId(dataFile);
- this.inputSupplier = () -> fs.open(dataFile);
+ this.inputSupplier = () -> {
+ FSDataInputStream is = fs.open(dataFile);
+ if (dropCacheBehind) {
+ // Tell the DataNode that the write ahead log does not need to be
cached in the OS page
+ // cache
+ try {
+ is.setDropBehind(Boolean.TRUE);
Review Comment:
I was wondering how I could know if this changes was working as intended,
thought adding some trace logging that could be flipped on might be useful.
```suggestion
is.setDropBehind(Boolean.TRUE);
log.trace("Called setDropBehind(TRUE) for stream reading file
{}", dataFile);
```
##########
server/base/src/main/java/org/apache/accumulo/server/compaction/FileCompactor.java:
##########
@@ -313,7 +313,8 @@ public CompactionStats call() throws IOException,
CompactionCanceledException {
reader = fileFactory.newReaderBuilder()
.forFile(mapFile.getPathStr(), fs, fs.getConf(), cryptoService)
-
.withTableConfiguration(acuTableConf).withRateLimiter(env.getReadLimiter()).build();
+
.withTableConfiguration(acuTableConf).withRateLimiter(env.getReadLimiter())
+ .dropCachesBehind().build();
Review Comment:
@dlmarion this is setting the compaction input files to drop behind. Did
you consider setting it for the compaction output file as well?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]