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
719 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
  • 3
  • 2
5 Comments
 
LVL 41

Expert Comment

by:HonorGod
Comment Utility
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
Comment Utility
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
Comment Utility
ok. sorry for the confusion.

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

Accepted Solution

by:
_Esam earned 0 total points
Comment Utility
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
Comment Utility
Excellent!  Thank you so very much for sharing your solution.

Good luck & have a great day.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Suggested Solutions

Configure Web Service (server application) I. Configure security for Web Services methods First, we need to protect Session bean which implements the service: 1. Open EJB deployment descriptor (ejb-jar.xml) in the EJB project that contains you…
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.

763 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now