Multiple topics in Kafka

135 views
Skip to first unread message

Alexandre Caeiro

unread,
Jun 16, 2021, 10:59:49 AM6/16/21
to Kogito development mailing list

Hi all,

I've created 2 workflows each with it's own message start event. I've also created 2 topics in the application.properties file using the 'topics' keyword. However, when publishing to one topic, the other workflow is also triggered. Is there a way around this?

Thanks for the help

Cristiano Nicolai

unread,
Jun 17, 2021, 6:46:37 AM6/17/21
to Kogito development mailing list
Hi,

If you're using the cloudevents as payload and the kogito-cloudevents-quarkus-addon is added to the process, the message name in the bpmn start node should match the type attribute in the cloud event message. That way it could trigger one or the other.
That's from a high level perspective, maybe if you could share more details, including the application.properties or even a small reproducer project, that would be really helpful.

Thanks



--
You received this message because you are subscribed to the Google Groups "Kogito development mailing list" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kogito-developm...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kogito-development/8cc0981d-7f38-47aa-b092-8d1d955d9f30n%40googlegroups.com.


--
Best regards,

Cristiano Nicolai

Alexandre Caeiro

unread,
Jun 17, 2021, 2:27:18 PM6/17/21
to Kogito development mailing list
Hi,

The message name does match the type attribute. So let's say I send a message with type 'A' this triggers workflow with start event message 'A' but will also trigger an error in workflow 'B' because it doesn't recognize the object in the 'data' field of the cloudevent message (each workflow should receive a different data payload). To make this clearer:

Workflow A starts with message A which has a data field of type Foo.
Workflow B starts with message B which has a data field of type Bar.

When sending message A, this will trigger workflow A which performs correctly but it also throws an error from workflow B due to unrecognized fields and vice-versa.

application.png

Thank you.
Reply all
Reply to author
Forward
0 new messages