Reputation: 953
Can I have a reliable dictionary which holds another reliable dictionary as its value?
var dicts = await StateManager.GetOrAddAsync<IReliableDictionary<string, IReliableDictionary<string, string>>>("Dictionaries");
My first try gave a serialization error:
Type 'Microsoft.ServiceFabric.Data.Collections.DistributedDictionary`2[System.String,System.String]' cannot be serialized. Consider marking it with the DataContractAttribute attribute, and marking all of its members you want serialized with the DataMemberAttribute attribute.
If the type is a collection, consider marking it with the CollectionDataContractAttribute.
See the Microsoft .NET Framework documentation for other supported types.
Upvotes: 0
Views: 158