Skip to content

Commit 35f265d

Browse files
tymaratsclaude
andcommitted
Fix KafkaConfiguration bean naming and duplicate WorkflowStatusListener conflict
Rename copy-pasted RabbitMQ bean names to Kafka. Mark workflowStatusListenerKafka as @primary to resolve conflict with upstream KafkaWorkflowStatusPublisherConfiguration which also provides a WorkflowStatusListener when conductor.workflow-status-listener.type=kafka. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent f4f7276 commit 35f265d

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

kafka/src/main/java/com/netflix/conductor/kafka/status/events/config/KafkaConfiguration.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
import org.springframework.boot.context.properties.EnableConfigurationProperties;
1717
import org.springframework.context.annotation.Bean;
1818
import org.springframework.context.annotation.Configuration;
19+
import org.springframework.context.annotation.Primary;
1920

2021
import com.netflix.conductor.core.listener.TaskStatusListener;
2122
import com.netflix.conductor.core.listener.WorkflowStatusListener;
@@ -39,17 +40,18 @@ public KafkaEventService kafkaEventService(KafkaProperties kafkaProperties) {
3940
havingValue = "kafka",
4041
matchIfMissing = false)
4142
@Bean
42-
public TaskStatusListener taskStatusPublisherRabbitMQ(
43+
public TaskStatusListener taskStatusPublisherKafka(
4344
KafkaEventService kafkaEventService, KafkaProperties kafkaProperties) {
4445
return new TaskStatusKafkaProducer(kafkaEventService, kafkaProperties);
4546
}
4647

48+
@Primary
4749
@ConditionalOnProperty(
4850
name = "conductor.workflow-status-listener.type",
4951
havingValue = "kafka",
5052
matchIfMissing = false)
5153
@Bean
52-
public WorkflowStatusListener workflowStatusListenerRabbitMQ(
54+
public WorkflowStatusListener workflowStatusListenerKafka(
5355
KafkaEventService kafkaEventService, KafkaProperties kafkaProperties) {
5456
return new WorkflowStatusKafkaProducer(kafkaEventService, kafkaProperties);
5557
}

0 commit comments

Comments
 (0)