Skip to content

Commit

Permalink
[Fix #3642] Gonzalos comments
Browse files Browse the repository at this point in the history
  • Loading branch information
fjtirado committed Aug 29, 2024
1 parent 0030180 commit d17602e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion springboot/addons/task-notification/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
</dependency>
<dependency>
<groupId>org.kie.kogito</groupId>
<artifactId>kogito-events-api</artifactId>
<artifactId>kogito-events-core</artifactId>
</dependency>

<!-- test dependencies -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@

import org.kie.kogito.event.DataEvent;
import org.kie.kogito.event.EventPublisher;
import org.kie.kogito.event.usertask.UserTaskInstanceDeadlineDataEvent;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
Expand All @@ -42,7 +43,7 @@ public class SpringNotificationEventPublisher implements EventPublisher {

@Override
public void publish(DataEvent<?> event) {
if (event.getType().startsWith("UserTaskDeadline")) {
if (event instanceof UserTaskInstanceDeadlineDataEvent) {
logger.debug("About to publish event {} to Kafka topic {}", event, topic);
try {
emitter.send(topic, event);
Expand Down

0 comments on commit d17602e

Please sign in to comment.