[ 
https://issues.apache.org/jira/browse/DERBY-3457?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12572969#action_12572969
 ] 

Dyre Tjeldvoll commented on DERBY-3457:
---------------------------------------

Hi Kristian, I had a quick look at the patch, and I think it looks good.

Wrt. how to handle a failing close(), I'm wondering if Statement.close() can 
ever fail with a recoverable error? If it can't (and I don't think it can), 
then I think the current approach will work well. The cleanup is aborted, but 
presumably neither the physical statement or even the physical connection will 
be usable in this case, so a graceful bailout seems the best one can do...

I guess I don't fully understand your last comment. super.close() in CLC would 
refer to LogicalConnection.close(), right? But this method does not close any 
LogicalStatements, does it? It has a comment saying that it needs to do so, but 
it doesn't do it, I think. Is that to avoid the failure?

> Closing a logical connection must close all associated logical statements
> -------------------------------------------------------------------------
>
>                 Key: DERBY-3457
>                 URL: https://issues.apache.org/jira/browse/DERBY-3457
>             Project: Derby
>          Issue Type: Task
>          Components: JDBC, Network Client
>    Affects Versions: 10.4.0.0
>         Environment: Client-server with statement pooling enabled in the 
> client driver.
>            Reporter: Kristian Waagan
>            Assignee: Kristian Waagan
>             Fix For: 10.4.0.0
>
>         Attachments: derby-3457-1a-stmt_closing.diff, 
> derby-3457-1a-stmt_closing.stat, derby-3457-1b-stmt_closing.diff, 
> derby-3457-1c-stmt_closing.diff, derby-3457-2a-stmt_registration.diff
>
>
> When a logical connection is closed, all open logical statements created by 
> this connection must be closed.
> The closing is important per the general principle of cleaning up resources, 
> but especially so in the case of statement pooling, as not closing the 
> logical statement can cause side effects on another logical connection 
> (sharing the same physical connection).

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to