[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-10-28 Thread p.w...@kostal.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Peter Wein edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 [~timblaktu], nearly exactly: You (or an administrator) must allow this to use this "unsecure" function to work in a jenkinsfile script or pipeline dsl library, then you could use  the method  in the following manner: {code:java}import hudson.Functions[...]try {throw "error"}catch (Exception e) {println Functions.printThrowable(e)}{code}   
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.2951.1572250260292%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-10-28 Thread p.w...@kostal.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Peter Wein edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 [~timblaktu], nearly exactly: You (or an administrator) must allow this to use this "unsecure" function to work in a jenkinsfile script or pipeline dsl library, then you could use in the following manner: {code:java}import hudson.Functions [...] try {throw "error"}catch (Exception e) {println Functions.printThrowable(e)}{code}   
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.2949.1572250209499%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-10-28 Thread p.w...@kostal.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Peter Wein edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 [~timblaktu], nearly exactly:  You (or an administrator) must allow this to use this "unsecure" function to work in a jenkinsfile script or pipeline dsl library, then you could use in the following manner:  {code:java}import hudson.Functionstry {throw "error"}catch (Exception e) {println Functions.printThrowable(e)}{code}   
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.2933.1572250208832%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-10-28 Thread p.w...@kostal.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Peter Wein commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Tim Black, nearly exactly:     

 

import hudson.Functions


try {
throw "error"
}
catch (Exception e) {
println Functions.printThrowable(e)
}
 

    
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.2924.1572250140242%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-10-24 Thread timbla...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Tim Black edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 [~peddanet] [~jglick] would you post a code example of how you invoke printThrowable, successfully? I'm having trouble finding documentation for the hudson/jenkins functions. (A link would be nice?) Would it be something like this:{code:java}node() { try { throw "error" } catch (err) { hudson.Functions.printThrowable(err) } }{code}?? Is this function available in default (open source) installations of Jenkins? Do I  need to  also  import anything to make this work?FWIW, I also  found some good examples [here|[https://code-maven.com/jenkins]]. Thanks.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.399.1571938440487%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-10-24 Thread timbla...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Tim Black edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 {code:java} {code} [~peddanet] [~jglick] would you post a code example of how you invoke printThrowable, successfully? I'm having trouble finding documentation for the hudson/jenkins functions. (A link would be nice?) Would it be something like this:{code:java}node() { try { throw "error" } catch (err) { hudson.Functions.printThrowable(err) } }{code}??I also found some good examples [here|[https://code-maven.com/jenkins]]. Thanks.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.391.1571938380602%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-10-24 Thread timbla...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Tim Black edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 {code:java} {code} [~peddanet] [~jglick] would you post a code example of how you invoke printThrowable, successfully? I'm having trouble finding documentation for the hudson/jenkins functions. (A link would be nice?) Would it be something like this: {code:java} node() {     try {    throw "error"     }catch (err)  \ { hudson.Functions.printThrowable(err)  }  }  {code }??I also found some good examples [here|[https://code-maven.com/jenkins]]. Thanks.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.389.1571938380566%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-10-24 Thread timbla...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Tim Black commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Peter Wein Jesse Glick would you post a code example of how you invoke printThrowable, successfully? I'm having trouble finding documentation for the hudson/jenkins functions. (A link would be nice?) Would it be something like this: node() { try  { throw "error" }  catch (err) { hudson.Functions.printThrowable(err) } } ?? I also found some good examples [here|https://code-maven.com/jenkins]. Thanks.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.374.1571938080774%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-10-02 Thread p.w...@kostal.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Peter Wein commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Thank you Basil Crow and Jesse Glick! I have used the proposal of Jesse , and finally it works!   
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.9470.1570002300245%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-09-24 Thread jgl...@cloudbees.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Jesse Glick commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Or hudson.Functions.printThrowable, which displays causes a bit more nicely.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.4434.1569354900275%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-09-24 Thread m...@basilcrow.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Basil Crow commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Another option is to use Throwables#getStackTraceAsString: 

 

try {
  error 'foo'
} catch (err) {
  echo Throwables.getStackTraceAsString(err)
}
 

 Note that this requires approving the following method in Script Security: 

 
staticMethod com.google.common.base.Throwables getStackTraceAsString java.lang.Throwable
 

  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.4406.1569349500637%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-09-23 Thread p.w...@kostal.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Peter Wein commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Which is where we have begun! But I did not understand correctly your way of solving it and if it is a regular pattern of jenkins or workaround for a bug. Is there one filed to the bug tracker team?  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.3545.1569257940411%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-09-23 Thread pedda...@sonnenkinder.org (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Peter Wein commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Vassilena Treneva, thanks for the detailed answer. Yes I have an exception and for example in a code like this: ~~ 

 

 try {
 new CommonTools().copyArtifacts(
 env['JOB_NAME'],
 env.ARCHIVE_INPUT_FOLDER + '/JenkinsServerStack/',
 env.JENKINS_SHARE)
 }
 catch (Exception eDF) {
 utility.debugPrint(
 env, name, 'Exception ' + eDF.getClass() + ' : CopyArtifacts somehow failed! ',
'lastSuccessful()')
 eDF.printStackTrace()
 } 

 but it does not print the StackTrace. It well gets the class by getClass: 

 

02:55:40 [PolyspaceBugFinder:runSteps]: Exception e is thrown:hudson.AbortException: CopyArtifacts somehow failed! 
lastSuccessful() 

 So no printStackTrace is printed. What am I doing wrong here?  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop

[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-09-20 Thread vasilena.tren...@softwareag.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Vassilena Treneva commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Peter Wein, 
 
The reason I wanted to catch the exception was a weird SVN checkout issue that I had – so I wanted to have a retry piece based on whether I have SVN exception or not. Thus I needed to know the type of the exception that occurs. 
Catching throwable is a bad approach but I did it initially until I figure out what is going in. (throwable covers exceptions as well as errors). Do not do it like me  
Try without a catch is probably another error in my script. 
workspaceDir is something that I set at the beginning of my script. 
 Do you have a specific problem that you are trying to solve by asking me these questions?  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.1848.1568980860215%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-09-20 Thread pedda...@sonnenkinder.org (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Peter Wein commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Vassilena Treneva I am new here, sorry for my poor JAVA knowlegde: 
 
What is the reason for that behavior? Is this a bug or a feature? 
If I have nested exceptions, do I have to do it for every nested exeception resp. throwable in this case? 
Why is the first Try without a catch? 
Most stupid question: Is the ws ("${workspaceDir}"){...} the part I have to replace with my code? . Cause my variable for workspace is different, just to start... 
 I hope you answer that questions even they are very obvious to you! Looking forward! Thanks in advance!  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.182865.1497172331000.1821.1568979840215%40Atlassian.JIRA.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-03-06 Thread constantin.bugn...@worldfirst.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Constantin Bugneac commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Many Thanks Vassilena Treneva.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-03-05 Thread vasilena.tren...@softwareag.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Vassilena Treneva commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Constantin Bugneac, I managed to get this info like this:  try {try { ws("${workspaceDirectory}") { checkout() } } catch (Throwable th) { echo 'Caught Throwable' echo 'Exception type: ' + th.getClass() echo 'Exception message: ' + th.getMessage() echo 'Exception stacktrace: ' + th.getStackTrace() as String[] }  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-03-04 Thread constantin.bugn...@worldfirst.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Constantin Bugneac commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Has anyone got a proper way to print the stacktrace ?  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-01-17 Thread vasilena.tren...@softwareag.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Vassilena Treneva edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Hey,What is the right way to redirect the stacktrace so that a user can see in the console log?I have this code: {code:java}    // code placeholder  try  \ { try { checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']]) } catch (Throwable ex)  \ { echo 'Caught Throwable. Retrying operation...' echo 'Exception message: ' + ex.getMessage() ex.printStackTrace() retry(5) { checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']]) } } {color:#505f79}{color} {code :java } // code placeholder{code}  But I cannot see the stacktrace as it goes in the error stream that I do not see in the console build log.Is there a way to copy this info to the console log?(My use case: I have many SVN checkout issues and I would like to be able to retry the checkout only when I get SVN related exceptions)  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 

[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-01-17 Thread vasilena.tren...@softwareag.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Vassilena Treneva edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Hey,What is the right way to redirect the stacktrace so that a user can see in the console log?I have this code:  {color:#505f79}{{ try \{try { checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']])} catch (Throwable ex) \{ echo 'Caught Throwable. Retrying operation...' echo 'Exception message: ' + ex.getMessage() ex.printStackTrace() retry(5) { checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']]) }} {color:#505f79 } } {color} {code:java}    // code placeholder  {code}  But I cannot see the stacktrace as it goes in the error stream that I do not see in the console build log.Is there a way to copy this info to the console log?(My use case: I have many SVN checkout issues and I would like to be able to retry the checkout only when I get SVN related exceptions)  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
  

[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-01-17 Thread vasilena.tren...@softwareag.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Vassilena Treneva edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Hey,What is the right way to redirect the stacktrace so that a user can see in the console log? {quote}  I have this  snippet  code :   { color:#505f79} { { try  \  { }} try  { {  checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']])} } \{{ }  catch (Throwable ex)  {}}  \{ {  echo 'Caught Throwable. Retrying operation...' }} \{{  echo 'Exception message: ' + ex.getMessage() }} \{{  ex.printStackTrace() }} \{{  retry(5) { }} {{  checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']])}}  \{{  }} } \ { { color  } }}  {quote}     But I cannot see the stacktrace as it goes in the error stream that I do not see in the console build log.Is there a way to copy this info to the console log?(My use case: I have many SVN checkout issues and I would like to be able to retry the checkout only when I get SVN related exceptions)  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira

[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-01-17 Thread vasilena.tren...@softwareag.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Vassilena Treneva edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Hey,What is the right way to redirect the stacktrace so that a user can see in the console log?I have this snippet:{{try {}}{{ checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']])}}  \ {{ } catch (Throwable ex) {}}  \ {{ echo 'Caught Throwable. Retrying operation...'}}  \ {{ echo 'Exception message: ' + ex.getMessage()}}  \ {{ ex.printStackTrace()}}  \ {{ retry(5) {}}{{ checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']])}}  \ {{ }}}  \ {{ }}}But I cannot see the stacktrace as it goes in the error stream that I do not see in the console build log.Is there a way to copy this info to the console log?(My use case: I have many SVN checkout issues and I would like to be able to retry the checkout only when I get SVN related exceptions)  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 
  

[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-01-17 Thread vasilena.tren...@softwareag.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Vassilena Treneva edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Hey,What is the right way to redirect the stacktrace so that a user can see in the console log?  {quote} I have this snippet:{{try {}} {{ checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']])}} \{{ } catch (Throwable ex) {}} \{{ echo 'Caught Throwable. Retrying operation...'}} \{{ echo 'Exception message: ' + ex.getMessage()}} \{{ ex.printStackTrace()}} \{{ retry(5) {}} {{ checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']])}} \{{ }}} \{{ }}} {quote} But I cannot see the stacktrace as it goes in the error stream that I do not see in the console build log.Is there a way to copy this info to the console log?(My use case: I have many SVN checkout issues and I would like to be able to retry the checkout only when I get SVN related exceptions)  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 
   

[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-01-17 Thread vasilena.tren...@softwareag.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Vassilena Treneva commented on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Hey, What is the right way to redirect the stacktrace so that a user can see in the console log? I have this snippet: try { checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']]) } catch (Throwable ex) { echo 'Caught Throwable. Retrying operation...' echo 'Exception message: ' + ex.getMessage() ex.printStackTrace() retry(5) { checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']]) } } But I cannot see the stacktrace as it goes in the error stream that I do not see in the console build log. Is there a way to copy this info to the console log? (My use case: I have many SVN checkout issues and I would like to be able to retry the checkout only when I get SVN related exceptions)  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 

  
 
 

[JIRA] (JENKINS-44808) Unable to print stacktrace on jenkins pipeline

2019-01-17 Thread vasilena.tren...@softwareag.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Vassilena Treneva edited a comment on  JENKINS-44808  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Unable to print stacktrace on jenkins pipeline   
 

  
 
 
 
 

 
 Hey,What is the right way to redirect the stacktrace so that a user can see in the console log?I have this snippet: {{ try { }}  {{  checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']]) }}  {{ } catch (Throwable ex) { }}  {{  echo 'Caught Throwable. Retrying operation...' }}  {{  echo 'Exception message: ' + ex.getMessage() }}  {{  ex.printStackTrace() }}  {{  retry(5) { }}  {{   checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[cancelProcessOnExternalsFail: true, credentialsId: 'nirdevadm', depthOption: 'infinity', ignoreExternalsOption: true, local: '.', remote: "${params.branch}@${params.revision}"], [cancelProcessOnExternalsFail: true, credentialsId: 'bgqatest', depthOption: 'infinity', ignoreExternalsOption: true, local: 'gradle', remote: "${external}"]], quietOperation: false, workspaceUpdater: [$class: 'CheckoutUpdater']]) }}  {{  } }}  {{ } }} But I cannot see the stacktrace as it goes in the error stream that I do not see in the console build log.Is there a way to copy this info to the console log?(My use case: I have many SVN checkout issues and I would like to be able to retry the checkout only when I get SVN related exceptions)   
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)