You have to do 2 steps:
1.) Give your action a name in the sitemap using the logger="...." attribute. For example "myAction".
2.) Register this logger-name in logkit.conf by creating this two entries:
...
<categories>
...
<category log-level="DEBUG" name="myAction">
<log-target id-ref="loginAction"/>
<log-target id-ref="error"/>
</category>
...
and
<targets>
...
<cocoon id="myAction">
<filename>${context-root}/WEB-INF/logs/myAction.log</filename>
<format type="cocoon">
%7.7{priority} %{time} [%{category}] (%{uri}) %{thread}/%{class:short}: %{message}\n%{throwable}
</format>
<append>false</append>
</cocoon>
...
Note that you have to set the log level to DEBUG!
After restarting cocoon, you can find the logs for you action in WEB-INF/logs/myAction.log.
[2. solution]
You have to do although 2 steps:
1.) Give your action an name in the sitemap using the logger="...." attribute. The name should start with "sitemap". For example "sitemap.myAction".
2.) Search for the following entry in logkit.xconf and switch log-level to DEBUG:
<category log-level="INFO" name="sitemap">
After restarting cocoon you can find your logs for your action in WEB-INF/logs/sitemap.log.
Regards Stephan
[EMAIL PROTECTED] wrote:
Hi all,
i wrote a little action in which i send messages using getLogger().debug(..)
or getLogger().error(..) or getLogger().warn(..) ; the question is where
can i find the messages sent ? I need to switch some parameters to activate loggers ?
May i redirect messages to my own log file ?
many thanks
Flavio
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
