• 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

ClassCastException when starting Tomcat with Struts2 Filter

 
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.
 
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 =)
 
Author
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
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.
 
Nothing up my sleeve ... and ... presto! A tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic