JBoss Community

Re: How to stop my WAR loading JBoss's provided 3rd party classes?

created by Ales Justin in JBoss Microcontainer - View the full discussion

Perhaps filter out the "org.hibernate.validator"?

I'll try something, but I'm not sure what to try exactly. Looks like adding NegatingClassFilter for org.hibernate as after-filter isn't the way so I'm not sure which way to go to block some packages/classes completely regardless their presence anywhere or not.

There should really be some "fully blocking" approach possible (and simply).

The same negating filter should also work for after phase.

The fully blocking filter is NothingClassFilter.

 

EDIT: I tried to setup filters on org.hibernate.validator package several ways - before-filter was always NegatingClassFilter on that package, after-filter was once NegatingClassFilter, once just PackageClassFilter, also tried RecursivePackageFilter for both before-filter and after-filter in the end but to no avail.

Hmm, yeah, I think that was a typo on my end, we need RecursivePackageFilter.

But apart from that I don't see what can go wrong.

 

Could you debug a bit more?

Or do you have some test case / example to share?

Reply to this message by going to Community

Start a new discussion in JBoss Microcontainer at Community