Closed darenegade closed 1 year ago
@darenegade you can move this issue to the digiwf-core repository. The CoSys Integration is now developed in that repository.
Use Streaming Tempate V2
Use new Envs in Operations-Repo (Spring Cloud Functions and Topics) tu use incident/bpmn-error
@darenegade How can the artifact recognize business errors? Are there special http status codes?
@martind260 What are business error specifically for cosys depends on the cosys API. I'm not deep enough into this api to provide this information
@martind260 We can start with the obvious. Most errors should be technical (5xx, 401, 403) i guess. I don't know if the return body provides that information in some way
If u don't find any obvious business errors, we can go on with everything that goes into status=false ends up in incidents and business errors can be provided in a future enhancement with more info about the API
@darenegade @martind260 we should wait about 2 days before starting with this issue. The WebClient and JSON task will cause a lot of merge conflicts.
@darenegade @dominikhorn93 TOO LATE!
Is your feature request related to a problem? Please describe. If an error occourse the consumer (process) doesn't know why a document couldn't be created. The respone only delivers an status flag with true (document created) or false (document not created)
Describe the solution you'd like The integration needs to distinguish between business errors and technical errors Business errors needs to be delivered within the normal response Technical errors needs to be delivered within an special error response
Describe alternatives you've considered The error messages (technical and business) can be delivered within the same message, but the process needs to know if the job was successfull or not. On technical errors the job should stop and wait for retry (admin function)
Additional context
https://github.com/it-at-m/digiwf-core/blob/dev/digiwf-integrations/digiwf-cosys-integration/digiwf-cosys-integration-core/src/main/java/io/muenchendigital/digiwf/integration/cosys/api/MessageProcessor.java#L36-L41
https://github.com/it-at-m/digiwf-core/blob/dev/digiwf-integrations/digiwf-cosys-integration/digiwf-cosys-integration-core/src/main/java/io/muenchendigital/digiwf/integration/cosys/domain/service/CosysService.java#L70-L77