jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Richard van Nieuwenhoven (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (JCR-861) Connector should support LocalTransaction as well as XATransaction
Date Fri, 30 Nov 2012 13:25:59 GMT

    [ https://issues.apache.org/jira/browse/JCR-861?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13507319#comment-13507319
] 

Richard van Nieuwenhoven commented on JCR-861:
----------------------------------------------

Apache Jackrabbit would solve a lot of problems in our current Project, and we would like
to use it. But this issue is prohibiting it. We are bound to use WebSphere (currently version
8.5) and need the XA Transaction features of Jackrabbit.
In Websphere 8.5 we still get the exception:

{code}
[11/26/12 12:36:08:734 CET] 0000032a LocalTransact E   J2CA0077E: An exception was caught
while trying to obtain a javax.resource.cci.LocalTransaction f
rom a ManagedConnection for resource jcr/repository2. The exception is: java.lang.UnsupportedOperationException:
Local transaction is not supported
        at org.apache.jackrabbit.jca.JCAManagedConnection.getLocalTransaction(JCAManagedConnection.java:207)
        at com.ibm.ejs.j2c.LocalTransactionWrapper.initialize(LocalTransactionWrapper.java:170)
        at com.ibm.ejs.j2c.MCWrapper.getLocalTransactionWrapper(MCWrapper.java:1073)
        at com.ibm.ejs.j2c.MCWrapper.getLocalTransactionWrapper(MCWrapper.java:1042)
        at com.ibm.ejs.j2c.ConnectionManager.initializeForUOW(ConnectionManager.java:1960)
        at com.ibm.ejs.j2c.ConnectionManager.involveMCInTran(ConnectionManager.java:1706)
        at com.ibm.ejs.j2c.ConnectionManager.allocateConnection(ConnectionManager.java:1050)
        at org.apache.jackrabbit.jca.JCARepositoryHandle.login(JCARepositoryHandle.java:75)
        at org.apache.jackrabbit.server.SessionProviderImpl.getSession(SessionProviderImpl.java:88)
        at org.apache.jackrabbit.server.jcr.JCRWebdavServer$SessionCache.getRepositorySession(JCRWebdavServer.java:337)
        at org.apache.jackrabbit.server.jcr.JCRWebdavServer$SessionCache.get(JCRWebdavServer.java:232)
        at org.apache.jackrabbit.server.jcr.JCRWebdavServer$SessionCache.access$200(JCRWebdavServer.java:165)
        at org.apache.jackrabbit.server.jcr.JCRWebdavServer.attachSession(JCRWebdavServer.java:103)
        at org.apache.jackrabbit.webdav.server.AbstractWebdavServlet.service(AbstractWebdavServlet.java:247)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:668)
{code}

Because to use NoTransaction is no solution for us (we need XA). We added a filter that opens
(and commits) a user transaction. This works for normal requests but not for events. Then
we get this Exception:

{code}
[11/19/12 12:41:24:421 CET] 000000a3 servlet       E com.ibm.ws.webcontainer.servlet.ServletWrapper
service SRVE0068E: An exception was thrown by one of
 the service methods of the servlet [JCRWebdavServer] in application [eQuest-jackrabbit-webdav].
Exception created : [java.lang.IllegalStateException: I
nactive logical session handle called
        at org.apache.jackrabbit.jca.JCAManagedConnection.getSession(JCAManagedConnection.java:237)
        at org.apache.jackrabbit.jca.JCASessionHandle.getSession(JCASessionHandle.java:90)
        at org.apache.jackrabbit.jca.JCASessionHandle.getUserID(JCASessionHandle.java:104)
        at org.apache.jackrabbit.server.jcr.JCRWebdavServer$SessionCache.getUserID(JCRWebdavServer.java:409)
        at org.apache.jackrabbit.server.jcr.JCRWebdavServer$SessionCache.get(JCRWebdavServer.java:239)
        at org.apache.jackrabbit.server.jcr.JCRWebdavServer$SessionCache.access$200(JCRWebdavServer.java:165)
        at org.apache.jackrabbit.server.jcr.JCRWebdavServer.attachSession(JCRWebdavServer.java:103)
        at org.apache.jackrabbit.webdav.server.AbstractWebdavServlet.service(AbstractWebdavServlet.java:247)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:668)
        at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1214)
        at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:774)
        at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:456)
        at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
{code}

This issue is very old but i hope that somebody can help us solving this one! We would be
willing to do the testing an debugging if necessary. But we do not have the time to dig into
the code and solve it ourself. 
If somebody helps us getting Jackrabbit running XA under Webspere, i will go to the Management
and try to get a donation to Apache-Jackrabbit.

                
> Connector should support LocalTransaction as well as XATransaction
> ------------------------------------------------------------------
>
>                 Key: JCR-861
>                 URL: https://issues.apache.org/jira/browse/JCR-861
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-jca
>    Affects Versions: 1.2.3, 1.3
>         Environment: Websphere 5.1 and 6 on Linux, but may also apply on other platforms
>            Reporter: Adam Hatherly
>            Priority: Minor
>
> According to the Java connector specification, an application server may choose to use
a LocalTransaction rather than an XATransaction if it determines that an XATransaction is
not needed. Jackrabbit's connector code supports XA transactions but throws an exception if
the server requests a LocalTransaction. The JCA code should be able to support LocalTransaction
which could be easily mapped internally to calls to the XAResource interface.
> I get this problem when I deploy on Websphere 5.1 or WebSphere 6, specifying XATransaction
in the ra.xml file - in normal usage Websphere tries to obtain a LocalTransaction resulting
in the exception:
> [17/04/07 15:32:58:887 BST] 57053d6b LocalTransact E J2CA0077E: An exception was caught
> while trying to obtain a javax.resource.cci.LocalTransaction from a ManagedConnection
for
> resource jcr/local. The exception is: java.lang.UnsupportedOperationException: Local
transaction
> is not supported
> My only workaround at present is to specify NoTransaction, but that may not be a good
solution for many people.
> See post on jackrabbit users group from Wed, 18 Apr, 13:16 by Dominique Pfister.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message