Esempio n. 1
0
        public async Task <string> Locate(string routePath, string key)
        {
            var route = await _serviceRouteProvider.SearchRoute(routePath);

            AddressModel result = new IpAddressModel();

            if (route != null)
            {
                result = await _addressSelector.SelectAsync(new AddressSelectContext()
                {
                    Address    = route.Address,
                    Descriptor = route.ServiceDescriptor,
                    HashCode   = _hashAlgorithm.Hash(key)
                });
            }
            return(result.ToString());
        }