(no) logging in workflow

I’m trying to achieve logging from javascript code in a workflow, but with no success.
This is an excerpt from the workflow code I’m using:

<event type=”process-start”>
<action>
<script>
logger.log(“Message X”);
</script>
</action>
</event>

C:\alfresco-enterprise-tomcat-3.4.4\tomcat\webapps\alfresco\WEB-INF\classes\log4j.properties
contains:
      log4j.logger.org.alfresco.repo.workflow=DEBUG 

That should be good, but no logging information.

https://forums.alfresco.com/en/viewtopic.php?f=10&t=21838 gave me the answer.

# Repository
….
log4j.logger.org.alfresco.repo.jscript=error
log4j.logger.org.alfresco.repo.jscript.ScriptLogger=debug    <= set this one .
log4j.logger.org.alfresco.rep…..

And also –

My script needs to be encapsulated by the action class AlfrescoJavaScript.

<action class=”org.alfresco.repo.workflow.jbpm.AlfrescoJavaScript”>
<script>
logger.log(“Ad Hoc Task”);
</script>
</action>

Advertenties

Geef een reactie

Vul je gegevens in of klik op een icoon om in te loggen.

WordPress.com logo

Je reageert onder je WordPress.com account. Log uit / Bijwerken )

Twitter-afbeelding

Je reageert onder je Twitter account. Log uit / Bijwerken )

Facebook foto

Je reageert onder je Facebook account. Log uit / Bijwerken )

Google+ photo

Je reageert onder je Google+ account. Log uit / Bijwerken )

Verbinden met %s