public static LoggingLevel ApplicationInsightsLoggingLevel(this IEnvironmentConfiguration config, bool throwException = false)
        {
            LoggingLevel loggingLevel;
            var          configLevel = config.PlatformOrConfigCache(KeyApplicationInsightsLoggingLevel);

            if (!string.IsNullOrEmpty(configLevel) && Enum.TryParse(configLevel, out loggingLevel))
            {
                return(loggingLevel);
            }

            return(LoggingLevel.Warning);
        }
 public static string ApplicationInsightsKey(this IEnvironmentConfiguration config, bool throwException = false)
 => config.PlatformOrConfigCache(KeyApplicationInsights);
 public static string EventHubsConnection(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyEventHubsConnection);
Beispiel #4
0
 public static string ServiceBusConnection(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyServiceBusConnection);
Beispiel #5
0
 public static string LogStorageAccountName(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyLogStorageAccountName, config.StorageAccountName());
Beispiel #6
0
 public static int?EncryptionKeySize(this IEnvironmentConfiguration config) => string.IsNullOrEmpty(config.PlatformOrConfigCache(KeyEncryptionKeySize)) ? default(int?) : config.PlatformOrConfigCacheInt(KeyEncryptionKeySize);
Beispiel #7
0
 public static string StorageAccountAccessKey(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyStorageAccountAccessKey);
 public static string KeyVaultSecretBaseUri(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyKeyVaultSecretBaseUri);
 public static string DocDBCollectionName(this IEnvironmentConfiguration config, bool throwExceptionIfNotFound = false)
 => config.PlatformOrConfigCache(KeyDocDBCollectionName, throwExceptionIfNotFound: throwExceptionIfNotFound);
 public static string DocDBAccountAccessKey(this IEnvironmentConfiguration config, bool throwExceptionIfNotFound = false)
 => config.PlatformOrConfigCache(KeyDocDBAccountAccessKey, throwExceptionIfNotFound: throwExceptionIfNotFound);
Beispiel #11
0
 public static string AuthTokenLifeInMin(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyAuthTokenLifeInMin, "30");
Beispiel #12
0
 public static string AuthIssuer(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyAuthIssuer);
Beispiel #13
0
 public static string AuthAudiences(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyAuthAudiences);
Beispiel #14
0
 public static Sha512SignatureHelper SignatureProvider(this IEnvironmentConfiguration config) => new Sha512SignatureHelper(config.PlatformOrConfigCache(KeyAuthSignature));
Beispiel #15
0
 public static string EncryptionId(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyEncryptionId, "transport");
 public static string Client(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyClient);
 public static string KeyVaultClientSecret(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyKeyVaultClientSecret);
 public static string AesTransportEncryptionKey(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyAesTransportEncryptionKey, throwExceptionIfNotFound: true);
 public static string AzureTableStorageConfigSASKey(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyAzureTableStorageConfigSASKey);
Beispiel #20
0
 public static string RedisCacheConnection(this IEnvironmentConfiguration config, bool throwExceptionIfNotFound = false)
 => config.PlatformOrConfigCache(KeyRedisCacheConnection, throwExceptionIfNotFound: throwExceptionIfNotFound);
Beispiel #21
0
 public static string EncryptionKey(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyEncryptionKey);
Beispiel #22
0
 public static string DocDBCollectionName(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyDocDBCollectionName);
Beispiel #23
0
 public static string AzureStorageAccountAccessKey(this IEnvironmentConfiguration config, bool throwExceptionIfNotFound = true)
 => config.PlatformOrConfigCache(KeyAzureStorageAccountAccessKey, throwExceptionIfNotFound: throwExceptionIfNotFound);
Beispiel #24
0
 public static IList <string> WebLogFilterLevels(this IEnvironmentConfiguration config) => config.PlatformOrConfigCache(KeyWebLogFilterLevels, "All")?.Split(',').ToList() ?? new List <string>();