V13: request queueing (#15176)

* Implement persistence

* Start implementing repository

* Implement repository

* Implement request service

* Dont run WebhookFiring if not in runtime mode run

* Refactor repository and service to have full CRUD

* add tests for Request service

* Implement WebhookRequest lock

* Register hosted service

* Add try catch when firing HttpRequest

* Add migration

* Refactor to use renamed IWebhookService

* Refactor tests too

* Add setting to configure webhook firing period

* Update docs

* Review fixes

* Add column renaming migration

* Remove unused service

* run request in parralel

* Refactor to fire parallel in background

---------

Co-authored-by: Zeegaan <nge@umbraco.dk>
Co-authored-by: Bjarke Berg <mail@bergmania.dk>
This commit is contained in:
Nikolaj Geisle
2023-11-13 15:49:02 +01:00
committed by GitHub
parent 04ac1542aa
commit 46df3a05a7
24 changed files with 565 additions and 92 deletions

View File

@@ -7,6 +7,7 @@ public class WebhookSettings
{
private const bool StaticEnabled = true;
private const int StaticMaximumRetries = 5;
internal const string StaticPeriod = "00:00:10";
/// <summary>
/// Gets or sets a value indicating whether webhooks are enabled.
@@ -31,4 +32,10 @@ public class WebhookSettings
/// </remarks>
[DefaultValue(StaticMaximumRetries)]
public int MaximumRetries { get; set; } = StaticMaximumRetries;
/// <summary>
/// Gets or sets a value for the period of the webhook firing.
/// </summary>
[DefaultValue(StaticPeriod)]
public TimeSpan Period { get; set; } = TimeSpan.Parse(StaticPeriod);
}