Hello again,
OK, I've found the solution. Probably should have done some more
research ... but in my defense, it's really not easy to find
documentation on Cocoon and its assorted technologies.
On 20/01/06, Jakob Fix <[EMAIL PROTECTED]> wrote:
> Hi Giacomo,
>
> thanks for your reply.
>
> On 20/01/06, Giacomo Pati <[EMAIL PROTECTED]> wrote:
> > > From: Jakob Fix <[EMAIL PROTECTED]>
> > > I have trouble configuring logkit as to not log to file at all (the
> > > application will run directly from CD-ROM), but to only log
> > > FATAL_ERRORs to the *console*. I can't find any hint as to what the
> > > name of the factory to use would be.
> >
> > Change all ref-id attribute values in the <categories> section of the
> > logkit.xml file to "console" and you are done ("console" references the
> > corresponding <stream id="console"> target in the <targets> section
> > which uses the "stream" factory which prints to System.out).
>
> OK, I can change the ref-id attributes to "console".
>
> However, I do not have any <stream> elements in my <targets> section,
> and also there's no stream factory, just these:
>
> <factory type="priority-filter"
>
> class="org.apache.avalon.excalibur.logger.factory.PriorityFilterTargetFactory"/>
> <factory type="servlet"
> class="org.apache.avalon.excalibur.logger.factory.ServletTargetFactory"/>
> <factory type="cocoon"
> class="org.apache.cocoon.util.log.CocoonTargetFactory"/>
> <factory type="lf5"
> class="org.apache.avalon.excalibur.logger.factory.LF5TargetFactory"/>
>
> Couldn't find any mentioning of a stream factory etc. on the cocoon
> website either. I'm using 2.1.5.
>
> Is it just me being daft?
>
> --
> cheers,
> Jakob.
Googling for "stream target cocoon", at
http://www.planetcocoon.com/tags/210 I found "Re: svn commit: r159493
- cocoon/trunk/src/webapp/WEB-INF/logkit.xconf"
which contained the line
+ <factory type="stream"
class="org.apache.avalon.excalibur.logger.factory.StreamTargetFactory"/>
which I then used in my <factories> section.
Then I cut down the <targets> section to this:
<targets>
<stream id="console"/>
</targets>
Again, I deduced from looking at the factory elements' type attribute
that they probably woud be the namesake for the target element name. I
gave it the id attribute value "console" because you alluded to it in
your previous post. And then I replaced, as you indicated, all id-ref
values with "console". Also, as I mentioned, the error level is
pushed up to FATAL_ERROR.
Thanks for the pointer to the stream factory though.
--
cheers,
Jakob.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]