Issue Type: Bug Bug
Assignee: Jesse Glick
Components: workflow-plugin
Created: 17/Mar/15 9:15 AM
Description:

We start by creating a class in the groovy script but we've also tried having another groovy script as well as create the class in Java.

When we then declare create an object with the class "def sc = new SimpleClass("Nisse")" the workflow will exit with an error code.

The part "echo "this is the end"" will not be executed.

If I remove the def sc = new ... then the job will exit and all the echo commands will run.

workflow.groovy
class SimpleClass{
    
    def name = ""
    
    public SimpleClass(def name){
        this.name = name
    }    
    
    public def greet(){
        return "Hello " + this.name
    }
    
}

def sc = new SimpleClass("Nisse")

echo sc.greet()
node("linux || windows") {
    echo "enter node"
    ws("rb-sb-revision") {
        echo "Node + WS 1"
    }
    echo "exit WS"
}
echo "this is the end"
Environment: Jenkins 1.596.1
Workflow plugin 1.4

Xubuntu 14.04

Groovy Version: 1.8.6 JVM: 1.7.0_76 Vendor: Oracle Corporation OS: Linux
Java(TM) SE Runtime Environment (build 1.7.0_76-b13)
Project: Jenkins
Priority: Critical Critical
Reporter: Marcus Jacobsson
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

--
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.

Reply via email to