5 Replies Latest reply on Feb 12, 2008 8:37 AM by Andrew Dinn

    Basic deployment question

    dominik heller Newbie

      Hi there,
      for evaluating XTS I have build a test client and a test service close to the demo nightout. The client as the service are deployed in seperate EAR files whereas every ear has the ws*.war files and the jar files in it for.

      So my question right now, do both, the client and the service, share the same transaction manager? The client and the service have slightly different deployment descriptors but when running the transaction it seems that the AS would use the deployment descriptors which have been deployed at last.

      thx

        • 1. Re: Basic deployment question
          Jonathan Halliday Master

          There is only one transaction manager in use as the coordinator for any given transaction, although more than one may be deployed concurrently in the same app server.

          Because XTS's messaging style means both clients and servers need to receive messages (i.e. all clients are also servers) it's easiest just to deploy the full stack with everything that may need any part of it. The XTS demo shows how to deploy a 'standalone' coordinator and configure applications to use that if you wish.

          This will change in future releases, as we'll deploy the XTS transaction manager as a separate .sar and the applications that use it, be they clients or web services, will just look it up via JNDI.

          • 2. Re: Basic deployment question
            dominik heller Newbie

            Ok so I don't need a standalone coordinator, actually I was looking for the exact place where the endpoints for the participant and the completionInitiator are defined and I just stumbled across the question about the trtansaction manager. so do I assume correctly that because I have only one transaction manager this transactionmanager contains the endpoints for both the service and the client?

            thx for helping

            • 3. Re: Basic deployment question
              Andrew Dinn Master

              The endpoints are currentlyimplemented by the deployed XTS code, not the transaction manager (jbossjta) code. They are specified via the web.xml files inserted into ws-c.war and ws-t.war. A single servlet (the multiplexor servlet) filters messages to either service endpoints or client (reply) endpoints. The paths used to route these messages are established by the initialisation classes mentioned in the listener specifications. The initialisation classes also set up service endpoint implentation (SEI) instances to catch the messages.

              So, in the service war incoming messages will be routed to service SEI instances while in the client war responses will be routed to a client response SEI instance which notifies the client of the result.

              If you include the war files unchanged in each of your ears then you will also have client reply endpoints registered for your service ear servlet and service endpoints registered for your client ear servlet. However, they should not get exercised.

              You do need to ensure that the client and server ears deploy their multiplexor servlet using different paths.

              • 4. Re: Basic deployment question
                dominik heller Newbie

                Hi adinn,
                well I modified the paths of the multiplexor servlet and now I have two Multiplexor Servlets deployed, up and running. The thing is that it seems that still only one multiplexor servlet is used. So in order to make sure that I understand this right I recap a little bit.

                So by deploying a client and a service in separate ear files, each containing a full xts stack, to an AS, both the client and the service would use the same TransactionManager which acts as coordinator although that more than one is deployed. In ws-c.war and ws-t.war all the listener are defined which will be used for coordinating the transaction. In ws-c.war it is possible to modify the multiplexor servlet to determine the path to the separate endpoints of the TM e.g. @host@:@port@/xts_test/soap

                So what happens now is that by modifying the multiplexor servlet the client and the service both use the path that has been deployed at last. So do I assume coorectly that this is because they both share the same TM?

                Well I know that some of this has allready been answered but I am really stuck here right now. So thanks in advance for helping

                • 5. Re: Basic deployment question
                  Andrew Dinn Master

                   


                  So what happens now is that by modifying the multiplexor servlet the client and the service both use the path that has been deployed at last. So do I assume coorectly that this is because they both share the same TM?


                  You need to make sure that your client accesses the coordinator deployed in your server ear via the correct URL. Look at README.txt in the coordinator directory for instructions on how to point the client at the coordinator.