-
Bug
-
Resolution: Fixed
-
Highest
-
7.0.1, 7.4.6, 7.13.0
-
16
-
Severity 2 - Major
-
95
-
Issue Summary
Confluence Lucene connection uses NIOFSDirectory implementation rather than MMapDirectory in Java 11
Steps to Reproduce
- Install any Confluence version above 7.X that has support for Java 11
- The underlying Lucene uses NIOFSDirectory implementation rather than MMapDirectory which is more efficient
Expected Results
Confluence should use MMapDirectory with Java 11 as it was with Java 8
Actual Results
Confluence uses NIOFS implementation . This can result in multiple outcomes
- At scale, this method can be notably less performant for index lookups and searches
- Conditionally this results in situations where customers are presented with below error that requires a restart of the instance
aused by: java.io.IOException: null: NIOFSIndexInput(_f2fd_Lucene41_0.tim in path="/var/atlassian/application-data/confluence/index/_f2fd.cfs" slice=2604086:9597840) at org.apache.lucene.store.NIOFSDirectory$NIOFSIndexInput.readInternal(NIOFSDirectory.java:191) ... 143 more Caused by: java.nio.channels.ClosedByInterruptException
This is a known behaviour for NIOFS class https://lucene.apache.org/core/3_5_0/api/all/org/apache/lucene/store/NIOFSDirectory.html
- NOTE: Accessing this class either directly or indirectly from a thread while it's interrupted can close the underlying file descriptor immediately if at the same time the thread is blocked on IO. The file descriptor will remain closed and subsequent access to NIOFSDirectory will throw a ClosedChannelException. If your application uses either Thread.interrupt() or Future.cancel(boolean) you should use SimpleFSDirectory in favor of NIOFSDirectory.
Workaround
Downgrade to Java 8
- mentioned in
-
Page Failed to load
-
Page Failed to load
-
Page Failed to load
-
Page Failed to load
-
Page Failed to load
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
Form Name |
---|
Hi All,
It seems like there was an oversight on the paperwork for this fix.
We implemented the backport for this issue in Confluence 7.13.6 on 16 May 2022, but unfortunately that wasn't reflected on this ticket.
I've corrected that oversight, apologies for the oversight.
Thanks,
James Ponting
Engineering Manager - Confluence Data Center