internal AzureSilo(IServiceRuntimeWrapper serviceRuntimeWrapper) { this.serviceRuntimeWrapper = serviceRuntimeWrapper; DataConnectionConfigurationSettingName = AzureConstants.DataConnectionConfigurationSettingName; SiloEndpointConfigurationKeyName = AzureConstants.SiloEndpointConfigurationKeyName; ProxyEndpointConfigurationKeyName = AzureConstants.ProxyEndpointConfigurationKeyName; StartupRetryPause = AzureConstants.STARTUP_TIME_PAUSE; // 5 seconds MaxRetries = AzureConstants.MAX_RETRIES; // 120 x 5s = Total: 10 minutes logger = LogManager.GetLogger("OrleansAzureSilo", LoggerType.Runtime); }
internal AzureSilo(IServiceRuntimeWrapper serviceRuntimeWrapper) { this.serviceRuntimeWrapper = serviceRuntimeWrapper; DataConnectionConfigurationSettingName = AzureConstants.DataConnectionConfigurationSettingName; SiloEndpointConfigurationKeyName = AzureConstants.SiloEndpointConfigurationKeyName; ProxyEndpointConfigurationKeyName = AzureConstants.ProxyEndpointConfigurationKeyName; StartupRetryPause = AzureConstants.STARTUP_TIME_PAUSE; // 5 seconds MaxRetries = AzureConstants.MAX_RETRIES; // 120 x 5s = Total: 10 minutes logger = LogManager.GetLogger("OrleansAzureSilo", LoggerType.Runtime); }
internal AzureSilo(IServiceRuntimeWrapper serviceRuntimeWrapper, ILoggerFactory loggerFactory) { this.serviceRuntimeWrapper = serviceRuntimeWrapper; DataConnectionConfigurationSettingName = AzureConstants.DataConnectionConfigurationSettingName; SiloEndpointConfigurationKeyName = AzureConstants.SiloEndpointConfigurationKeyName; ProxyEndpointConfigurationKeyName = AzureConstants.ProxyEndpointConfigurationKeyName; StartupRetryPause = AzureConstants.STARTUP_TIME_PAUSE; // 5 seconds MaxRetries = AzureConstants.MAX_RETRIES; // 120 x 5s = Total: 10 minutes this.loggerFactory = loggerFactory; logger = loggerFactory.CreateLogger <AzureSilo>(); }
internal static ClusterConfiguration DefaultConfiguration(IServiceRuntimeWrapper serviceRuntimeWrapper) { var config = new ClusterConfiguration(); config.Globals.LivenessType = GlobalConfiguration.LivenessProviderType.AzureTable; config.Globals.ClusterId = serviceRuntimeWrapper.DeploymentId; try { config.Globals.DataConnectionString = serviceRuntimeWrapper.GetConfigurationSettingValue(AzureConstants.DataConnectionConfigurationSettingName); } catch (Exception exc) { if (exc.GetType().Name.Contains("RoleEnvironmentException")) { config.Globals.DataConnectionString = null; } else { throw; } } return(config); }
internal static ClusterConfiguration DefaultConfiguration(IServiceRuntimeWrapper serviceRuntimeWrapper) { var config = new ClusterConfiguration(); config.Globals.LivenessType = GlobalConfiguration.LivenessProviderType.AzureTable; config.Globals.DeploymentId = serviceRuntimeWrapper.DeploymentId; try { config.Globals.DataConnectionString = serviceRuntimeWrapper.GetConfigurationSettingValue(AzureConstants.DataConnectionConfigurationSettingName); } catch (Exception exc) { if (exc.GetType().Name.Contains("RoleEnvironmentException")) { config.Globals.DataConnectionString = null; } else { throw; } } return config; }