• 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 is not available

 
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,

I m not getting why my Tomcat 6 servlet container is unable to find the ActionServlet.
I have made entry for this servlet in web.xml and done mapping also
WEB-INF\lib is having the "struts-core-1.3.10.jar" file. I am not using other struts modules/ features like jsp tags, validation, tiles etc.

I have checked my code and file structure with that available in book "Struts Complete Reference". Code downloaded runs fines.
For my code the container is not getting ActionServlet itself.

web.xml listing


Thank you all.
 
Sheriff
Posts: 9707
43
Android Google Web Toolkit Hibernate IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I m not getting why my Tomcat 6 servlet container is unable to find the ActionServlet.



Exact what is the error saying?? Please post the stack trace of the error that you get here...
 
Lalit Nagalkar
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
As such there is no stack trace in tomcat window. The browser shows 404 error:
----------------------------------------------------------
HTTP Status 404 - Servlet action is not available

type Status report

message Servlet action is not available

description The requested resource (Servlet action is not available) is not available.

Apache Tomcat/6.0.20
---------------------------------------------------------
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please turn up the logging level to DEBUG and check the log immediately after startup.
 
Lalit Nagalkar
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

David Newton wrote:Please turn up the logging level to DEBUG and check the log immediately after startup.



How can i do that??
I have never used logging system

 
Ankit Garg
Sheriff
Posts: 9707
43
Android Google Web Toolkit Hibernate IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Read this to get more information about how to set logging level...
 
Lalit Nagalkar
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I checked Tomcat logs; binutils and digester libraries were required. So copied them to my application's WEB-INF\lib directory
action servlet is getting accessed now,
but now following exception is being thrown

From tomcat logs:
-------------------------------------------------
Nov 17, 2009 4:21:40 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet action threw exception
org.apache.struts.chain.commands.InvalidPathException: No action config found for the specified url.
-------------------------------------------------

struts-config.xml and web.xml files are properly set for the requested URL. Not getting why is this happening.
I have worked with struts some 9 months back, but didn't get such issues.
 
Lalit Nagalkar
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
HI all
Thanks for the help

There was an error of '/' in <action> element's path property.

Now no exception is being thrown, but after processing action i m not getting the forward page.
I am seeing only a blank screen.
Nothing found in tomcat logs.
Also System.out.println() is not printing anything on tomcat console window.
These SOP's not printed in logs too.

 
Ankit Garg
Sheriff
Posts: 9707
43
Android Google Web Toolkit Hibernate IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You'll have to show us your configuration files and/or your code for the action. Without that we can't predict what the problem is...
 
Lalit Nagalkar
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I used instructions available on tomcat site for enabling logging and copied new tomcat-juli.jar file. Now tomcat itself is not starting at all. log files of 10MBs are generated (as is mentioned on website). Hence i m using old tomcat-juli.jar file only.

I am not able to see my System.out.println() calls anywhere in the logs.

Ankit Garg wrote:You'll have to show us your configuration files and/or your code for the action. Without that we can't predict what the problem is...




This is simples registration form with 1 userID and two Password fields. No database connections are made.
I am not including success.html and failure.html; these are simplest html files showing success or failure depending upon whether user entered both passwords same or not respectively.

A part of tomcat.log file is also attached generated by log4j.

Here others are.

web.xml



struts-config.xml


register.jsp


RegisterForm.java



RegisterAction.java



Tomcat log related to my HTTP request

 
Lalit Nagalkar
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hiii all

I am getting frustrated for not able to solve this simple problem
Logs also don't say at all, SOP's not working too
Please someone help me out
 
reply
    Bookmark Topic Watch Topic
  • New Topic