This content has been marked as final. Show 3 replies
Show the full stacktrace. Could it be that the statement is being closed after the connection was closed?
The rest of the stack trace is not relevant. But it is entirely possible I'm closing twice... but given this from the Interface docs:
Calling the method close on a Statement object that is already closed has no effect.
It would seem this is not correctly implemented, which is why I was confused. If you're telling me that it is not acceptable to call close() twice, then I can deal with that and move on.
It is indeed OK by spec to close a statement that has already been closed,
even if closed implicitly by having closed the connection, and if you find that
is what is causing the exception, you can certainly file an SR to get that fixed.
I was just saying that I've seen such exceptions caused by such behavior. If
you can easily code to close things once (the connection being the only
crucial one), then you could also just move on with that change.
The complexity (which does not excuse a bug) is that we are dealing with
RMI objects, and once/if the connection is closed, sub-objects (the
internal RMI referents) may no longer exist...
Edited by: Joe Weinstein on Mar 22, 2012 12:37 PM