cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vadim Gritsenko <>
Subject Re: svn commit: r522901 - in /cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main: java/org/apache/cocoon/caching/impl/ resources/META-INF/cocoon/spring/cocoon-pipeline-impl-cache.xml
Date Thu, 29 Mar 2007 12:04:10 GMT
Carsten Ziegeler wrote:
> Vadim Gritsenko wrote:
>> Torsten Curdt wrote:
>>> On 28.03.2007, at 20:14, Vadim Gritsenko wrote:
>>>> wrote:
>>>>> -public class CacheImpl
>>>>> -extends AbstractLogEnabled
>>>>> -implements Cache, ThreadSafe, Serviceable, Disposable, 
>>>>> Parameterizable {
>>>>> +public class CacheImpl implements Cache {
>>>>>  +    private Log logger = LogFactory.getLog(getClass());
>>>> Is there a reason why logger can not be static?
>> So since Cocoon is not and should not be deployed in container's shared class 
>> loader, usage of 'static' is preferred.
> Hmm, why do you think "is not and should not"? Why not (I'm talking
> about 2.2+ here)?

Last I checked, and since 2.2, it is impossible (or just really hard?) to start 
up cocoon without servlet context and related objects, which means it gotta be 
deployed and started as part of the webapp. If that is the case, IMHO there is 
no good reason to have it as part of the shared classloader.

> In addition, with 2.2+ we provide separate artifacts for "common"
> components which might be used outside of Cocoon and might then be used
> via a shared class loader. So I think we should not use "static" here.

For reusable components - yes, I agree.

> As most of our components are singletons anyway, there isn't any memory
> problem here.

There are some generated poolable wrappers, IIRC - those aren't singletons and 
do represent good chunk of components (pipelines and all direct sitemap components).


View raw message