Hi,
I'm trying to use this pipeline command on my Windows slave node:
step([$class: 'LogParserPublisher', parsingRulesPath: all_rules_file,
useProjectRule: false, failBuildOnError: true, unstableOnWarning: true,
showGraphs: true]);
I get the following error:
ERROR: Failed to parse console log
java.io.FileNotFoundException: c:\Jenkins\workspace\MyProject@tmp\all_rules.txt
(No such file or directory)
The file is created at runtime on the slave, it's there and filled properly
and permission are correct. I was wondering, if I invoke the step
LogParserPublisher command, does it get run on the master even if declared
inside the slave node? do I have to stash/copy the rules files back to the
master? then do a new node('master') at the end?
if so I will have to send the email after this, so my ig try catch will
overlap 2 node, is that legal code? and the email will get send by the
master instead I suppose
Right now I have
node('windows')
{
try
{
...
step([$class: 'LogParserPublisher', parsingRulesPath: all_rules_file,
useProjectRule: false, failBuildOnError: true, unstableOnWarning: true,
showGraphs: true]);
...
}
catch(any)
{
currentBuild.result = 'FAILURE'
throw any //rethrow exception to prevent the build from proceeding
}
finally
{
emailext ...
}
}
What I should do to have the LogParserPublisher done back on the master,
but doesn't seem like ligit code:
try
{
node('windows')
{
...
stash includes: "all_rules.txt", name: 'MyRules'
...
}
node('master')
{
def tempo_dir = pwd([tmp: true])
dir(tempo_dir)
{
unstash name: 'MyRules'
step([$class: 'LogParserPublisher', parsingRulesPath:
"${tempo_dir}/all_rules.txt", useProjectRule: false, failBuildOnError:
true, unstableOnWarning: true, showGraphs: true]);
}
}
}
catch(any)
{
currentBuild.result = 'FAILURE'
throw any //rethrow exception to prevent the build from proceeding
}
finally
{
node('master')
{
// I need a node to perform command here but...
emailext ...
}
}
how does one get to send an email if anything failed from any node actions?
--
You received this message because you are subscribed to the Google Groups
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/4c33eb52-5a8d-4277-ada8-579008a4af25%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.