StatelessSession and Session both implement java.io.Closeabe, but their implementation is not idempotent according to Javadoc.
SessionImpl line 311:
The above is not compliant with java.io.Closeable contract.
Request is to do nothing if session is already close or to consistently expose isClosed() method to Session and StatelessSession. Currently isClosed() is a method of SessionImplementor, to which I must cast my session.
I have library code that tries to close session multiple times to ensure the developer did not forget to close the session in the outer-most object. And also calls to close() from finalizers to make 100% sure