• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

*listener* *listener-class*

 
Ryan Bailey
Ranch Hand
Posts: 134
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I seem to be having a problem. Here is the following error that I'm getting.


I'm sure I have the proper <web-app> format.
My listener is the first element to be declared under <web-app> then it's <servlet>, <servlet-mapping>, <welcome-file-list>, <error-page>, resource-ref>. If I comment out the listener element everything works fine. Does anyone have any suggestions? My listener is define as follows:

I usually have great advice with tomcat but this had me confused. I'm using tomcat 4.1.
Regards,
Ryan
[ May 08, 2003: Message edited by: Mike Curwen ]
 
Mike Curwen
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In your listing of what tomcat expects in web-app, I don't see any listeners declarations. Could you have made your web.xml file based on the servlet 2.2 spec ?
 
Ryan Bailey
Ranch Hand
Posts: 134
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry about this screwed up post. I am sure you are correct. This is an old webapp file.
<!DOCTYPE web-app
PUBLIC"-//Sun Micorsystems, Inc. //DTD Web Application 2.2//EN"
"http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
The current Servlet Spec is 2.4 correct? Do I just change the link to sun in order to reference 2.4?
Thanks in advance for your time.
Cheers,
Ryan
 
Mike Curwen
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The current servlet spec is still 2.3. 2.4 is in 'proposed final draft 3'

You're using a version of Tomcat that supports 2.3, so I'd look into the example's web.xml file for the exact dtd string to use.
 
Ryan Bailey
Ranch Hand
Posts: 134
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the reply Mike. I looked into my root webapp and do see the 2_3 I need to use.
Cheers,
Ryan
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic