|
The Flow engine developed in scope of US1030377: PoC - FlowEngine allows us to write complex flows with rollback, improved error handling, etc. in a more concise, consistent way. This story aims to integrate the flow engine into the application manager for these purposes.
Scope:
- Pull in the folio-backend-tools shared library, where the flow engine is implemented. (pom.xml)
- Incorporate the flow engine / business logic updates
- We're currently publishing events to kafka upon discovery registration, update, removal. This is another situation where we want to ensure that the discovery info is persisted and the events are successfully published. If either fails, we should rollback and return an error.
- In US1037650: Application Manager - Implement an event outbox we incorporate the outbox pattern for publishing events. Depending on which story is pulled first depends on how the flow engine will be incorporated. Either:
- Writing to the discovery table + writing to the outbox should be an all-or-nothing operation... OR
- NOTE: A DB transaction might be all that's needed here, but if using the flow engine makes the code more readable or easier to maintain, let's use it in conjunction with a transaction. If it doesn't make sense to use the flow engine here, we might be able to scrap this story completely.
- Writing to the discovery table + successfully publishing the events should be an all-or-nothing operation.
- Documentation updates (README, wiki, etc.)
|