IllegalArgumentException when installing a warbundle on Fuse 6.2
tiago.matias Oct 31, 2015 2:32 PMWhen trying to add a WAR to a feature I always get this error:
Provision Exception: java.lang.IllegalArgumentException: No path specified on clause: war:mvn:eu.my.intranet/my-hub-web/1.0.1/war?Web-ContextPath=xpto
I used the following method:
JBossFuse:admin@root> profile-edit -b war:mvn:eu.my.intranet/my-hub-web/1.0.1/war?Web-ContextPath=xpto my-web-profile
Adding bundle:war:mvn:eu.my.intranet/my-hub-web/1.0.1/war?Web-ContextPath=xpto to profile:my-web-profile version:1.0
However, if I instead drag and drop the WAR as built by maven onto the webconsole (hawtio) no error occurs although i cannot access the web application (404 error)
JBossFuse:admin@root> container-info my-web-container
Name: my-web-container
Version: 1.0
Connected: true
Type: karaf
Root: false
Ensemble Server: false
Managed: true
Process ID: 4320
Resolver: localhostname
Network Address: DESKTOP-JRFU5KR
Local Network Address: 192.168.1.122
Public Network Address:
Local Hostname: DESKTOP-JRFU5KR
Public Hostname:
SSH Url: DESKTOP-JRFU5KR:8102
JMX Url: service:jmx:rmi://DESKTOP-JRFU5KR:44445/jndi/rmi://DESKTOP-JRFU5KR:1100/karaf-my-web-container
Http Url: http://DESKTOP-JRFU5KR:8182
Jolokia Url: http://DESKTOP-JRFU5KR:8182/jolokia
Blueprint Status: started
Provision Status: success
JBossFuse:admin@root> profile-display my-web-profile
Profile id: my-web-profile
Version : 1.0
Attributes:
abstract: false
parents: my-base-profile
Containers: my-web-container
Container settings
----------------------------
Features :
war
my-web-feature
Bundles :
mvn:eu.my.intranet/my-hub-web/1.0.1-SNAPSHOT/war
Agent Properties :
lastRefresh.my-web-profile = 1446250595660
Configuration details
----------------------------
Other resources
----------------------------
Resource: dependencies/requirements.json
Checking the target container, the application appears to "be there"
JBossFuse:admin@root> container-connect my-web-container Connected(..)JBossFuse:admin@my-web-container> web:list ID State Web-State Level Web-ContextPath Name [ 196] [Active ] [Deployed ] [ 80] [/xpto ] My web application (1.0.1.SNAPSHOT)
but I then get these errors on the child container log.
java.lang.NoClassDefFoundError: javax/servlet/ServletContextListener java.lang.NoClassDefFoundError: javax/servlet/Filter java.lang.NoClassDefFoundError: javax/servlet/http/HttpServlet
So the Servlet API is missing. I don't know that to add more to the profiles to enable it (besides the war feature). Here's my POM of the web application (it's a spring+hibernate application and works with wildfly without problems).
Can someone point me to the right direction? I feel that this must be an obvious solution that I'm not seeing
I'm sorry for the lengthy paste. I simplified most of the dependencies and eclipse's build plugins