[ http://issues.apache.org/jira/browse/DERBY-1020?page=comments#action_12414330 ]
Kathey Marsden commented on DERBY-1020: --------------------------------------- In a comment in DERBY-803, Deepa said: |Scenario is: Server is shutdown. One of the threads finds that the client |has disconnected. It tries to close the session but gets an exception |during rollback because the shutdown has already taken place. Yes I think this is the case. |In this scenario, since the client has already disconnected, can we ignore |the exceptions when closing the session? Then, we can pass a flag to |closeSession method asking to ignore exceptions if we are calling it |when we receive a DisconnectException in the server. Any |comments/suggestions ? I think that closeSession is really always an asynchronous cleanup operation and like garbage collection shouldn't ever fail. This operation performs a rollback so that it can close the connection because connection close will fail if a transaction is active. That is where the error always occurs when the database has been previously shutdown. In this case the close and cleanup should still happen normally. I was thinking perhaps one solution might be to add a new method to EngineConnection public void close(boolean force) which would close the connection without doing the active transaction check. That way (I think) the call would succeed regardless of the transaction or database state. > Network Server treats errors on cleanup of connections as an unexpected error > after intentional shutdown of the database/server > ------------------------------------------------------------------------------------------------------------------------------- > > Key: DERBY-1020 > URL: http://issues.apache.org/jira/browse/DERBY-1020 > Project: Derby > Type: Bug > Components: Network Server > Versions: 10.1.2.3, 10.1.3.0, 10.3.0.0, 10.2.0.0 > Reporter: Kathey Marsden > Priority: Minor > > Any exceptions that occur in the rollback and close of connections in > Session.close() are treated as unexpected errors and print to the console. > Exceptions that occur cleaning up the connection after intentional shutdown > are not really unexpected. > The console message can be disconcerting and intermittent as it depends on > time. It is the root cause of DERBY-273 and I believe DERBY-803 -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
