Discussions

Hi,I can not solve this problem form more then one week:I am trying to create simple web application using Struts in JBuilder X.Here are the steps I am doing:1. Create new project2. Create new Web-App3. Create new JSP with simple submit formNow the application can be runned and everything is ok.4. Add new dataSource to struts-config.xml so it looks like this:

Actually looking at the stack it seems that the Struts Jar cannot be found. is it present in /WEB-INF/lib? Or Struts basically work fine, until you add this datasource instruction. If that's the case then check that the JDBC driver JAR is also available.

I've had a lot of trouble getting the struts datasource feature to work. There is an easier way to make the data avilable to your application, since you are using Tomcat. You can add a JNDI entry in Tomcat for the JDBC datasource. This can be easily done using the Tomcat web-based admin tool. Then, you can use JNDI lookups and the Service Locator pattern to hide the lookup operations.

TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations technology projects - with its network of technology-specific websites, events and online magazines.