2021-08-27 14:50:49 +00:00
|
|
|
|
|
2021-08-24 08:08:58 +00:00
|
|
|
|
using ASC.Common;
|
|
|
|
|
using ASC.Common.Utils;
|
|
|
|
|
|
2021-08-27 14:50:49 +00:00
|
|
|
|
namespace ASC.Webhooks.Service
|
2021-08-24 08:08:58 +00:00
|
|
|
|
{
|
|
|
|
|
[Singletone]
|
|
|
|
|
public class Settings
|
|
|
|
|
{
|
|
|
|
|
public Settings()
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
public Settings(ConfigurationExtension configuration)
|
|
|
|
|
{
|
|
|
|
|
var cfg = configuration.GetSetting<Settings>("webhooks");
|
|
|
|
|
RepeatCount = cfg.RepeatCount ?? 5;
|
|
|
|
|
ThreadCount = cfg.ThreadCount ?? 1;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public int? RepeatCount { get; }
|
|
|
|
|
public int? ThreadCount { get; }
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|