Skip to content

Commit

Permalink
Fix analyzer concerns
Browse files Browse the repository at this point in the history
  • Loading branch information
wsugarman committed Aug 9, 2023
1 parent a4dc0ee commit 4306b20
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 20 deletions.
1 change: 1 addition & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
<!-- Build -->
<PropertyGroup>
<Deterministic>true</Deterministic>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<LangVersion>latest</LangVersion>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
<Nullable>enable</Nullable>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@
// Licensed under the MIT License.

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Google.Protobuf.Collections;
using Keda.Scaler.DurableTask.AzureStorage.Extensions;
using Microsoft.Extensions.Configuration;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
using Keda.Scaler.DurableTask.AzureStorage.Common;
using Keda.Scaler.DurableTask.AzureStorage.Extensions;
using Keda.Scaler.DurableTask.AzureStorage.TaskHub;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,7 @@ public AzureStorageTaskHubBrowser(
}

/// <summary>
/// Asynchronously attempts to retrieve an <see cref="ITaskHubQueueMonitor"/> for the Task Hub
/// with the given <paramref name="name"/>.
/// Asynchronously attempts to retrieve an <see cref="ITaskHubQueueMonitor"/> for the Task Hub with the given name.
/// </summary>
/// <param name="accountInfo">The account information for the Azure Storage account.</param>
/// <param name="taskHub">The name of the desired Task Hub.</param>
Expand All @@ -52,7 +51,7 @@ public AzureStorageTaskHubBrowser(
/// </param>
/// <returns>
/// A value task that represents the asynchronous operation. The value of the type parameter
/// of the value task contains the monitor for the given Task Hub..
/// of the value task contains the monitor for the given Task Hub.
/// </returns>
/// <exception cref="ArgumentException"><paramref name="accountInfo"/> is missing information.</exception>
/// <exception cref="ArgumentNullException">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,15 @@ namespace Keda.Scaler.DurableTask.AzureStorage.TaskHub;
public interface ITaskHubQueueMonitor
{
/// <summary>
/// Initializes a new instance of the <see cref="TaskHubQueueMonitor"/> class.
/// Asynchronously fetches the number of messages in queue across the Task Hub to gauge its usage.
/// </summary>
/// <param name="taskHubInfo">Metadata concerning the Task Hub.</param>
/// <param name="queueServiceClient">A client for accessing the Azure Queue service.</param>
/// <param name="logger">A diagnostic logger.</param>
/// <exception cref="ArgumentNullException">
/// <paramref name="taskHubInfo"/>, <paramref name="queueServiceClient"/>,
/// or <paramref name="logger"/> is <see langword="null"/>.
/// </exception>
/// <exception cref="ArgumentException">
/// <see cref="AzureStorageTaskHubInfo.PartitionCount"/> is less than <c>1</c> for <paramref name="taskHubInfo"/>.
/// </exception>
/// <param name="cancellationToken">
/// The token to monitor for cancellation requests. The default value is <see cref="CancellationToken.None"/>.
/// </param>
/// <returns>
/// A value task that represents the asynchronous operation. The value of the type parameter
/// of the value task contains the usage for the Task Hub.
/// </returns>
/// <exception cref="OperationCanceledException">The <paramref name="cancellationToken"/> is canceled.</exception>
ValueTask<TaskHubQueueUsage> GetUsageAsync(CancellationToken cancellationToken = default);
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public sealed class TaskHubQueueUsage
/// Gets a value indicating whether there is currently any activity for the Task Hub.
/// </summary>
/// <value>
/// <see langword="true"/> if there is at least one message that is pending; otherwise, <langword cref="false"/>.
/// <see langword="true"/> if there is at least one message that is pending; otherwise, <see langword="false"/>.
/// </value>
public bool HasActivity => WorkItemQueueMessages > 0 || ControlQueueMessages.Any(x => x > 0);

Expand Down

0 comments on commit 4306b20

Please sign in to comment.