Event Registry with My Own Kafka Config

Hello all,

I want to use event registry feature of flowable only with workflow related logic and I want to use my own kafka config with my other business logic. That’s why I already have kafka config in my microservice. That causes this error

***************************
APPLICATION FAILED TO START
***************************

Description:

Parameter 1 of method kafkaChannelDefinitionProcessor in org.flowable.spring.boot.eventregistry.EventRegistryAutoConfiguration$EventRegistryKafkaConfiguration required a bean of type 'org.springframework.kafka.core.KafkaOperations' that could not be found.


Action:

Consider defining a bean of type 'org.springframework.kafka.core.KafkaOperations' in your configuration.


Process finished with exit code 1

Is there a better way to do this than just implementing KafkaOperations bean in my config class?

   @Bean
    public KafkaOperations kafkaOperations(){
        return new KafkaOperations() {
            @Override
            public ListenableFuture<SendResult> sendDefault(Object o) {
                return null;
            }

            @Override
            public ListenableFuture<SendResult> sendDefault(Object o, Object o2) {
                return null;
            }

            @Override
            public ListenableFuture<SendResult> sendDefault(Integer integer, Object o, Object o2) {
                return null;
            }

            @Override
            public ListenableFuture<SendResult> sendDefault(Integer integer, Long aLong, Object o, Object o2) {
                return null;
            }

            @Override
            public ListenableFuture<SendResult> send(String s, Object o) {
                return null;
            }

            @Override
            public ListenableFuture<SendResult> send(String s, Object o, Object o2) {
                return null;
            }

            @Override
            public ListenableFuture<SendResult> send(String s, Integer integer, Object o, Object o2) {
                return null;
            }

            @Override
            public ListenableFuture<SendResult> send(String s, Integer integer, Long aLong, Object o, Object o2) {
                return null;
            }

            @Override
            public ListenableFuture<SendResult> send(ProducerRecord producerRecord) {
                return null;
            }

            @Override
            public ListenableFuture<SendResult> send(Message message) {
                return null;
            }

            @Override
            public List<PartitionInfo> partitionsFor(String s) {
                return null;
            }

            @Override
            public Map<MetricName, ? extends Metric> metrics() {
                return null;
            }

            @Override
            public Object execute(ProducerCallback producerCallback) {
                return null;
            }

            @Override
            public Object executeInTransaction(OperationsCallback operationsCallback) {
                return null;
            }

            @Override
            public void flush() {

            }

            @Override
            public void sendOffsetsToTransaction(Map map) {

            }

            @Override
            public void sendOffsetsToTransaction(Map map, String s) {

            }

            @Override
            public boolean isTransactional() {
                return false;
            }

            @Override
            public ConsumerRecord receive(String s, int i, long l, Duration duration) {
                return null;
            }

            @Override
            public ConsumerRecords receive(Collection collection, Duration duration) {
                return null;
            }
        };
    }

I don’t want to override all these methods which I don’t know much about. I would appreciate your help

Umut