Reputation: 97
I have two applications running on different ports of my Tomcat. I have added a filter in my web.xml. This filter class exists in only one of the two applications code/war file. When I start the tomcat, I get java.lang.ClassNotFoundException: com.abc.filter.MyFilter
The result is, application which has filter class runs fine, but other one does not start. My question is : Is there any way to specify application specific filters in Tomcat web.xml so we can load the applications which do not have a particular filter class?
Thanks.
Upvotes: 1
Views: 171
Reputation: 22484
Yes, you can setup app specific configurations by adding a web.xml
file in the application's WEB-INF
folder instead of setting up global configurations by modifying the XML
s in Tomcat's conf
folder
Upvotes: 2