Also mmap terms index (`.tip`) files for hybridfs (#43150)
This change adds the terms index (`.tip`) to the list of extensions that are memory-mapped by hybridfs. These files used to be accessed only once to load the terms index on-heap but since #42838 they can now be used to read the binary FST directly so it is benefical to memory-map them instead of accessing them via NIO.
This commit is contained in:
parent
51618af056
commit
6cfed7ec72
|
@ -157,6 +157,7 @@ public class FsDirectoryFactory implements IndexStorePlugin.DirectoryFactory {
|
|||
case "nvd":
|
||||
case "dvd":
|
||||
case "tim":
|
||||
case "tip":
|
||||
case "cfs":
|
||||
return true;
|
||||
default:
|
||||
|
|
|
@ -61,6 +61,7 @@ public class FsDirectoryFactoryTests extends ESTestCase {
|
|||
assertTrue(hybridDirectory.useDelegate("foo.dvd"));
|
||||
assertTrue(hybridDirectory.useDelegate("foo.nvd"));
|
||||
assertTrue(hybridDirectory.useDelegate("foo.tim"));
|
||||
assertTrue(hybridDirectory.useDelegate("foo.tip"));
|
||||
assertTrue(hybridDirectory.useDelegate("foo.cfs"));
|
||||
assertFalse(hybridDirectory.useDelegate("foo.bar"));
|
||||
MMapDirectory delegate = hybridDirectory.getDelegate();
|
||||
|
|
Loading…
Reference in New Issue