Search in sources :

Example 1 with StageStatusHandler

use of com.thoughtworks.go.server.domain.StageStatusHandler in project gocd by gocd.

the class JobStatusListener method onMessage.

public void onMessage(final JobStatusMessage message) {
    if (message.getJobState().isCompleted()) {
        final Stage stage = stageService.findStageWithIdentifier(message.getStageIdentifier());
        stage.statusHandling(new StageStatusHandler() {

            public void onNormalCompletion(StageState stageState, StageResult stageResult) {
                stageStatusTopic.post(new StageStatusMessage(message.getStageIdentifier(), stageState, stageResult));
            }
        });
    }
}
Also used : StageState(com.thoughtworks.go.domain.StageState) StageStatusHandler(com.thoughtworks.go.server.domain.StageStatusHandler) StageResult(com.thoughtworks.go.domain.StageResult) Stage(com.thoughtworks.go.domain.Stage)

Aggregations

Stage (com.thoughtworks.go.domain.Stage)1 StageResult (com.thoughtworks.go.domain.StageResult)1 StageState (com.thoughtworks.go.domain.StageState)1 StageStatusHandler (com.thoughtworks.go.server.domain.StageStatusHandler)1