Skip to content
Discussion options

You must be logged in to vote

Yes, that is a common use case. Once you subscribe to events on a topic, you can set up a Flux in your data fetcher and emit events based on the events coming in from the topic.

@DgsSubscription
public Publisher<SomeEvent> someEvent() 
return Flux.create { sink ->
            // set up a listener for the topic
            // consume and handle events from the queue
            // emit the event e.g. sink.next(it)
 }

Hope that answers your question.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@Feedcube
Comment options

Answer selected by Feedcube
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants