Hey folks,

I'm not sure if this is a bug or not, but I can't find any relevant
information in the spec to suggest the behavior is expected.

There's a web-fragment in my classpath that I'd like to skip. The only way
to accomplish this that I know of is to put an <absolute-ordering> stanza
in my web.xml and omit an <others/>. Though this has the desired effect of
skipping the web-fragment I don't want, it has the very negative side
effect that my ServletContainerInitializer doesn't get handed all instances
of WebApplicationInitializer anymore, despite its @HandlesTypes annotation.
If I add the <others/>, classpath scanning works fine, but the undesired
web-fragment comes back. I've tested this in the latest 7.x and 8.x Tomcat
releases.


This begs two questions:

   1. Why does specifying an <absolute-ordering> without an <others/> kill
   classpath scanning, or at least the part of Tomcat responsible for finding
   types specified by @HandlesTypes and giving it to interested parties?
   2. Is there an alternate way to skip a web-fragment, short of ripping it
   out of the jar, which I really don't want to do?

Thanks!

-Ryan

Reply via email to