tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Neale Rudd" <>
Subject Re: Container-specific method to prevent classpath scanning for EE annotations
Date Thu, 15 Mar 2012 09:41:50 GMT
Thanks Romain,

Having trouble building the snapshot due to a problem in a dependant 
project, so we're trying conf/exclusions.list which does indeed seem to be 
in beta2.

Couldn't find any docs, but from the source code, it seems to be in this 


Is that correct?  Just plain text with dashes separating package names and a 
dash on the end for wildcard?

Best Regards,

----- Original Message ----- 
From: "Romain Manni-Bucau" <>
To: <>
Sent: Thursday, March 15, 2012 6:08 PM
Subject: Re: Container-specific method to prevent classpath scanning for EE 

> in last version (understand trunk) you have 2 mecanisms:
> 1) tomee/conf/exclusions.list [i'm no more sure at all but i think it is 
> in
> beta-2]
> -> contain a list of file (in fact prefixes: for instance "commons-") to
> avoid to scan
> 2) WEB-INF/scan.xml
> -> contains the list of classes and/or packages to scan. Here is a sample:
> - Romain
> 2012/3/15 Neale Rudd <>
>> Hi Guys,
>> One of our customers trialling TomEE has reported that their app isn't
>> loading because it is scanning all the library JARs in his WEB-INF/lib 
>> for
>> Java EE annotations, and then complaining about missing classes (such as
>> Hibernate.Session).
>> "It even scans those that have no META-INF/persistence.xml,
>> META-INF/ejb-jar.xml, or anything else. This is a problem because I have 
>> a
>> framework JAR that contains such annotations but that should *not* be
>> scanned by default. Rather, I will refer to these framework classes
>> explicitly in my app JAR's persistence.xml, ejb-jar.xml etc.
>> Containers such as GlassFish/JBoss have a container-specific mechanism to
>> control/prevent classpath scanning. But I can't see anything for TomEE?"
>> Is there a way to prevent these jars being scanned?
>> Best Regards,
>> Neale Rudd
>> Metawerx Pty Ltd

View raw message