private ActivationAddress GetClientActivationAddress(GrainId clientId) { // Need to pick a unique deterministic ActivationId for this client. // We store it in the grain directory and there for every GrainId we use ActivationId as a key // so every GW needs to behave as a different "activation" with a different ActivationId (its not enough that they have different SiloAddress) string stringToHash = clientId.ToParsableString() + myAddress.Endpoint + myAddress.Generation.ToString(System.Globalization.CultureInfo.InvariantCulture); Guid hash = Utils.CalculateGuidHash(stringToHash); UniqueKey key = UniqueKey.NewKey(hash); return(ActivationAddress.GetAddress(myAddress, clientId, ActivationId.GetActivationId(key))); }
private ActivationAddress GetClientActivationAddress(GrainId clientId) { return(ActivationAddress.GetAddress(myAddress, clientId, ActivationId.GetActivationId(clientId))); }