Skip to content

Commit af28efc

Browse files
committed
jenkins-pipleline-step-execution
1 parent f5a3057 commit af28efc

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/main/java/com/browserstack/automate/ci/jenkins/pipeline/BrowserStackPipelineStepExecution.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
import org.jenkinsci.plugins.workflow.steps.BodyExecutionCallback;
1717
import org.jenkinsci.plugins.workflow.steps.EnvironmentExpander;
1818
import org.jenkinsci.plugins.workflow.steps.StepContext;
19-
import org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution;
19+
import org.jenkinsci.plugins.workflow.steps.StepExecution;
2020

2121
import java.io.IOException;
2222
import java.io.PrintStream;
@@ -25,7 +25,7 @@
2525
import static com.browserstack.automate.ci.common.logger.PluginLogger.log;
2626
import static com.browserstack.automate.ci.common.logger.PluginLogger.logError;
2727

28-
public class BrowserStackPipelineStepExecution extends SynchronousNonBlockingStepExecution<Void> {
28+
public class BrowserStackPipelineStepExecution extends StepExecution {
2929
private static final long serialVersionUID = -8810137779949881645L;
3030
private String credentialsId;
3131
private StepContext context;
@@ -42,7 +42,7 @@ protected BrowserStackPipelineStepExecution(StepContext context, String credenti
4242
}
4343

4444
@Override
45-
protected Void run() throws Exception {
45+
public boolean start() throws Exception {
4646
Run run = context.get(Run.class);
4747
TaskListener taskListener = context.get(TaskListener.class);
4848
Launcher launcher = context.get(Launcher.class);
@@ -55,7 +55,7 @@ protected Void run() throws Exception {
5555
if (credentials == null) {
5656
logError(logger, "Credentials id is invalid. Aborting!!!");
5757
tracker.sendError("No Credentials Available", true, "PipelineExecution");
58-
return null;
58+
return false;
5959
}
6060

6161
if (credentials.hasUsername() && credentials.hasAccesskey()) {
@@ -97,7 +97,7 @@ protected Void run() throws Exception {
9797

9898
tracker.pluginInitialized(overrides.get(Constants.JENKINS_BUILD_TAG),
9999
(this.localConfig != null), true);
100-
return null;
100+
return false;
101101
}
102102

103103
public void startBrowserStackLocal(String buildTag, PrintStream logger, String accessKey,

0 commit comments

Comments
 (0)