public async Task<Request> GetRequestAsync()
{
var response = await _httpClient.GetAsync(_requestUri, _cancellationToken);
return await response.Content.ReadAsAsync<Request>();
}
I've got this code that passes an instance of CancellationToken into the _httpClient.GetAsync call. I would expect I also could pass a CancellationToken into the response.Content.ReadAsync call, but there doesn't seem to be any overload accepting a CancellationToken.
I would expect the response.Content.ReadAsAsync call could also take some time. Shouldn't it then be cancellable?
Is this by design, or am I missing something here?