public ServerSourceHolder(ServerEndpointInfoSource source, string transportName) { Source = source; TransportName = transportName; }
private async Task <IEnumerable <IEndpointInfo> > GetEndpointInfoAsync(ServerEndpointInfoSource source) { _outputHelper.WriteLine("Getting endpoint infos."); using CancellationTokenSource cancellationSource = new CancellationTokenSource(TimeSpan.FromSeconds(10)); return(await source.GetEndpointInfoAsync(cancellationSource.Token)); }
public async Task <IEnumerable <IEndpointInfo> > GetEndpointInfoAsync(ServerEndpointInfoSource source) { _outputHelper.WriteLine("Getting endpoint infos."); using CancellationTokenSource cancellationSource = new(GetEndpointInfoTimeout); return(await source.GetEndpointInfoAsync(cancellationSource.Token)); }