Eclipse fails to deploy ear on Jboss [message #1066924] |
Fri, 05 July 2013 03:29  |
Eclipse User |
|
|
|
When I Drag&Drop the folder with the .ear file to the server in the Servers-Tab, the deployment fails. I am using eclipse 4.3 (but any 4.x does) and JBoss EAP 6.0. My ear looks like this:
A.jar
|-META-INF
|-/lib
|-B.jar
|-C.jar
The problem is that eclipse/Jboss extracts the jars from the /lib folder to the root level, so it looks like this on the JBoss:
A.jar
B.jar
C.jar
/lib/ -empty-
/META-INF/
As a consequence the paths are wrong and deployment fails.
Now I can do this:
I make a rightclick on the ear-folder and then choose "Configure->Convert to Maven Project" - and then I see a small "M" on the folder in the project explorer. Then I build the folder again with "Rightclick->Run as...->Maven install".
Afterwards I repeat the Drag&Drop to the server tab - and out of a wonder it deploys correctly! And the jars remain correctly in the subfolder /lib.
But as soon as I do "Rightclick->Disable Maven Nature" (small M sign on folder is gone) it fails again on Drag&Drop deployment! This process is reproducable anytime.
Why is this so? Is it a bug? Why does it ONLY work when I do "Convert to Maven Project" (although it already is a Maven Project)? Please someone clarify this, as it is quite annoying.
|
|
|
|
|
Re: Eclipse fails to deploy ear on Jboss [message #1066970 is a reply to message #1066956] |
Fri, 05 July 2013 05:36  |
Eclipse User |
|
|
|
I'm using JBoss Tools from marketplace already. Besides I elaborated the task and found that this "convert to maven project" creates an additional "m2e-wtp" folder in the target directory. Obviously it depends on this directory to make the Drag&Drop-deployment correctly. This additional directory also appears if one does "righclick on folder-> project facets->Jboss Maven integration".
I'm sorry if I didn't post in the correct subforum, as I don't know where exactly the error lies. It looked to me that the simple Drag&Drop feature (which exists from the beginning in an eclipse installation) does somehow an error itself, therefore I wrote in here.
However it still does not make sense, because - why is there Drag&Drop possible in the first place if it doesn't work correctly, except doing some workaround...
[Updated on: Fri, 05 July 2013 05:37] by Moderator
|
|
|
Powered by
FUDForum. Page generated in 0.03502 seconds