Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

How to package an EAR file for a struts, ejb, and utility module for WebSpher 6.1 using RAD 7.5.1?

Posted on 2009-05-03
5
Medium Priority
?
736 Views
Last Modified: 2013-12-11
Hi,
I have an application that uses struts 1.3.8 with the web module.
It also uses an ejb  module and an utility module for the ejb module.

Now when I run this application on the local test server for webspher 6.1 it runs fine.

But when I export it as an EAR module, then try to deploy it on local server, it does not run properly.
The server complaints which looks like ... the app can't find the classes for the utility module.
 
I can't seem to find out why this is the case.
Can someone shed me some light as to how to package this EAR properly so that the ejb module can find the dependent utility module so that it can be exported and then run properly?

Thanks much,
_Esam
0
Comment
Question by:_Esam
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 41

Expert Comment

by:HonorGod
ID: 24294130
So you are trying to have a stand-alone application that allows you to connect to some EJB's on your WebSphere Application Server?

If this is the case, you need the Application Client

http://publib.boulder.ibm.com/infocenter/wasinfo/v6r1/index.jsp?topic=/com.ibm.websphere.base.doc/info/aes/ae/ccli_appclients.html
0
 

Author Comment

by:_Esam
ID: 24294767
So you are trying to have a stand-alone application that allows you to connect to some EJB's on your WebSphere Application Server?
NO.
I did say that I am trying to export the ear file (Enterprise Application) which has a web module that uses struts, it also has an ejb module (this ejb module is within the enterprise application and it uses some java utility classes) ....

Looks like when it is exported, it can't find these utility classes which the ejb needs...
It runs run when I run from within RAD but when I export the ear and then deploy and run it .. it can't find those utility classes...

I believe I am clear...
Let me know.

Thanks.
_Esam
0
 
LVL 41

Expert Comment

by:HonorGod
ID: 24294831
ok. sorry for the confusion.

When you export the EAR, does the export succeed?
0
 

Accepted Solution

by:
_Esam earned 0 total points
ID: 24295386
I figured out the problem.
As I noted earlier, when I run the app from within RAD on the local test server, it runs fine.
But when I export the ear (the export succeeds), and then deploy it on local server, it seems like it can't find the utility classes needed by the ejb module...
So, I made some changed on how the WebSphere loads the classes...
For my app, I changed "Class Loading and update detection"
For class loader order > Classes loaded with application class loader first
For WAR class loader policy > Single class loader for application

Once I made these changes, the app was able to find the classes, and the app runs fine now...

_Esam.
0
 
LVL 41

Expert Comment

by:HonorGod
ID: 24296032
Excellent!  Thank you so very much for sharing your solution.

Good luck & have a great day.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most of the developers using Tomcat find it easy to configure the datasource in Server.xml and use the JNDI name in the code to get the connection.  So the default connection pool using DBCP (or any other framework) is made available and the life go…
Upgrading Tomcat – There are a couple of methods to upgrade Tomcat is to use The Apache Installer is to download and unzip and run the services.bat remove|install Tomcat6 Because of the App that we are working with, we can only use Tomcat 6.…
The viewer will learn how to implement Singleton Design Pattern in Java.
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question