Hi,
I’m implementing some “workflow”, where based on event I need to call external service. Is it ok to call services from within sagas or is here better pattern/place where this should be invoked (special type of event handler?).
What if I need to pass request parameters to this event handlers and don’t want to store them in event metadata (mainly spring Oauth authentication)?
Are you calling the services to get data from or are you calling them to invoke consequence logic of your use case ? The former i guess would be ok, the latter seems more like an eventhandler thing.
it’s generally ok to call external services from Sagas. You can consider that as sending a command or performing a query. Perfectly fine things of a saga (or event handler) to do.