Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

New to Weblogic

 
Mike Jeya
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am new to weblogic..I am using weblogic6.1.
I mangaged to deploy a ear file..it contains a war an jar.
How can I access the Jsp inside that war?
 
Vikram Shinde
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Mike,
You must be having application.xml inside the .ear that you have deployed.
It will give you information of context root for the web application that you wish to use
e.g. <context-root>myApplication</context-root>
Now you need to use url of following type to access jsp's present in you web application "myApplication"
http://<host>:7001/myApplication/<jsp>
e.g. http://localhost:7001/myApplication/first.jsp

Cheers,
Vikram
 
Mike Jeya
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Vikram,
Thank u very much for ur reply,
I have some other questions also.

Please bear me if I ask some funny questions.
While deploying, I get error that META-INF/ejb-jar.xml is not found, unable to deploy..
Can you tell that where should I place ejb-jar.xml?
Thank u once again
 
Vikram Shinde
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Mike,
When you pack your .ear file its structure should be like this -
Assume that your ear file name is myEAR.ear
c:\myEAR
-----------\meta_inf\application.xml
-----------\DeployableEJB.jar
Here, DeployableEJB.jar is the one in which ejb-jar.xml should reside.
Sample structure for DeployableEJB.jar is as follows -
c:\DeployableEJB
-----------\meta_inf\ejb-jar.xml
-----------\meta_inf\weblogic-ejb-jar.xml
-----------\homeInterface.class
-----------\remoteInterface.class
-----------\bean.class
So now you could observe that all deployment descriptors are present in a directory "META_INF".
Hope this will help you.
Regards,
Vikram
 
j archie
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Iam also new to EJB & Weblogic, can you explain me how to code, compile (commands) and deploy in weblogic.
 
Mike Jeya
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Vikram,
Thank u.
I created a Example.war file has the following structure
\jsp-src\hello.jsp
\jsp-src\hello1.jsp
\meta-inf\application.xml
\web-inf\web.xml
i deployed this war file
in application.xml I made the following entry
<module>
<web>
<web-uri>Example</web-uri>
<context-root>Example</context-root>
</web>
</module>
I accessed using the following url
http://localhost:7001/Example/hello.jsp
But,I couldn't access that jsp.
error is:Error 404--Not Found
Can u tell me that what mistake am I doing?
Expecting reply.
Thank u
 
wei wu
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Remove application.xml in META-INF and add a manifest.mf instead.
application.xml is only used to list all the modules in an enterprise application rather than web application.
 
wei wu
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Remove application.xml in META-INF and add a manifest.mf instead.
application.xml is only used to list all the modules in an enterprise application rather than web application.
 
Mike Jeya
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I did like that . Still I am getting the same error.
 
wei wu
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The url should be http://host/Example/jsp-src/hello.jsp
 
Mike Jeya
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Still, I couldn't access the JSP.
I don't know that what mistake am I doing.

Do I need to change any configurationfiles?
can u help me on this?
Pls any one help me on this
 
Chris Mathews
Ranch Hand
Posts: 2712
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Mike,
Thanks for joining JavaRanch, but could you take a quick look at the naming policy and edit your profile accordingly.
 
Mike Jeya
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Now War file works fine.Thank you.
Today I restarted the weblogic. After that it works fine.
Thank u
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic