• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Servlet action unavailable

 
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi .
I�ve been experiencing problems for running an application that mixes Struts and Struts-Layout. I have a page with 3 tabs on it, where each has its on form to post...
Once I submit one of these forms, I get an "Servlet action is currently unavailable" , which means that my controller is off , isn�t it ?
So I checked the Tomcat�s logs and got the following :

"Servlet /testes/struts-layout threw load() exception javax.servlet.UnavailableException: Initializing application data source org.apache.struts.action.DATA_SOURCE"
and... in stderr.log
"org.apache.struts.action.ActionServlet initModuleDataSources
SEVERE: Initializing application data source org.apache.struts.action.DATA_SOURCE
java.sql.SQLException: Cannot create JDBC driver of class 'COM.ibm.db2.jdbc.app.DB2Driver' for connect URL 'jdbc b2:base' "

My DataSource declaration in the struts-config.xml is :
<data-sources>
<data-source>
<set-property property="driverClass" value="COM.ibm.db2.jdbc.app.DB2Driver" />
<set-property property="url" value="jdbc b2:base" />
<set-property property="maxCount" value="5"/>
<set-property property="minCount" value="1"/>
<set-property property="user" value="japiadm"/>
<set-property property="password" value="admin"/>
</data-source>
</data-sources>
I think the serlvet controller is not being instantiated because of some sort of problem with the Data Source ... but I don�t know what...
In general, what causes the controller not to start ?
I�ve also already checked the names for the Action class called by the posting... and it�s ok...

Any idea ?
Tks !
Fabio
[ June 05, 2003: Message edited by: fabio gama ]
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I found it out myself... In fact , I�m running all my tests under Tomcat 4.1.x...
Comparing many log files, I saw problems with the DataSource... So, I disabled 2 contexts and another host that were Struts-bases applications and left only context configured for running Struts applications, once apparently, it�s not possible to run 2 or more Struts applications under Tomcat...(or most likely I don�t know how to configure it...) . Does anybody know how to configure it to run many Struts-based applications ?

Thanks.

F�bio
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Making myself clearer... :
Does anybody know how to configure Tomcat to run several Struts-based apps to work concurrently under the same host (different contexts ) or different hosts ?
Tks
F�bio
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic