private void PopulatePrototypeWithVariableProperties(IShardConfiguration config) { SafeSet(prototypeConfiguration, Environment.ConnectionString, config.ConnectionString); SafeSet(prototypeConfiguration, Environment.ConnectionStringName, config.ConnectionStringName); SafeSet(prototypeConfiguration, Environment.CacheRegionPrefix, config.ShardCacheRegionPrefix); SafeSet(prototypeConfiguration, Environment.SessionFactoryName, config.ShardSessionFactoryName); SafeSet(prototypeConfiguration, ShardedEnvironment.ShardIdProperty, config.ShardId.ToString()); }
private void PopulatePrototypeWithVariableProperties(IShardConfiguration config) { var oldDefaultSchema = PropertiesHelper.GetString(Environment.DefaultSchema, prototypeConfiguration.Properties, null); SafeSet(prototypeConfiguration, Environment.ConnectionString, config.ConnectionString); SafeSet(prototypeConfiguration, Environment.ConnectionStringName, config.ConnectionStringName); SafeSet(prototypeConfiguration, Environment.CacheRegionPrefix, config.ShardCacheRegionPrefix); SafeSet(prototypeConfiguration, Environment.DefaultSchema, config.DefaultSchema); SafeSet(prototypeConfiguration, Environment.SessionFactoryName, config.ShardSessionFactoryName); SafeSet(prototypeConfiguration, ShardedEnvironment.ShardIdProperty, config.ShardId.ToString(CultureInfo.InvariantCulture)); if (config.DefaultSchema != null && config.DefaultSchema != oldDefaultSchema) { ReplaceSchema(prototypeConfiguration, oldDefaultSchema, config.DefaultSchema); } }
private void PopulatePrototypeWithVariableProperties(IShardConfiguration config) { throw new System.NotImplementedException(); }
private void PopulatePrototypeWithVariableProperties(IShardConfiguration config) { var oldDefaultSchema = PropertiesHelper.GetString(Environment.DefaultSchema, prototypeConfiguration.Properties, null); SafeSet(prototypeConfiguration, Environment.ConnectionString, config.ConnectionString); SafeSet(prototypeConfiguration, Environment.ConnectionStringName, config.ConnectionStringName); SafeSet(prototypeConfiguration, Environment.CacheRegionPrefix, config.ShardCacheRegionPrefix); SafeSet(prototypeConfiguration, Environment.DefaultSchema, config.DefaultSchema); SafeSet(prototypeConfiguration, Environment.SessionFactoryName, config.ShardSessionFactoryName); SafeSet(prototypeConfiguration, ShardedEnvironment.ShardIdProperty, config.ShardId.ToString()); if (config.DefaultSchema != null && config.DefaultSchema != oldDefaultSchema) { ReplaceSchema(prototypeConfiguration, oldDefaultSchema, config.DefaultSchema); } }