• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

ClassCastException when starting Tomcat with Struts2 Filter

 
Kurt Kopf
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
OS: Windows 7
Tomcat: 6.0.26
Struts 2.1.8.1
Java 1.6.0_20

Whenever I try and start up my app in Tomcat with a struts filter, I get the following exception:

I actually had the same exception on my OS X box, but that was with Tomcat 6.0.24. When I upgraded to .26, everything worked fine. I'm using the same exact code base, libraries, etc, on the two machines but with no luck. Using the same major and minor Java versions as well, both compiled for 64-bit. I've tried going back to Tomcat .24 and .20 with no luck. I haven't tried going to Struts 2.0.x, but I'll probably try it out if no one has any suggestions.

Thanks in advance for your help, hopefully it's just something simple.
 
Alpesh Padra
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please verify your filter entries in web.xml since its comming while application loading.
 
Kurt Kopf
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here's my web.xml:


Thanks for any insight =)
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What libraries are you deploying with your application?
 
Kurt Kopf
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I figured out the issue. In OS X, Eclipse Galileo is 64-bit. In Win23, Galileo is only 32 bit. I had to upgrade Eclipse to Helios 64-bit (which means none of my SVN stuff works, but that's a completely different issue).

Thanks David, you actually sent me down the path that solved the issue.
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Glad you figured it out :) Yeah, most times when a totally bizarre issue like that pops up it's some form of library mismatch.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic