If you ban this by policy, it should return false.
Instead today all writes will fail by default.
Bulk close for 5.3.0 release
Commit 1696003 from Michael McCandless in branch 'dev/trunk'
[ https://svn.apache.org/r1696003 ]
LUCENE-6618: move CHANGES.txt entry
Commit 1696002 from Michael McCandless in branch 'dev/branches/branch_5x'
[ https://svn.apache.org/r1696002 ]
Commit 1696001 from Michael McCandless in branch 'dev/branches/lucene_solr_5_3'
[ https://svn.apache.org/r1696001 ]
LUCENE-6618: MMapDirectory.checkUnmapSupported is buggy
Reopen for backport to 5.3.0
Should we backport this to 5.3.0 for the 2nd RC?
Commit 1695865 from Robert Muir in branch 'dev/branches/branch_5x'
[ https://svn.apache.org/r1695865 ]
Commit 1695859 from Robert Muir in branch 'dev/trunk'
[ https://svn.apache.org/r1695859 ]
After chatting with Robert, I understand now what the problem is: The main reason for the setAccessible is to have the same check as done while executing the unmapping. If you don't do the setAccessible,the reflection works, although it may fail later when doing the unmapping.
Simple patch. I also removed the builder-like chaining here.