The condurum is that you need STRUTS.JAR in the classpath when building
struts applications, but it must not be in the classpath while running
Struts Web Applications. This is because Tomcat can get confused about
which STRUTS.JAR to use.

So, if you are building and testing on the same machine, then the
solution is to use a tool like ANT to add Struts to the classpath
dynamically. But it should not otherwise be on the classpath of the
machine serving the Struts application. (Too many cooks!)

*********** REPLY SEPARATOR  ***********

On 1/8/2001 at 4:47 PM Nishant Baranwal wrote:

I had a similar problem with tomcat...
Having looked at your classpath setting.....i find struts.jar being set
in the classpath......struts.jar file needs to be in the lib directory
of your web application i.e. /web-inf/lib...... only.
I removed struts.jar from my class path and had it only in the lib
folder.
This actually solved my problem.
You can try this too.

Nishant Baranwal
Project Leader
Nihilent Technologies Pvt. Ltd., Pune
Phone: 91-20-6054452/6052253
Mobile: 9823078613



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Saturday, January 06, 2001 6:02 AM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: PLEASE PRETTY PLEASE HELP ME


Hi,

I have WLS 5.1 with SP6, Struts 0.5, Xalan-j_1_2_2 and xercs-1_2_3
installed
on my machine. I have added the classpaths to weblogic and here is a
sample.
WebLogic startup settings are presently:

CLASSPATH Prefix
D:\weblogic\lib\weblogic510sp6boot.jar;D:\Apache\xalan-j_1_2
_2\xalan.jar;D:\Apache\xerces-1_2_3\xerces.jar;D:\Apache\jakarta-struts-

0.5\
lib\
struts.jar
CLASSPATH
D:\weblogic\lib\weblogic510sp6boot.jar;D:\Apache\xalan-j_1_2
_2\xalan.jar;D:\Apache\xerces-1_2_3\xerces.jar;D:\Apache\jakarta-struts-

0.5\
lib\
struts.jar;D:\weblogic\jre1_2\lib\tools.jar;D:\weblogic\jre1_2\jre\lib\r

t.ja
r;D:
\weblogic\jre1_2\jre\lib\i18n.jar;D:\weblogic\license;D:\weblogic\classe

s\bo
ot;D
:\weblogic\classes;D:\weblogic\lib\weblogicaux.jar;D:\weblogic\eval\clou

dsca
pe\l
ib\cloudscape.jar
JAVA_HOME           D:\weblogic\jre1_2
WEBLOGIC_LICENSEDIR D:\weblogic\license
WEBLOGIC_HOME       D:\weblogic
system properties:
                    java.security.manager
                    java.security.policy==D:\weblogic\weblogic.policy
                    weblogic.system.home=D:\weblogic
                    java.compiler=symcjit
 
weblogic.class.path=D:\weblogic\lib\weblogic510sp6.jar;d:\We
blogic\license;d:\Weblogic\classes;d:\Weblogic\myserver\serverclasses;d:

\Web
logi
c\lib\weblogicaux.jar
INITIAL_HEAP        64 MB
MAX_HEAP            64 MB
SERVERCLASSPATH
D:\weblogic\lib\weblogic510sp6boot.jar;D:\Apache\xalan-j_1_2
_2\xalan.jar;D:\Apache\xerces-1_2_3\xerces.jar;D:\Apache\jakarta-struts-

0.5\
lib\
struts.jar;D:\weblogic\jre1_2\jre\lib\rt.jar;D:\weblogic\jre1_2\jre\lib\

i18n
.jar
;D:\weblogic\classes\boot;D:\weblogic\eval\cloudscape\lib\cloudscape.jar


When weblogic starts up it fails with the following error:
Fri Jan 05 19:13:52 EST 2001:<I> <WebLogicServer> Invoking T3StartupDef
StartDatabaseServlet weblogic.servlet.utils.ServletStartup with
{servlet=db}
Fri Jan 05 19:13:52 EST 2001:<I> <ServletContext-General> db: init
Fri Jan 05 19:13:53 EST 2001:<E> <ServletContext-General> db: Database
load
exception
java.lang.ClassNotFoundException: org/apache/struts/example/User
        at
org.apache.struts.digester.Digester.startElement(Digester.java,
Compiled Code)
        at
org.apache.xerces.parsers.SAXParser.startElement(SAXParser.java,
Compiled Code)
        at
org.apache.xerces.validators.common.XMLValidator.callStartElement(XMLVal

idat
or.java, Compiled Code)
        at
org.apache.xerces.framework.XMLDocumentScanner.scanElement(XMLDocumentSc

anne
r.java, Compiled Code)
        at
org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatc

h(XM
LDocumentScanner.java, Compiled Code)
        at
org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentScan

ner.
java, Compiled Code)
        at
org.apache.xerces.framework.XMLParser.parse(XMLParser.java:948)
        at javax.xml.parsers.SAXParser.parse(SAXParser.java:345)
        at javax.xml.parsers.SAXParser.parse(SAXParser.java:143)
        at org.apache.struts.digester.Digester.parse(Digester.java:748)
        at
org.apache.struts.example.DatabaseServlet.load(DatabaseServlet.java:282)

        at
org.apache.struts.example.DatabaseServlet.init(DatabaseServlet.java:175)

        at javax.servlet.GenericServlet.init(GenericServlet.java:258)
        at
weblogic.servlet.internal.ServletStubImpl.createServlet(ServletStubImpl.

java
:474)
        at
weblogic.servlet.internal.ServletStubImpl.createInstances(ServletStubImp

l.ja
va, Compiled Code)
        at
weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl

.jav
a:421)
        at
weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl

.jav
a:342)
        at
weblogic.servlet.utils.ServletStartup.startup(ServletStartup.java:36)
        at
weblogic.t3.srvr.StartupThread.runStartup(StartupThread.java:182)
        at weblogic.t3.srvr.StartupThread.doWork(StartupThread.java,
Compiled Code)
        at
weblogic.t3.srvr.PropertyExecuteThread.run(PropertyExecuteThread.java:62

)

Fri Jan 05 19:13:53 EST 2001:<I> <WebLogicServer> T3StartupDef
StartDatabaseServlet weblogic.servlet.utils.ServletStartup
reports:servlet:
db unable to initialize.
javax.servlet.UnavailableException: Cannot load database from 'null'
        at
org.apache.struts.example.DatabaseServlet.init(DatabaseServlet.java:180)

        at javax.servlet.GenericServlet.init(GenericServlet.java:258)
        at
weblogic.servlet.internal.ServletStubImpl.createServlet(ServletStubImpl.

java
:474)
        at
weblogic.servlet.internal.ServletStubImpl.createInstances(ServletStubImp

l.ja
va, Compiled Code)
        at
weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl

.jav
a:421)
        at
weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl

.jav
a:342)
        at
weblogic.servlet.utils.ServletStartup.startup(ServletStartup.java:36)
        at
weblogic.t3.srvr.StartupThread.runStartup(StartupThread.java:182)
        at weblogic.t3.srvr.StartupThread.doWork(StartupThread.java,
Compiled Code)
        at
weblogic.t3.srvr.PropertyExecuteThread.run(PropertyExecuteThread.java:62

)

Fri Jan 05 19:13:53 EST 2001:<I> <WebLogicServer> Invoking T3StartupDef
StartActionServlet weblogic.servlet.utils.ServletStartup with
{servlet=*.do}
Fri Jan 05 19:13:53 EST 2001:<I> <ServletContext-General> *.do: init
Fri Jan 05 19:13:53 EST 2001:<I> <ServletContext-General> *.do: Loading
application resources from resource
org.apache.struts.example.ApplicationResources
Fri Jan 05 19:13:53 EST 2001:<E> <ServletContext-General> *.do: Cannot
load
application resources bundle
org.apache.struts.example.ApplicationResources
java.util.MissingResourceException: Can't find resource for base name
org.apache.struts.example.ApplicationResources, locale en_US
        at java.util.ResourceBundle.getBundle(ResourceBundle.java:423)
        at java.util.ResourceBundle.getBundle(ResourceBundle.java:339)
        at
org.apache.struts.util.MessageResources.<init>(MessageResources.java:102

)
        at
org.apache.struts.util.MessageResources.getMessageResources(MessageResou

rces
.java:579)
        at
org.apache.struts.action.ActionServlet.initApplication(ActionServlet.jav

a:49
4)
        at
org.apache.struts.action.ActionServlet.init(ActionServlet.java:289)
        at javax.servlet.GenericServlet.init(GenericServlet.java:258)
        at
weblogic.servlet.internal.ServletStubImpl.createServlet(ServletStubImpl.

java
:474)
        at
weblogic.servlet.internal.ServletStubImpl.createInstances(ServletStubImp

l.ja
va, Compiled Code)
        at
weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl

.jav
a:421)
        at
weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl

.jav
a:342)
        at
weblogic.servlet.utils.ServletStartup.startup(ServletStartup.java:36)
        at
weblogic.t3.srvr.StartupThread.runStartup(StartupThread.java:182)
        at weblogic.t3.srvr.StartupThread.doWork(StartupThread.java,
Compiled Code)
        at
weblogic.t3.srvr.PropertyExecuteThread.run(PropertyExecuteThread.java:62

)

Fri Jan 05 19:13:53 EST 2001:<I> <WebLogicServer> T3StartupDef
StartActionServlet weblogic.servlet.utils.ServletStartup
reports:servlet:
*.do unable to initialize.
javax.servlet.UnavailableException: Cannot load application resources
bundle
org.apache.struts.example.ApplicationResources
        at
org.apache.struts.action.ActionServlet.initApplication(ActionServlet.jav

a:50
5)
        at
org.apache.struts.action.ActionServlet.init(ActionServlet.java:289)
        at javax.servlet.GenericServlet.init(GenericServlet.java:258)
        at
weblogic.servlet.internal.ServletStubImpl.createServlet(ServletStubImpl.

java
:474)
        at
weblogic.servlet.internal.ServletStubImpl.createInstances(ServletStubImp

l.ja
va, Compiled Code)
        at
weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl

.jav
a:421)
        at
weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl

.jav
a:342)
        at
weblogic.servlet.utils.ServletStartup.startup(ServletStartup.java:36)
        at
weblogic.t3.srvr.StartupThread.runStartup(StartupThread.java:182)
        at weblogic.t3.srvr.StartupThread.doWork(StartupThread.java,
Compiled Code)
        at
weblogic.t3.srvr.PropertyExecuteThread.run(PropertyExecuteThread.java:62

)

Fri Jan 05 19:13:53 EST 2001:<I> <ListenThread> Listening on port: 7001
Fri Jan 05 19:13:53 EST 2001:<I> <SSLListenThread> Listening on port:
7002
Fri Jan 05 19:13:54 EST 2001:<I> <WebLogicServer> WebLogic Server
started

Could you please help?


Sharmila Pandith
Software Engineer
iXL Inc.

phone: 212-500-5180
AIM: spandith
Yahoo: spandith
MSN: spandith

This message is intended only for the use of the Addressee and may
contain
information that is PRIVILEGED and CONFIDENTIAL. If you are not the
intended
recipient, dissemination of this communication is prohibited. If you
have
received this communication in error, please erase all copies of the
message
and its attachments and notify us immediately.



Reply via email to