Skip to content

Commit

Permalink
Formatting: If we're separating parameters to separate lines, convent…
Browse files Browse the repository at this point in the history
…ion requires each have their own line.

Signed-off-by: Whit Waldo <[email protected]>
  • Loading branch information
WhitWaldo committed Jan 10, 2024
1 parent abaf78b commit 003c0ca
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions src/Dapr.Client/DaprClientGrpc.cs
Original file line number Diff line number Diff line change
Expand Up @@ -612,17 +612,19 @@ public override async Task<IReadOnlyList<BulkStateItem>> GetBulkStateAsync(strin
}

/// <inheritdoc/>
public override async Task<IReadOnlyList<BulkStateItem<TValue>>> GetBulkStateAsync<TValue>(string storeName,
IReadOnlyList<string> keys, int? parallelism, IReadOnlyDictionary<string, string> metadata = default,
public override async Task<IReadOnlyList<BulkStateItem<TValue>>> GetBulkStateAsync<TValue>(
string storeName,
IReadOnlyList<string> keys,
int? parallelism,
IReadOnlyDictionary<string, string> metadata = default,
CancellationToken cancellationToken = default)
{
var rawBulkState = await GetBulkStateRawAsync(storeName, keys, parallelism, metadata, cancellationToken);

var bulkResponse = new List<BulkStateItem<TValue>>();
foreach (var item in rawBulkState)
{
var deserializedValue =
TypeConverters.FromJsonByteString<TValue>(item.Value, this.JsonSerializerOptions);
var deserializedValue = TypeConverters.FromJsonByteString<TValue>(item.Value, this.JsonSerializerOptions);
bulkResponse.Add(new BulkStateItem<TValue>(item.Key, deserializedValue, item.Etag));
}

Expand All @@ -635,7 +637,9 @@ public override async Task<IReadOnlyList<BulkStateItem<TValue>>> GetBulkStateAsy
/// </summary>
private async Task<IReadOnlyList<(string Key, string Etag, ByteString Value)>> GetBulkStateRawAsync(
string storeName,
IReadOnlyList<string> keys, int? parallelism, IReadOnlyDictionary<string, string> metadata = default,
IReadOnlyList<string> keys,
int? parallelism,
IReadOnlyDictionary<string, string> metadata = default,
CancellationToken cancellationToken = default)
{
ArgumentVerifier.ThrowIfNullOrEmpty(storeName, nameof(storeName));
Expand All @@ -644,7 +648,8 @@ public override async Task<IReadOnlyList<BulkStateItem<TValue>>> GetBulkStateAsy

var envelope = new Autogenerated.GetBulkStateRequest()
{
StoreName = storeName, Parallelism = parallelism ?? default
StoreName = storeName,
Parallelism = parallelism ?? default
};

if (metadata != null)
Expand Down

0 comments on commit 003c0ca

Please sign in to comment.