Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Forward missed CancellationTokens #459

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 16 additions & 16 deletions arangodb-net-standard/AqlFunctionApi/AqlFunctionApiClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public virtual async Task<PostAqlFunctionResponse> PostAqlFunctionAsync(
{
var content = GetContent(body, new ApiClientSerializationOptions(true, true));

using (var response = await _transport.PostAsync(_apiPath, content).ConfigureAwait(false))
using (var response = await _transport.PostAsync(_apiPath, content, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down Expand Up @@ -92,7 +92,7 @@ public virtual async Task<DeleteAqlFunctionResponse> DeleteAqlFunctionAsync(
uri += "?" + query.ToQueryString();
}

using (var response = await _transport.DeleteAsync(uri).ConfigureAwait(false))
using (var response = await _transport.DeleteAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down Expand Up @@ -120,7 +120,7 @@ public virtual async Task<GetAqlFunctionsResponse> GetAqlFunctionsAsync(
uri += "?" + query.ToQueryString();
}

using (var response = await _transport.GetAsync(uri).ConfigureAwait(false))
using (var response = await _transport.GetAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down Expand Up @@ -150,7 +150,7 @@ public virtual async Task<PostExplainAqlQueryResponse> PostExplainAqlQueryAsync(
string uri = "_api/explain";

var content = GetContent(body, new ApiClientSerializationOptions(true, true));
using (var response = await _transport.PostAsync(uri, content).ConfigureAwait(false))
using (var response = await _transport.PostAsync(uri, content, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down Expand Up @@ -180,7 +180,7 @@ public virtual async Task<PostParseAqlQueryResponse> PostParseAqlQueryAsync(
string uri = "_api/query";

var content = GetContent(body, new ApiClientSerializationOptions(true, true));
using (var response = await _transport.PostAsync(uri, content).ConfigureAwait(false))
using (var response = await _transport.PostAsync(uri, content, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down Expand Up @@ -227,7 +227,7 @@ public virtual async Task<ResponseBase> DeleteKillRunningAqlQueryAsync(
uri += "?" + query.ToQueryString();
}

using (var response = await _transport.DeleteAsync(uri).ConfigureAwait(false))
using (var response = await _transport.DeleteAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down Expand Up @@ -262,7 +262,7 @@ public virtual async Task<ResponseBase> DeleteClearSlowAqlQueriesAsync(
uri += "?" + query.ToQueryString();
}

using (var response = await _transport.DeleteAsync(uri).ConfigureAwait(false))
using (var response = await _transport.DeleteAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down Expand Up @@ -305,7 +305,7 @@ public virtual async Task<List<SlowAqlQuery>> GetSlowAqlQueriesAsync(
uri += "?" + query.ToQueryString();
}

using (var response = await _transport.GetAsync(uri).ConfigureAwait(false))
using (var response = await _transport.GetAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand All @@ -329,7 +329,7 @@ public virtual async Task<ResponseBase> DeleteClearAqlQueryCacheAsync(
{
string uri = "_api/query-cache";

using (var response = await _transport.DeleteAsync(uri).ConfigureAwait(false))
using (var response = await _transport.DeleteAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand All @@ -354,7 +354,7 @@ public virtual async Task<List<CachedAqlQueryResult>> GetCachedAqlQueryResultsAs
CancellationToken token = default)
{
string uri = "_api/query-cache/entries";
using (var response = await _transport.GetAsync(uri).ConfigureAwait(false))
using (var response = await _transport.GetAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand All @@ -377,7 +377,7 @@ public virtual async Task<QueryCacheGlobalProperties> GetQueryCacheGlobalPropert
CancellationToken token = default)
{
string uri = "_api/query-cache/properties";
using (var response = await _transport.GetAsync(uri).ConfigureAwait(false))
using (var response = await _transport.GetAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down Expand Up @@ -412,7 +412,7 @@ public virtual async Task<QueryCacheGlobalProperties> PutAdjustQueryCacheGlobalP
string uri = "_api/query-cache/properties";

var content = GetContent(body, new ApiClientSerializationOptions(true, true));
using (var response = await _transport.PutAsync(uri, content).ConfigureAwait(false))
using (var response = await _transport.PutAsync(uri, content, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand All @@ -433,7 +433,7 @@ public virtual async Task<QueryTrackingConfiguration> GetQueryTrackingConfigurat
CancellationToken token = default)
{
string uri = "_api/query/properties";
using (var response = await _transport.GetAsync(uri).ConfigureAwait(false))
using (var response = await _transport.GetAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down Expand Up @@ -467,7 +467,7 @@ public virtual async Task<QueryTrackingConfiguration> PutChangeQueryTrackingConf
string uri = "_api/query/properties";

var content = GetContent(body, new ApiClientSerializationOptions(true, true));
using (var response = await _transport.PutAsync(uri, content).ConfigureAwait(false))
using (var response = await _transport.PutAsync(uri, content, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down Expand Up @@ -498,7 +498,7 @@ public virtual async Task<List<RunningAqlQuery>> GetCurrentlyRunningAqlQueriesAs
uri += "?" + query.ToQueryString();
}

using (var response = await _transport.GetAsync(uri).ConfigureAwait(false))
using (var response = await _transport.GetAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand All @@ -523,7 +523,7 @@ public virtual async Task<List<GetQueryRule>> GetQueryRulesAsync(CancellationTok
{
string uri = "_api/query/rules";

using (var response = await _transport.GetAsync(uri).ConfigureAwait(false))
using (var response = await _transport.GetAsync(uri, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down
2 changes: 1 addition & 1 deletion arangodb-net-standard/ViewApi/ViewsApiClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public virtual async Task<ViewResponse> PostCreateViewAsync(ViewDetails body, bo
useCamelCasePropertyNames: true,
ignoreNullValues: ignoreNullValuesOnSerialization,
applySerializationOptionsToDictionaryValues: true));
using (var response = await _transport.PostAsync(uri, content).ConfigureAwait(false))
using (var response = await _transport.PostAsync(uri, content, token: token).ConfigureAwait(false))
{
if (response.IsSuccessStatusCode)
{
Expand Down