cancel
Showing results for 
Search instead for 
Did you mean: 

'logger' is not defined

jkraai
Champ in-the-making
Champ in-the-making
I saw a brief post about how a tag in a maven .xml file is necessary for the workflow logger to work properly but I cannot find it again, hence I've chosen to file this in the configuration forum.

Environment:
<ul>
<li>latest alfresco enterprise
<li>latest activiti plugin for eclipse
</ul>

Problem:
<ul>
<li>in activiti workflow, a script task with the following
<blockquote>logger.log("starting Request");</blockquote>
</ul>

Expected behavior:
<ul>
<li>in catalina.out
<blockquote>[…] starting Request</blockquote>
</ul>

Actual behavior:
<ul>
<li>in catalina.out
<blockquote>SEVERE: Error while closing command context
org.activiti.engine.ActivitiException: problem evaluating script: sun.org.mozilla.javascript.internal.EcmaError: ReferenceError: "logger" is not defined. (&lt;Unknown source&gt;#2) in &lt;Unknown source&gt; at line number 2</blockquote>
</ul>

I have attempted to set the log4j flags to debug as described in many older posts, but that causes other problems on startup.

Clearly, I have little experience w/ Alfresco and it's workflow engine; and I have no experience with Maven.

Thank you for any help.

–jim
1 REPLY 1

sujaypillai
Confirmed Champ
Confirmed Champ
Try using a alfresco script task as <strong>logger</strong> is a root object provided by alfresco.