Here we go again...

I did what you suggested and I got a new error message. I must confess I don't know 
what to do next :(

Here's the error message:

Error: 500
Location: /fadd/servlet/com.honeywell.fixedasset.test.DataSourceTest
Internal Servlet Error:

java.lang.NoClassDefFoundError: javax/sql/DataSource
        at 
com.honeywell.fixedasset.test.DataSourceTest.processRequest(DataSourceTest.java:55)
        at com.honeywell.fixedasset.test.DataSourceTest.doGet(DataSourceTest.java:92)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
        at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)
        at org.apache.tomcat.core.Handler.service(Handler.java:287)
        at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
        at 
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:806)
        at org.apache.tomcat.core.ContextManager.service(ContextManager.java:752)
        at 
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:213)
        at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
        at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
        at java.lang.Thread.run(Thread.java:479)

And I'm enclosing the Servlet I used.

Thanks in advance,

Alex

-----Original Message-----
From: David Graham [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, September 18, 2002 10:25 AM
To: [EMAIL PROTECTED]
Subject: RE: DataSource


What happens if you leave everything out of struts-config except the 
datasources section and then try to use the datasource for a simple query?  
You can get the datasource from the ServletContext like this to try it out 
without any struts actions:

// from any servlet do this
DataSource ds = (DataSource) this.getServletContext().getAttribute(
                                "org.apache.struts.action.DATA_SOURCE");

You might also try explicitly putting the key and type attributes in the 
datasource like this:

<datasource
    key="org.apache.struts.action.DATA_SOURCE"
    type="org.apache.struts.util.GenericDataSource">

Dave


>From: "Silva, Alejandro" <[EMAIL PROTECTED]>
>Reply-To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
>To: 'Struts Users Mailing List' <[EMAIL PROTECTED]>
>Subject: RE: DataSource
>Date: Wed, 18 Sep 2002 07:25:37 -0700
>
>Hi David, all:
>
>When I leave the Datasource section out of the config file, my page loads 
>with no problem. It is the page in which the
>user will type his/her username and password.
>
>Also, Balaji Thirugnanam asked about the App Server: I'm using Tomcat 3.2.4 
>and Struts 1.0.2
>
>Thanks!
>
>Alex
>
>-----Original Message-----
>From: David Graham [mailto:[EMAIL PROTECTED]]
>Sent: Tuesday, September 17, 2002 10:58 PM
>To: [EMAIL PROTECTED]
>Subject: Re: DataSource
>
>
>The error message doesn't indicate anything wrong with the datasource.  
>what
>happens when you leave that part out of the config file?
>
>Dave
>
>
> >From: "Silva, Alejandro" <[EMAIL PROTECTED]>
> >Reply-To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
> >To: "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
> >Subject: DataSource
> >Date: Tue, 17 Sep 2002 16:50:13 -0700
> >
> >Hi!
> >
> >Introduction
> >-----------------
> >I'm trying to use the DataSource implementation in Struts so that I can
> >have database Connection pooling. However, every
> >time I try and load the logon.jsp page I get an error :(
> >
> >Any thoughts?
> >
> >Details
> >-----------------
> >Here's my struts-config.xml so far:
> >
> ><?xml version="1.0" encoding="ISO-8859-1"?>
> >
> ><!DOCTYPE struts-config PUBLIC
> >     "-//Apache Software Foundation//DTD Struts Configuration 1.0//EN"
> >     "http://jakarta.apache.org/struts/dtds/struts-config_1_0.dtd";>
> >
> ><struts-config>
> >
> ><!-- ========== Data Source Configuration ===============================
> >-->
> ><data-sources>
> >     <data-source>
> >         <set-property property="autoCommit"
> >                          value="false"/>
> >         <set-property property="description"
> >                          value="Fixed Assets Development Database"/>
> >         <set-property property="driverClass"
> >                          value="sun.jdbc.odbc.JdbcOdbcDriver"/>
> >         <set-property property="maxCount"
> >                          value="4"/>
> >         <set-property property="minCount"
> >                          value="2"/>
> >         <set-property property="password"
> >                          value="webuser"/>
> >         <set-property property="url"
> >                          value="jdbc:odbc:FADDDataSource"/>
> >         <set-property property="user"
> >                          value="webuser"/>
> >     </data-source>
> ></data-sources>
> >
> >
> ><!-- ========== Form Bean Definitions ===================================
> >-->
> ><form-beans>
> >     <!-- Logon form bean -->
> >     <form-bean name="logonForm"
> >type="com.honeywell.fixedasset.LogonForm"/>
> >
> >     <!-- SBU List form bean -->
> >     <form-bean name="getSBUListForm"
> >type="com.honeywell.fixedasset.util.GetSBUListForm"/>
> >
> >     <!-- New Asset form bean -->
> >     <form-bean name="addAssetForm"
> >type="com.honeywell.fixedasset.add.AddAssetForm"/>
> ></form-beans>
> >
> >
> ><!-- ========== Global Forward Definitions ==============================
> >-->
> ><global-forwards>
> >     <forward name="logoff" path="/logoff.do"/>
> >     <forward name="logon" path="/logon.jsp"/>
> >     <forward name="success" path="/main_page.jsp"/>
> ></global-forwards>
> >
> >
> ><!-- ========== Action Mapping Definitions ==============================
> >-->
> ><action-mappings>
> >     <!-- Process a user logoff -->
> >     <action path="/logoff" type="com.honeywell.LogoffAction">
> >         <forward name="success" path="/index.jsp"/>
> >     </action>
> >
> >     <!-- Process a user logon -->
> >     <action path="/logon" type="com.honeywell.fixedasset.LogonAction"
> >name="logonForm" scope="request"
> >input="/logon.jsp">
> >     </action>
> >
> >     <!-- Get an SBU list -->
> >     <action path="/getSBUList"
> >type="com.honeywell.fixedasset.util.GetSBUListAction" 
>name="getSBUListForm"
> >scope="request" validate="false">
> >         <forward name="newAsset"          path="/add_asset_sbu.jsp"/>
> >         <forward name="reviewAssets"      path="review_assets.jsp"/>
> >         <forward name="changeSBU"         path="change_sbu.jsp"/>
> >         <forward name="addLocationSBU"    path="add_location_sbu.jsp"/>
> >         <forward name="changeLocationSBU" 
>path="change_location_sbu.jsp"/>
> >         <forward name="addLocation"       path="add_location.jsp"/>
> >         <forward name="changeLocation"    path="change_location.jsp"/>
> >     </action>
> >
> >     <!-- Add an Asset to the system -->
> >     <action path="/addAsset"
> >type="com.honeywell.fixedasset.add.AddAssetAction" name="addAssetForm"
> >scope="request"
> >input="/add_asset_sbu.jsp">
> >         <forward name="success" path="/index.jsp"/>
> >     </action>
> ></action-mappings>
> >
> ></struts-config>
> >
> >The error message I get is:
> >
> >Error: 500
> >Location: /fadd/logon.jsp
> >Internal Servlet Error:
> >javax.servlet.ServletException: Cannot find ActionMappings or
> >ActionFormBeans collection
> >     at
> 
>>org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:461)
> >     at
> 
>>_0002flogon_0002ejsplogon_jsp_0._jspService(_0002flogon_0002ejsplogon_jsp_0.java:503)
> >     at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
> >     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> >(and more)
> >
> >
> >Alejandro Silva
> >Honeywell - GBS Mexico
> >[EMAIL PROTECTED]
> >+52 (444) 826-2577
> >
> >
> >--
> >To unsubscribe, e-mail:
> ><mailto:[EMAIL PROTECTED]>
> >For additional commands, e-mail:
> ><mailto:[EMAIL PROTECTED]>
>
>
>
>
>_________________________________________________________________
>MSN Photos is the easiest way to share and print your photos:
>http://photos.msn.com/support/worldwide.aspx
>
>
>--
>To unsubscribe, e-mail:   
><mailto:[EMAIL PROTECTED]>
>For additional commands, e-mail: 
><mailto:[EMAIL PROTECTED]>
>
>--
>To unsubscribe, e-mail:   
><mailto:[EMAIL PROTECTED]>
>For additional commands, e-mail: 
><mailto:[EMAIL PROTECTED]>




_________________________________________________________________
Send and receive Hotmail on your mobile device: http://mobile.msn.com


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>


begin 600 DataSourceTest.java
M+RH*("H@1&%T85-O=7)C951E<W0N:F%V80H@*@H@*B!#<F5A=&5D(&]N(%-E
M<'1E;6)E<B`Q."P@,C`P,BP@-3HP-2!030H@*B\*(`IP86-K86=E(&-O;2YH
M;VYE>7=E;&PN9FEX961A<W-E="YT97-T.R`@("`@("`@("`@"@II;7!O<G0@
M:F%V82YS<6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'1I;VX@>PH@("`@("`@(')E<W!O;G-E+G-E=$-O;G1E;G14>7!E
M*")T97AT+VAT;6PB*3L*("`@("`@("!3=')I;F<@9&)5<V5R;F%M92`](&YU
M;&P["B`@("`@("`@4W1R:6YG('%U97)Y(#T@;G5L;#L*("`@("`@("!#;VYN
M96-T:6]N(&-O;FX@/2!N=6QL.PH@("`@("`@(%-T871E;65N="!S=&UT(#T@
M;G5L;#L*("`@("`@("!297-U;'13970@<G,@/2!N=6QL.PH@("`@("`@(`H@
M("`@("`@(&IA=F$N:6\N4')I;G17<FET97(@;W5T(#T@<F5S<&]N<V4N9V5T
M5W)I=&5R*"D["B`@("`@("`@"B`@("`@("`@1&%T85-O=7)C92!D<R`]("A$
M871A4V]U<F-E*2!T:&ES+F=E=%-E<G9L971#;VYT97AT*"DN9V5T071T<FEB
M=71E*")O<F<N87!A8VAE+G-T<G5T<RYA8W1I;VXN1$%405]33U520T4B*3L*
M("`@("`@("`*("`@("`@("!T<GD@>PH@("`@("`@("`@("!C;VYN(#T@9',N
M9V5T0V]N;F5C=&EO;B`H*3L*("`@("`@("`@("`@<W1M="`](&-O;FXN8W)E
M871E4W1A=&5M96YT("@I.PH*("`@("`@("`@("`@+R\@475E<GD@=&AE('5S
M97(@8GD@=7-E<FYA;64*("`@("`@("`@("`@<75E<GD@/2`B4T5,14-4($QO
M9VEN240L(%!A<W-W;W)D+"!,;V=I;DYA;64@1E)/32!A85],;V=I;B(["@H@
M("`@("`@("`@("`O*B!O=71P=70@>6]U<B!P86=E(&AE<F4@*B\*("`@("`@
M("`@("`@;W5T+G!R:6YT;&XH(CQH=&UL/B(I.PH@("`@("`@("`@("!O=70N
M<')I;G1L;B@B/&AE860^(BD["B`@("`@("`@("`@(&]U="YP<FEN=&QN*"(\
M=&ET;&4^4V5R=FQE=#PO=&ET;&4^(BD[("`*("`@("`@("`@("`@;W5T+G!R
M:6YT;&XH(CPO:&5A9#XB*3L*("`@("`@("`@("`@;W5T+G!R:6YT;&XH(CQB
M;V1Y/B(I.PH@("`@("`@("`@("`O+R!&;W(@9&5B=6=G:6YG('!U<G!O<V5S
M"B`@("`@("`@("`@(&]U="YP<FEN=&QN("@B475E<GD@4W1R:6YG(')E861S
M.B`B("L@<75E<GD@*R`B/&)R/B(I.PH*("`@("`@("`@("`@<G,@/2!S=&UT
M+F5X96-U=&51=65R>2`H<75E<GDI.PH@("`@("`@(`H@("`@("`@("`@("!I
M9B`H<G,N;F5X="`H*2D@>PH@("`@("`@("`@("`@("`@9&)5<V5R;F%M92`]
M(')S+F=E=%-T<FEN9R`H(DQO9VEN240B*3L*("`@("`@("`@("`@("`@(&]U
M="YP<FEN=&QN("@B3&]G:6Y)1#H@(B`K(&1B57-E<FYA;64@*R`B/&)R/B(I
M.PH@("`@("`@("`@("!]"@H@("`@("`@("`@("!O=70N<')I;G1L;B@B/"]B
M;V1Y/B(I.PH@("`@("`@("`@("!O=70N<')I;G1L;B@B/"]H=&UL/B(I.PH@
M("`@("`@('T*("`@("`@("!C871C:"`H4U%,17AC97!T:6]N(&5X8U-Q;"D@
M>PH@("`@("`@("`@("!O=70N<')I;G1L;B`H(E1H97)E('=A<R!A(%-13"!%
M>&-E<'1I;VXZ("(@*R!E>&-3<6PN=&]3=')I;F<@*"D@*R`B/&)R/B(I.PH@
M("`@("`@('T*("`@("`@("!O=70N8VQO<V4H*3L*("`@('T@"@H@("`@+RHJ
M($AA;F1L97,@=&AE($A45%`@/&-O9&4^1T54/"]C;V1E/B!M971H;V0N"B`@
M("`J($!P87)A;2!R97%U97-T('-E<G9L970@<F5Q=65S=`H@("`@*B!`<&%R
M86T@<F5S<&]N<V4@<V5R=FQE="!R97-P;VYS90H@("`@*B\*("`@('!R;W1E
M8W1E9"!V;VED(&1O1V5T*$AT='!397)V;&5T4F5Q=65S="!R97%U97-T+"!(
M='1P4V5R=FQE=%)E<W!O;G-E(')E<W!O;G-E*0H@("`@=&AR;W=S(%-E<G9L
M971%>&-E<'1I;VXL(&IA=F$N:6\N24]%>&-E<'1I;VX@>PH@("`@("`@('!R
M;V-E<W-297%U97-T*')E<75E<W0L(')E<W!O;G-E*3L*("`@('T@"@H@("`@
M+RHJ($AA;F1L97,@=&AE($A45%`@/&-O9&4^4$]35#PO8V]D93X@;65T:&]D
M+@H@("`@*B!`<&%R86T@<F5Q=65S="!S97)V;&5T(')E<75E<W0*("`@("H@
M0'!A<F%M(')E<W!O;G-E('-E<G9L970@<F5S<&]N<V4*("`@("HO"B`@("!P
M<F]T96-T960@=F]I9"!D;U!O<W0H2'1T<%-E<G9L971297%U97-T(')E<75E
M<W0L($AT='!397)V;&5T4F5S<&]N<V4@<F5S<&]N<V4I"B`@("!T:')O=W,@
M4V5R=FQE=$5X8V5P=&EO;BP@:F%V82YI;RY)3T5X8V5P=&EO;B!["B`@("`@
M("`@<')O8V5S<U)E<75E<W0H<F5Q=65S="P@<F5S<&]N<V4I.PH@("`@?0H*
M("`@("\J*B!2971U<FYS(&$@<VAO<G0@9&5S8W)I<'1I;VX@;V8@=&AE('-E
M<G9L970N"B`@("`J+PH@("`@<'5B;&EC(%-T<FEN9R!G971397)V;&5T26YF
M;R@I('L*("`@("`@("!R971U<FX@(E-H;W)T(&1E<V-R:7!T:6]N(CL*("`@
&('T*"GT*
`
end

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to