cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sylvain Wallez <sylv...@apache.org>
Subject Re: [RT] Per sitemap classloading and ClassLoaderFactory
Date Mon, 06 Jun 2005 09:35:52 GMT
Carsten Ziegeler wrote:

>In 2.2 we have the nice feature to have a class loader on a per sitemap
>base. This allows to load classes just for this sitemap (and all sub
>sitemaps).
>Now, the implementation - the SitemapLanguage -  uses a global
>component, the ClassLoaderFactory to get the per sitemap classloader.
>Current we only have on implementation and even if we had different
>implementations, you can only configure one classloader factory for the
>whole cocoon instance.
>
>For my own application I want to use an own classloader for a specific
>sitemap - which is not possible today.
>  
>

Can you elaborate on your use case?

>So what do you think about removing the (avalon) component
>ClassLoaderFactory and make the class loader factory configurable on a
>per sitemap base. Then you can define the class for the factory on the
>components section:
><map:components classloader-factory-class="..."/>
>
>If this attribute is missing we use the default which is the
>DefaultClassLoaderFactory.
>  
>

Hmm... since this class has to be defined by a higher-level classloader, 
what about allowing different implementations for the 
ClassLoaderFactory, i.e. using a role rather than a class name?

Also, it seems to me this property belongs more to <map:classpath> 
rather than <map:components>.

Sylvain

-- 
Sylvain Wallez                        Anyware Technologies
http://apache.org/~sylvain            http://anyware-tech.com
Apache Software Foundation Member     Research & Technology Director


Mime
View raw message