本文整理匯總了C#中Orleans.Runtime.Configuration.NodeConfiguration.Load方法的典型用法代碼示例。如果您正苦於以下問題:C# NodeConfiguration.Load方法的具體用法?C# NodeConfiguration.Load怎麽用?C# NodeConfiguration.Load使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Orleans.Runtime.Configuration.NodeConfiguration
的用法示例。
在下文中一共展示了NodeConfiguration.Load方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: CalculateOverrides
private void CalculateOverrides()
{
if (Globals.LivenessEnabled &&
Globals.LivenessType == GlobalConfiguration.LivenessProviderType.NotSpecified)
{
if (Globals.UseSqlSystemStore)
{
Globals.LivenessType = GlobalConfiguration.LivenessProviderType.SqlServer;
}
else if (Globals.UseAzureSystemStore)
{
Globals.LivenessType = GlobalConfiguration.LivenessProviderType.AzureTable;
}
else if (Globals.UseZooKeeperSystemStore)
{
Globals.LivenessType = GlobalConfiguration.LivenessProviderType.ZooKeeper;
}
else
{
Globals.LivenessType = GlobalConfiguration.LivenessProviderType.MembershipTableGrain;
}
}
if (Globals.UseMockReminderTable)
{
Globals.SetReminderServiceType(GlobalConfiguration.ReminderServiceProviderType.MockTable);
}
else if (Globals.ReminderServiceType == GlobalConfiguration.ReminderServiceProviderType.NotSpecified)
{
if (Globals.UseSqlSystemStore)
{
Globals.SetReminderServiceType(GlobalConfiguration.ReminderServiceProviderType.SqlServer);
}
else if (Globals.UseAzureSystemStore)
{
Globals.SetReminderServiceType(GlobalConfiguration.ReminderServiceProviderType.AzureTable);
}
else if (Globals.UseZooKeeperSystemStore)
{
Globals.SetReminderServiceType(GlobalConfiguration.ReminderServiceProviderType.Disabled);
}
else
{
Globals.SetReminderServiceType(GlobalConfiguration.ReminderServiceProviderType.ReminderTableGrain);
}
}
foreach (var p in overrideXml)
{
var n = new NodeConfiguration(Defaults);
n.Load(ParseXml(new StringReader(p.Value)));
InitNodeSettingsFromGlobals(n);
Overrides[n.SiloName] = n;
}
}