Let's start at the beginning: what do you like to achive? What is your goal? 
Usually a _user_ doesn't need to mess around with all that as it works 
perfectly fine out of the box for Java SE, WAR, isolated EAR and non-isolated 
EAR scenarios.


LieGrue,
strub



----- Original Message -----
> From: Harald Wellmann <hwellmann...@googlemail.com>
> To: u...@openwebbeans.apache.org; Mark Struberg <strub...@yahoo.de>
> Cc: 
> Sent: Monday, June 25, 2012 4:47 PM
> Subject: Re: Classloaders
> 
> Hi Mark,
> 
> hmm yes, I had thought the SingletonService might help, but I'm not
> sure what it does and how to use it. What is this Object parameter in
> get(Object) and getSingletonClassloader(Object)? Besides, for
> overriding any SPI, the only way I've seen so far is setting a class
> name in openwebbeans.properties. But this amounts to OWB calling
> Class.newInstance() with a default constructor and then I can't pass
> any parameters to the given service implementation.
> 
> What I'd really like to be able to do is something like
> WebBeansContext.createNewContext(myClassLoader), to avoid messing
> around with the TCCL...
> 
> Best regards,
> Harald
> 
> 2012/6/25 Mark Struberg <strub...@yahoo.de>:
>>  Hi Harald!
>> 
>>  By default OWB takes the TCCL (ThreadContextClassLoader) into account. An 
> EE server (e.g. WAS or Geronimo) could swap the SingletonService before 
> starting 
> up the container. But by default each WebApp will start it's own BeanManager 
> instance and it's own Extensions.
>> 
>>  In our production app we e.g. have all the owb, myfaces, openjpa, bval, etc 
> jars in a shared ClassLoader. See the shared.loader setting in 
> ${catalina.home}/conf/catalina.properties
>> 
>>  Works superb!
>> 
>>  LieGrue,
>>  strub
>> 
>> 
>> 
>> 
>>  ----- Original Message -----
>>>  From: Harald Wellmann <hwellmann...@googlemail.com>
>>>  To: u...@openwebbeans.apache.org
>>>  Cc:
>>>  Sent: Monday, June 25, 2012 3:37 PM
>>>  Subject: Classloaders
>>> 
>>>  When creating multiple CDI containers from a single OpenWebBeans
>>>  library working with multiple classloaders in parallel, how do you
>>>  tell OpenWebBeans which classloader to use?
>>> 
>>>  Is there any alternative to setting the Thread Context Class Loader?
>>> 
>>>  Best regards,
>>>  Harald
>>> 
> 

Reply via email to