| | | 1 | | namespace Elsa.UserTasks.Options; |
| | | 2 | | |
| | | 3 | | public sealed class UserTasksOptions |
| | | 4 | | { |
| | 85 | 5 | | public string DefaultTenantId { get; set; } = ""; |
| | 85 | 6 | | public string DefaultProvider { get; set; } = "default"; |
| | 84 | 7 | | public string SubjectClaimType { get; set; } = "sub"; |
| | 84 | 8 | | public string TenantClaimType { get; set; } = "tenant"; |
| | 84 | 9 | | public string ProviderClaimType { get; set; } = "elsa:identity-provider"; |
| | 84 | 10 | | public string DisplayNameClaimType { get; set; } = "name"; |
| | 84 | 11 | | public ICollection<string> GroupClaimTypes { get; set; } = ["groups", "group"]; |
| | 84 | 12 | | public ICollection<string> PermissionClaimTypes { get; set; } = ["permission", "permissions"]; |
| | 178 | 13 | | public int MaximumPayloadBytes { get; set; } = 256 * 1024; |
| | 118 | 14 | | public TimeSpan DefaultInvitationLifetime { get; set; } = TimeSpan.FromDays(7); |
| | | 15 | | |
| | | 16 | | /// <summary>Upper bound on a guest session, applied on top of the invitation's own expiry.</summary> |
| | 154 | 17 | | public TimeSpan GuestSessionLifetime { get; set; } = TimeSpan.FromHours(4); |
| | | 18 | | |
| | | 19 | | /// <summary>Attempts allowed per caller partition within <see cref="AnonymousRateLimitWindow"/>.</summary> |
| | 91 | 20 | | public int AnonymousRateLimit { get; set; } = 10; |
| | | 21 | | |
| | 86 | 22 | | public TimeSpan AnonymousRateLimitWindow { get; set; } = TimeSpan.FromMinutes(5); |
| | | 23 | | |
| | | 24 | | /// <summary>Back-off schedule for invitation delivery retries. Delivery is abandoned once the list is exhausted.</s |
| | 18 | 25 | | public IReadOnlyList<TimeSpan> InvitationDeliveryRetryDelays { get; set; } = |
| | 81 | 26 | | [TimeSpan.FromSeconds(15), TimeSpan.FromMinutes(1), TimeSpan.FromMinutes(5), TimeSpan.FromMinutes(30)]; |
| | | 27 | | |
| | | 28 | | /// <summary>Advertised to clients through the feature capability descriptor.</summary> |
| | 81 | 29 | | public bool RealtimeEnabled { get; set; } = true; |
| | | 30 | | |
| | 81 | 31 | | public int PollingIntervalSeconds { get; set; } = 30; |
| | | 32 | | |
| | | 33 | | /// <summary>How often the hosted worker marks overdue tasks and applies the timeout outcome.</summary> |
| | 81 | 34 | | public TimeSpan DueSweepInterval { get; set; } = TimeSpan.FromMinutes(1); |
| | | 35 | | |
| | | 36 | | /// <summary>How often the hosted worker reconciles committed bookmarks against projected tasks.</summary> |
| | 81 | 37 | | public TimeSpan ReconciliationInterval { get; set; } = TimeSpan.FromMinutes(15); |
| | | 38 | | |
| | | 39 | | /// <summary>Tenants swept by the hosted workers. Empty means the default tenant only.</summary> |
| | 81 | 40 | | public ICollection<string> WorkerTenantIds { get; set; } = []; |
| | | 41 | | } |