[
https://issues.apache.org/jira/browse/CXF-2398?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12746211#action_12746211
]
William Tam commented on CXF-2398:
----------------------------------
I don't think we are reading it any differently but It says this right in your
quote:
"It (the container) invokes ManagedConnection.cleanup when it has to invalidate
all
connection handles associated with this ManagedConnection instance ..."
It clearly mandates that it is JCA connector's responsibility to invalidate all
the handles when ManagedConnection.cleanup(). You could invalidate individual
handle in handleCloseMethod() upon connection.close() which is driven by the
application but we are still required to invalidate all the handles in
cleanup() which is driven by container/application server.
The only question is what constitutes a "handle" and thus what should be
invalidated.
Your view:
the target service proxy should NOT be invalidated when the associated handle
is closed.
My view:
the target service proxy should be invalidated when the associated handle is
closed.
When the application closes a connection, we should not allow the application
to access any resource associated with the closed connection. I think it makes
the contract much more clear and intuitive. Otherwise, how would you document
how long the target service (client proxy) can remain usable after a connection
has been closed?
I think the intention for your quotation is to point out that there is a window
between the application calls connection.close() and the container calls
ManagedConnection.cleanup(). True, but the window is tiny comparing with the
window when ManagedConnection.destroy() is called. We could add a member in
the handle similar to your suggestion but it also blocks invocation made to the
target service if the associated handle has been closed. Then, there would be
no window.
> JMS Connections are not closed when JCA recycles CXF proxy
> ----------------------------------------------------------
>
> Key: CXF-2398
> URL: https://issues.apache.org/jira/browse/CXF-2398
> Project: CXF
> Issue Type: Bug
> Components: Integration
> Affects Versions: 2.1
> Reporter: Seumas Soltysik
> Assignee: Daniel Kulp
> Fix For: 2.1.7, 2.2.4
>
> Attachments: CXF-2398.patch, CXF-2398.patch2
>
>
> When close() is called on JCA ConnectionHandler, there is no cleanup of the
> underlying client proxy and its transport. Specfically when the JCA outbound
> use case is using JMS, JMS connections are not being closed.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.