users@glassfish.java.net

Transaction error when calling 1 webservice from another

From: <glassfish_at_javadesktop.org>
Date: Wed, 25 Aug 2010 17:14:10 PDT

Hi all, I'm having a prob calling 1 soap webservice from another.

WebService A is my main app, deployed securely in GlassFish 3, and it's a client of WebService B, which is also deployed securely, in GlassFish 2 on another server.

When I call WebService B directly from Soap UI, I see the following severe log msg:

WSTX-SERVICE-5002: A JTA Transaction MUST NOT exist entering WS-TX Service Pipe procesing for binding '{http://ws.mydomain.com/}MyServicePortBinding' and operation 'operation1'. JTA Transaction is J2EETransaction: txId=3 nonXAResource=null jtsTx=com.sun.jts.jta.TransactionImpl@ca6b 332b localTxStatus=0 syncs=[]|#]

In spite of this msg, I get a successful result back from the service.


When I call WebService B from WebService A, which is what I need, I see the following log msgs on B:

WSTX-COORDINATOR-3006: register sent to EPR '
<K?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<KEndpointReference xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">
        <KAddress>https://MarcJay-PC:8181/__wstx-services/wscoor/coordinator/register
        <K/Address>
        <KReferenceParameters>
        <Kjaxws:objectId xmlns:ns2="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns="http://schemas.xmlsoap.org/ws/2004/10/wscoor" xmlns:jaxws="http://jax-ws.dev.java.net/xml/ns/" xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:ns3="http://schemas.xmlsoap.org/soap/envelope/">5bf29fdf-05dc-4414-b771-63e5ac0db68f
        <K/jaxws:objectId>
        <K/ReferenceParameters>
<K/EndpointReference>' failed for activityId 'uuid:WSCOOR-SUN-6cbf15b8-bf3e-49c1-a956-56927b60129f'. Nested exception: 'HTTP transport error: java.net.ConnectException: [b]Connection refused[/b]'|#]
WSTX-AT-0022: Registration with durable parent failed: ' coordId=uuid:WSCOOR-SUN-6cbf15b8-bf3e-49c1-a956-56927b60129f partId:2 '|#]

and WebService A (the caller of B) throws this exception:

WSTX-AT-0004: while registering ATCoordinator as an XAResource, received exception 'Local transaction already has 1 non-XA Resource: cannot add more resources.



WebService A is calling B from within a slsb with @TransactionManagement(TransactionManagementType.CONTAINER)
and with other attributes specified in the method header, which should mean it defaults to TransactionAttributeType.REQUIRED.

I'm not sure if 'MUST NOT exist' was intended to mean 'should not exist', or 'does not exist'. But since there are error msgs whether I call service B from within a txn or not, I'm assuming something's wrong with my deployment..

Let me know if any ideas.
Thanks,
Jay
[Message sent by forum member 'jayspex']

http://forums.java.net/jive/thread.jspa?messageID=481015