search and ai stabilization work, localization stablized.

This commit is contained in:
master
2026-02-24 23:29:36 +02:00
parent 4f947a8b61
commit b07d27772e
766 changed files with 55299 additions and 3221 deletions

View File

@@ -1,5 +1,6 @@
using StellaOps.Cryptography;
using System;
using static StellaOps.Localization.T;
namespace StellaOps.Configuration;
@@ -14,27 +15,27 @@ public sealed partial class AuthorityAckTokenOptions
if (string.IsNullOrWhiteSpace(PayloadType))
{
throw new InvalidOperationException("notifications.ackTokens.payloadType must be specified when ack tokens are enabled.");
throw new InvalidOperationException(_t("config.ack_token.payload_type_required"));
}
if (DefaultLifetime <= TimeSpan.Zero)
{
throw new InvalidOperationException("notifications.ackTokens.defaultLifetime must be greater than zero.");
throw new InvalidOperationException(_t("config.ack_token.default_lifetime_invalid"));
}
if (MaxLifetime <= TimeSpan.Zero || MaxLifetime < DefaultLifetime)
{
throw new InvalidOperationException("notifications.ackTokens.maxLifetime must be greater than zero and greater than or equal to defaultLifetime.");
throw new InvalidOperationException(_t("config.ack_token.max_lifetime_invalid"));
}
if (string.IsNullOrWhiteSpace(ActiveKeyId))
{
throw new InvalidOperationException("notifications.ackTokens.activeKeyId must be provided when ack tokens are enabled.");
throw new InvalidOperationException(_t("config.ack_token.key_id_required"));
}
if (string.IsNullOrWhiteSpace(KeyPath))
{
throw new InvalidOperationException("notifications.ackTokens.keyPath must be provided when ack tokens are enabled.");
throw new InvalidOperationException(_t("config.ack_token.key_path_required"));
}
if (string.IsNullOrWhiteSpace(KeySource))
@@ -59,7 +60,7 @@ public sealed partial class AuthorityAckTokenOptions
if (JwksCacheLifetime <= TimeSpan.Zero || JwksCacheLifetime > TimeSpan.FromHours(1))
{
throw new InvalidOperationException("notifications.ackTokens.jwksCacheLifetime must be between 00:00:01 and 01:00:00.");
throw new InvalidOperationException(_t("config.ack_token.jwks_cache_range"));
}
}
}