All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.redhat.parodos.examples.negative.simple.SequentialFailedWorkFlowConfiguration Maven / Gradle / Ivy

package com.redhat.parodos.examples.negative.simple;

import com.redhat.parodos.examples.negative.simple.task.FailedWorkFlowTask;
import com.redhat.parodos.workflow.annotation.Infrastructure;
import com.redhat.parodos.workflows.workflow.SequentialFlow;
import com.redhat.parodos.workflows.workflow.WorkFlow;
import lombok.extern.slf4j.Slf4j;

import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
@Slf4j
public class SequentialFailedWorkFlowConfiguration {

	@Bean
	FailedWorkFlowTask failedWorkFlowTask() {
		return new FailedWorkFlowTask();
	}

	@Bean(name = "sequentialFailedWorkFlow")
	@Infrastructure
	WorkFlow simpleFailedWorkFlow(@Qualifier("failedWorkFlowTask") FailedWorkFlowTask failedWorkFlowTask) {
		// @formatter:off
		return SequentialFlow
				.Builder.aNewSequentialFlow()
				.named("sequentialFailedWorkFlow")
				.execute(failedWorkFlowTask)
				.build();
		// @formatter:on
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy