public async Task RunAsync([ActivityTrigger] IDurableActivityContext input) { var(data, scope) = input.GetInput <(ItemsExtensionData, string)>(); await _azuredo.PutAsync(ExtensionManagement.ExtensionData <ExtensionDataReports>( _config.ExtensionPublisher, _config.ExtensionName, scope), data) .ConfigureAwait(false); }
public async Task ReconcileAsync(string projectId, string itemId) { var policies = _policiesResolver.Resolve(projectId); var policy = Find(policies, itemId).SingleOrDefault(); if (policy != null) { await _client.PutAsync(Requests.Policies.Policy(projectId, policy.Id), UpdatePolicy(policy)) .ConfigureAwait(false); } else { await _client.PostAsync(Requests.Policies.Policy(projectId), InitializeMinimumNumberOfReviewersPolicy(itemId)) .ConfigureAwait(false); } }