Can you share more info on the deployment and exception you get?
Thank you Alessio for the response. Please see the attached logs from JBoss 7 and JBoss 6.1.0. I have two webservices in our app. One is EJB based (packaged inside the EJB jar) and the other one is POJO based (packaged inside a war). They both are packaged indise a EAR file that is deployed in JBoss. I do not have any problem with EJB based service (WmsService). It is the POJO based service (UploadService) that got messed up as far as the URL is concerned. If you open the JBoss 6 log file and search for 'UploadService' you will see the deployment info for this service including the URL. Apparently the deployment info for JBoss 7 also the same but it does not work in 7 as it is not able to complete the deployment process.
Here is the web.xml contents relating to the POJO service:
<!-- Upload Users & Certificates web service -->
Am I missing anything here? Appreciate your help.
The problem seems to be in the context-root for the jse endpoint being an empty string. That's the case for both AS6 and AS7 afaics from the logs; AS7 throws an exception because it has an additional component that relies on the endpoint context-root creating an AS7 MSC service name.
So, the actual issue is in the context root being empty. Can you share any descriptor / configuration you have at ear leve (perhaps an application.xml ) that might influence that? Also, how is you packaged app at the end? I assume you have infolinkApp.ear which contains infolink-ejb.jar and infolink-web.war. What about descriptors in the ear? Do you also have a jboss-web.xml descriptor controlling the context root in the war archive?
Your assumption about the contents
<?xml version="1.0" encoding="UTF-8"?>
<display-name>InfoLink Software Application</display-name>
As you can see, our context root is / and we wanted it at root. It used to work just fine in NATIVE stack. Therefore I am inclined to believe that it is CXF vs NATIVE issue. Is it possible to have context root for the application at root level (/) and a separate context root (/upload ) for the web sevices? Is so, how do I set that up? Appreciate your help.
1 of 1 people found this helpful
OK, the application.xml explains to me where that "/" comes from.
I've created https://issues.jboss.org/browse/JBWS-3342 for the bug, you can monitor that if you want; it's scheduled for the next major release, should be done by the time AS 7.1 goes final.
In the mean time, as a workaround, you can consider splitting the infolink-web.war (if doable) into two wars, one for the ws endpoints only and the other one for the rest of the web app. Then you set "/upload" as context root for the ws endpoint war.
Thanks for the feedback, very much appreciated.
Thank you Alessio. Will keep an eye on that. Splitting webservices piece involves a lot of rehashing so we would rather not go that route. In the mean time, is it possible to replace CXF stack with native on AS7? If so how do I do that?
Regarding native on AS7, it's currently possible (might not be the case in the future); you need to download jbossws-native sources and install against AS 7 (ant -Djboss700.home=... deploy-jboss700)
Tried that and ran into issues. What am I doing wrong?
C:\jbossws-native>ant -Djboss700.home="C:\Program Files\jboss-as-7.0.0.Final" deploy-jboss700
[mkdir] Created dir: C:\jbossws-native\modules\dist\target
[exec] [INFO] Scanning for projects...
[exec] [ERROR] The build could not read 1 project -> [Help 1]
[exec] [ERROR] The project org.jboss.ws.native:jbossws-native:4.0.0-SNAPSHOT (C:\jbossws-native\pom.xml) has 1 er
[exec] [ERROR] Non-resolvable parent POM: Could not find artifact org.jboss.ws:jbossws-parent:pom:1.0.10-SNAPSH
OT and 'parent.relativePath' points at wrong local POM @ line 24, column 11 -> [Help 2]
[exec] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[exec] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[exec] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[exec] [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException
[exec] [ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException
Never mind Alessio. After going thru your document about mavenization of the build process and setting up the settings.xml file properly, I am able to build it now. Appreciate your help.