users@glassfish.java.net

maven / remote EJB client for deployment in JBoss AS?

From: Kristian Rink <kr_at_zimmer428.net>
Date: Tue, 13 Nov 2012 13:45:21 +0100

Folks;

having a standalone Java EE client built and running using maven (good), I am
trying to take the next step and do as needed - build a web app supposed to
run as part of an enterprise application deployed to a JBoss AS 7.1.1.

So far, however, I see maven2 build for Glassfish standalone clients is a bit
cumbersome; at the moment I have

                <dependency>
                        <groupId>org.glassfish.appclient</groupId>
                        <artifactId>gf-client</artifactId>
                        <version>3.1</version>
                        <type>pom</type>
                        <scope>compile</scope>
                </dependency>


as a dependency in that very module which adds roughly 40 megs of jars to the
project. Adding this setup to a webapp and trying to deploy this to JBoss
makes the JBoss deployer massively complain about things like this...

[...]
        at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_33]
Caused by: java.lang.IllegalArgumentException: JBAS015533: Web Service
endpoint com.sun.xml.ws.tx.coord.v11.endpoint.RegistrationPortImpl with URL
pattern /RegistrationService_V11 is already registered. Web service endpoint
com.sun.xml.w
s.tx.coord.v11.endpoint.RegistrationRequesterPortImpl is requesting the same
URL pattern.
        at
org.jboss.as.webservices.metadata.model.AbstractDeployment.addEndpoint(AbstractDeployment.java:60)
        at
org.jboss.as.webservices.metadata.model.JAXWSDeployment.addEndpoint(JAXWSDeployment.java:27)
[...]


... before ultimately stopping deployment. Looking at the kind of jars in the
gf-client pom project, I am not really surprised to see this causing problems,
yet I of course would like to see it work. Can anyone out here point me out
(a) which jars out of gf-client would be required to deploy such a structure
to another application server and/or (b) whether there is a "cleaner" way for
building such things via maven other than adding _all_ the code to the project
via this large pom?

TIA and all the best,
Kristian