I know that the Webhooks have a retry feature with built in scheduler, my question is if there is any generic way to use similar utilities to lets say http-requests to external resources?
Litium version: 8.7.0
I know that the Webhooks have a retry feature with built in scheduler, my question is if there is any generic way to use similar utilities to lets say http-requests to external resources?
Litium version: 8.7.0
I think it’s little depend on the use-case and what you try to guard from.
The simplest is to use Polly to setup retry policies, Implement HTTP call retries with exponential backoff with Polly | Microsoft Learn. If you need to have more advance use case that also working over server restarts you need to implement that logic your self, in Litium we use the SchedulerService to schedule a future retry of the failed web hook.
Thank you for the answer. I’m looking for something that persists after server restart. Now I know we have to build that from scratch. A followup question then, how would one persist data not related to any litium entity?
This is little depend on the need and how much and what type of data. If it is like paramters into the scheduler for executing the scheduler, you pass them in as parameters in the execute method, then the system will automatic store the value and reuse during execution.
If it is small settings you have the Common.SettingService that can be sued, with that you can store both personal and global settings.
If there is larger data structures you need to build the storage by yourself to match what you need, Litium does not have a “general all purpose” data layer that can be used.
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.