aspose file tools*
The moose likes JBoss/WildFly and the fly likes Troubles deploying ear? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Products » JBoss/WildFly
Bookmark "Troubles deploying ear?" Watch "Troubles deploying ear?" New topic
Author

Troubles deploying ear?

Mike Blair
Greenhorn

Joined: Sep 10, 2003
Posts: 19
The details :
Using this turorial (http://www.roseindia.net/jboss/buildingwebapplicationwithant.shtml) I went through and built it successfully. I have the ear file created ok.
Running JBoss 3.2.1, I place the example2.ear in the server\default\deploy dir.
When I try to access it via a browser with http://localhost:8080/anttest/example2 I get a web page with the following:
Directory: /anttest/example2/
WEB-INF/ 0 bytes Sep 10, 2003 10:03:04 AM

If I have not given enough details, please let me know. This is my first attempt at deploying an ear and I just can't seem to get it to work.
Thanks for any and all tips!
Mike
norman richards
Author
Ranch Hand

Joined: Jul 21, 2003
Posts: 367
Originally posted by Mike Blair:

When I try to access it via a browser with http://localhost:8080/anttest/example2 I get a web page with the following:

Where did the /anttest come from? Your webapp is being deployed as /example2, right? Is that a typo or did you do something different from the tutorial?
Mike Blair
Greenhorn

Joined: Sep 10, 2003
Posts: 19
anttest was the root of the example. About 3/4 ways down the tutorial, there is a "Running ant utility to build example2.ear" and shows the output.... in the output it has the anttest as the root.
Thanks,
Mike
norman richards
Author
Ranch Hand

Joined: Jul 21, 2003
Posts: 367
When I look at the example at the URL you gave, I see:
<context-root>/example2</context-root>
If I don't see anything being deployed at /anttest.
Furthermore, I see the article suggesting to hit: http://localhost:8080/example2
You obviously have SOMETHING deployed to anttest, but it doesn't resemble anything in the tutorial at the URL sent out.
Mike Blair
Greenhorn

Joined: Sep 10, 2003
Posts: 19
Originally posted by norman richards:
When I look at the example at the URL you gave, I see:
<context-root>/example2</context-root>
If I don't see anything being deployed at /anttest.
Furthermore, I see the article suggesting to hit: http://localhost:8080/example2
You obviously have SOMETHING deployed to anttest, but it doesn't resemble anything in the tutorial at the URL sent out.

About 3/4's of the way downt the tutorial, it states :
"Now it's time to build example2.ear and deploy on the Jboss 3.0 application server.
To execute Ant utility go to c:\anttest\example2 directory and issue ant command.
"
This lead me to believe that my example2 dir needed to be UNDER anttest.
I redid this, and redeployed to c:\example2 and I get the same problem.
Would anyone want to try to deploy this on their machine to see if it works? I could zip the folder and shoot it off to anyone.
Thanks,
Mike
norman richards
Author
Ranch Hand

Joined: Jul 21, 2003
Posts: 367
That is your build directory and has no relationship to how you deploy the application. When you run the build command, you should have example2.ear being created. Then you copy example2.ear into server/default/deploy.
Is this what you did?
Mike Blair
Greenhorn

Joined: Sep 10, 2003
Posts: 19
Ok, a quick follow-up.
I found the example source on that site. I downloaded it and unzipped it using the original directory structure. It extracted it to the following structure.
c:\example\example2...
in c:\example\example2 is the example2.ear.
I took this ear and placed it in my deploy folder. I then went to http://localhost:8080/example2/ and it worked fine.
Now I just need to figure out where I went wrong in the tutorial.
Mike
Mike Blair
Greenhorn

Joined: Sep 10, 2003
Posts: 19
Originally posted by norman richards:
That is your build directory and has no relationship to how you deploy the application. When you run the build command, you should have example2.ear being created. Then you copy example2.ear into server/default/deploy.
Is this what you did?


Yep, this is exactly what I do.
Mike Blair
Greenhorn

Joined: Sep 10, 2003
Posts: 19
Norman, thank you so much for taking time to help me out!!!
You got my brain going in a different direction and I figured it out. Here is what was happening.
The .jsp was not being included in the .war file as it was not in the correct folder. So the build was making a .war without a jsp and hence the directory structure showing up in my browser.
Again, thanks a ton.
Next beer is on me!!
Mike
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Troubles deploying ear?
 
Similar Threads
installation of jboss-3.2.1_tomcat-4.1.24
Regd Web Hosting
Problem with EAR holding WAR and JAR files
Need the procedure for creating and deploying EAR,WAR files in JBoss3.2.5 Server
error in running the sample application