cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thorsten Scherler <>
Subject @Logger in RestController or independent?
Date Wed, 13 Jul 2011 18:12:08 GMT
Hi all,

I developed a small @Logger annotation for a customer project which I
would like to contribute. The question is ATM what is the best way?

ATM I have implemented the annotation based on an independent
BeanPostProcessor which I then invoke with adding
<!-- logger annotation implementation -->
  <bean class="org.apache.cocoon.common.LoggerInjector"/>

Basically the class is doing:
if (field.getAnnotation(Logger.class) != null) {
                    Log log = LogFactory.getLog(bean.getClass());
                    field.set(bean, log);

I saw SpringRESTController and I wonder whether we should add it there
in getController as  populateLogger(configuration, unpackedController,

or to leave it independent to allow usages as well in REST independent
components such as generators, etc.


Thorsten Scherler <>
codeBusters S.L. - web based systems
<consulting, training and solutions>

View raw message