Re: access to dataSource configured in struts-config.xml in a Plugin

2005-06-06 Thread Thibaut Lassalle
thank you for your help. I find the solution. To access to database in a plugin method you can do: javax.sql.DataSource aDataSource = (DataSource)servletc.getServletContext().getAttribute("dataBase1"); where dataBase1 is the key witch identify the data-source in the struts-config.xml

Re: access to dataSource configured in struts-config.xml in a Plugin

2005-06-06 Thread Martin Gainty
Thibault- Have you had the opportunity to look at http://www.docjar.com/html/api/org/apache/struts/action/ActionServlet.java.html ? This is a customised ActionServlet which initialises data-sources thru initModuleDataSources method and the initModulePlugIns method which initialises the PlugIns