public async Task <IReadOnlyList <Instance> > GetSearchEndpointsAsync( RegionInformation regionInformation, CancellationToken token) { var result = await _azureManagementApiWrapper.GetCloudServicePropertiesAsync( _configuration.Value.Subscription, regionInformation.ResourceGroup, regionInformation.ServiceName, ProductionSlot, token); var cloudService = AzureHelper.ParseCloudServiceProperties(result); var instances = GetInstances(cloudService.Uri, cloudService.InstanceCount, regionInformation); return(instances); }
public Task <string> GetCloudServicePropertiesAsync( string subscription, string resourceGroup, string name, string slot, ITestOutputHelper logger, CancellationToken token) { return(RetryUtility.ExecuteWithRetry( () => _inner.GetCloudServicePropertiesAsync( subscription, resourceGroup, name, slot, token), ex => ex is AzureManagementException, maxAttempts: RetryUtility.DefaultMaxAttempts, sleepDuration: _sleepDuration, logger: logger)); }