-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hello Andrew,
your 'context' tag is missing the attributes 'docbase' and 'path'. It should look like this: <Context docbase="webapps/myapp.war" path="/myapp"> <!-- Db connection --> <Resource name="jdbc/wdcc" auth="Container" [...] This should pointing it to the directory where your context.xml file resides. If this does not work either, you could try to set the fields 'WAR or Directory URL' or 'XML configurations URL' when deploying your application using the Tomcat Manager. Kind regards Sebastian Gerdes > I'm having problems trying to set up a DataSource in META-INF/context.xml > > If I specify the <Resource> within a <Context> in server.xml it works fine. > Similarly, if I put it into conf/Catalina/localhost/myapp.xml it's fine, but > putting it in myapp/META-INF/context.xml does not work. > > I also found that if I put completely invalid xml in > myapp/META-INF/context.xml, then Tomcat doesn't report this. > > I've googled this issue, there seem to be quite a few occurrences of this > problem, but no specific solutions or recommendations. > > I'm using Tomcat 5.5.17 and Java 1.5.0 on Windows 2000 > > myapp/META-INF/context.xml is: > <Context> > <!-- Db connection --> > <Resource > name="jdbc/wdcc" > auth="Container" > factory="org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory" > type="javax.sql.DataSource" > driverClassName="com.mysql.jdbc.Driver" > url="jdbc:mysql://localhost:3306/wdcc1" > username="jdbc" > password="andrew" > removeAbandoned="true" /> > </Context> > > Any help would be appreciated > Regards > Andrew Connick > > > --------------------------------------------------------------------- > To start a new topic, e-mail: users@tomcat.apache.org > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - -- *********************************** Sebastian Gerdes Strackerjanstr. 51 26129 Oldenburg Uni-Oldenburg *********************************** -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHa7iVDven//UCaP8RAvVmAJ9ScoeNFsrVMbOBGrqtMwpSxP1BTgCfVbSw 78JXSz5gscQTQVY/QKtdrXw= =PJm/ -----END PGP SIGNATURE----- --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]