Win a copy of Escape Velocity: Better Metrics for Agile Teams this week in the Agile and Other Processes forum!
  • 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
  • Liutauras Vilda
  • Tim Cooke
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Frank Carver
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • fred rosenberger

Cannot find ActionMappings or ActionFormBeans collection

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi guys
i spent now 1 day on this problem, couldn't find in this forum, hope someone can help.

first i was using struts 1.1 and everything worked fine, now i migrated to struts 1.2.4 and this exception appears...

problem:

org.apache.jasper.JasperException: Cannot find ActionMappings or ActionFormBeans collection

=========================================================================
=========================================================================

struts-config.xml:

<?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>
<!-- ========== Form Bean Definitions -->
<form-beans>
<!-- There can be many form-bean elements defined. One for each form in the system -->
<form-bean name="registerForm" type="com.gekko.messenger.forms.RegisterForm"></form-bean>
<form-bean name="loginForm" type="com.gekko.messenger.forms.LoginForm"> </form-bean>
</form-beans>

<!-- ========== Global Forward Definitions -->
<global-forwards>
<forward name="register" path="/jsp/index.jsp"/>
<forward name="login" path="/jsp/messenger.jsp"/>
<forward name="error" path="/jsp/errorPage.jsp"/>
</global-forwards>

<!-- ========== Action Mapping Definitions -->
<action-mappings>
<action path="/login"
type="com.gekko.messenger.actions.LoginAction"
name="loginForm"
scope="request"
input="/jsp/login.jsp">
<forward name="success" path="/html/index.html"/>
<forward name="failure" path="/jsp/errorPage.jsp"/>
</action>

<action path="/register"
type="com.gekko.messenger.actions.RegisterAction"
name="registerForm"
scope="request"
input="/jsp/registerUser.jsp">
<forward name="success" path="/jsp/registerUser.jsp"/>
<forward name="failure" path="/jsp/errorPage.jsp"/>
</action>

</action-mappings>
</struts-config>

=========================================================================
=========================================================================

web.xml:

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>
<display-name></display-name>
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
<init-param>
<param-name>application</param-name>
<param-value>com.gekko.messenger.ApplicationResources</param-value>
</init-param>
<init-param>
<param-name>config</param-name>
<param-value>/WEB-INF/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>2</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>

<!-- Struts Tag Library Descriptors -->
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>

<taglib>
<taglib-uri>/WEB-INF/struts-bean.tld</taglib-uri>
<taglib-location>/WEB-INF/struts-bean.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/struts-html.tld</taglib-uri>
<taglib-location>/WEB-INF/struts-html.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/struts-logic.tld</taglib-uri>
<taglib-location>/WEB-INF/struts-logic.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/struts-form.tld</taglib-uri>
<taglib-location>/WEB-INF/struts-form.tld</taglib-location>
</taglib>
</web-app>



if anyone can help me, you'll be my hero! ;-)

[ October 12, 2004: Message edited by: Christian Pfister ]
[ October 12, 2004: Message edited by: Christian Pfister ]
 
Ranch Hand
Posts: 157
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
When does this exception occur
- on application deployment?
- on submitting a request?

Also, a few more lines of the stack trace would be useful.

Just observed that you are still using the 1.0 version of the struts-config DTD. Try using the 1.1 version. Also, the resources file can now be specified in the struts-config rather than the web.xml

[Edit: There is another post with exactly the same topic.]

Sheldon Fernandes
[ October 12, 2004: Message edited by: Sheldon Fernandes ]
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Christian,

see my last post for: my question.

Perhaps the missing JARs and/or taglibs is your problem.
 
Ranch Hand
Posts: 333
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The error could well be because u have got some extra JAR files (read: struts.jar) in your JAVA_HOME/jre/lib/ext directory.
 
Christian Pfister
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks for your help, i'll try that!!
 
What are your superhero powers? Go ahead and try them on this tiny ad:
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic