afs commented on issue #1846:
URL: https://github.com/apache/jena/issues/1846#issuecomment-1511339289
This is not a bug.
Here, the resource is returned from the function.
"return channel" passes out the file channel which has the random access
file.
The IDE/compiler does not track that FileChannel has a handle on
RandomAccesFile which is why there is `@SuppressWarnings("resource")`.
Channels are closed by ChannelManager.release --- although Channels are long
lived so in all likelihood, not closed except by JVM exit.
(NB Windows does not properly release memory mapped files anyway - long
standing Java issue that is "won't fix" in OpenJDK)
Jena is currently 4.7.0
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]