JJupin print function not working in v3.0.7

Craig Leigh April 14, 2016

JJupin v3.0.7

While developing another script I tried to print to the log using a simple print command.

string[] complist;
number i;
number marraySize;
marraySize = arraySize(components);
for(i=0; i < marraySize; i = i + 1)
{
    if(components[i] == "Tempo")
    {
     watchers = addElementIfNotExist(watchers, "dt02765");
     watchers = addElementIfNotExist(watchers, "dt202280");
    }
}
print("Name");

What I get in the log is this over and over:

2016-04-14 11:17:08,034 http-bio-8080-exec-22 ERROR dt84658 677x589x1 x5a9l3 10.142.150.21 /secure/WorkflowUIDispatcher.jspa [commons.ivm.routines.UserFullNameRoutine] Empty username provided.
2016-04-14 11:17:08,136 http-bio-8080-exec-22 ERROR dt84658 677x589x1 x5a9l3 10.142.150.21 /secure/WorkflowUIDispatcher.jspa [commons.ivm.routines.UserFullNameRoutine] Empty username provided.

The script works, but the print("name");   function does not. 

I have already added under Logging and Profiling:

com.keplerrominfoINFO

Any Ideas?  

3 answers

1 accepted

3 votes
Answer accepted
Alexandra Topoloaga
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 14, 2016

HI Craig,

 

Depending on what kind of print you need, you can use printlogPrint or runnerLog routines.

print routine puts the output in the  /catalina.out 

logPrint puts the output in jira_home/atlassian-jira.log

runnerLog puts the output in the gadget's console (from JJUPIN/SER)

 

Hope this helps,
Alexandra 

0 votes
Craig Leigh April 14, 2016

Thank you for your response, but your docuementation says different.  Besides I have used the print() function in the past and it worked.  Just let me know if it is broken or not so I do not waste time.

From your documentation:

https://confluence.kepler-rominfo.com/display/JJUPIN/Configure+JIRA+Logging

Configure JIRA Logging

JIRA uses Log4J as a logging system. We're interested in output messages produced by our plugins so you will need to configure logging.

  1. Open JIRA_HOME/atlassian-jira/WEB-INF/classes/log4j.properties with your favorite text editor.
  2. Append the following lines (add them at the end):

 

log4j.category.com.keplerrominfo = INFO, console, filelog
log4j.additivity.com.keplerrominfo = false

 

Note

Icon

If you do not perform this configuration step, some routines such as print() will not output messages.

0 votes
Silviu Burcea
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 14, 2016

You are looking for logPrint routine wink

Suggest an answer

Log in or Sign up to answer