Skip to content

Commit

Permalink
Update dependencies
Browse files Browse the repository at this point in the history
Signed-off-by: Victor Chang <[email protected]>
  • Loading branch information
mocsharp committed Aug 11, 2023
1 parent 7383e88 commit 029ea4c
Show file tree
Hide file tree
Showing 9 changed files with 63 additions and 61 deletions.
30 changes: 15 additions & 15 deletions doc/dependency_decisions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
- :who: mocsharp
:why: MIT (https://github.com/ardalis/GuardClauses.Analyzers/raw/master/LICENSE)
:versions:
- 4.0.1
- 4.1.1
:when: 2022-08-16 21:39:30.077666354 Z
- - :approve
- Castle.Core
Expand All @@ -18,7 +18,7 @@
- :who: mocsharp
:why: MIT (https://github.com/coverlet-coverage/coverlet/raw/master/LICENSE)
:versions:
- 3.2.0
- 6.0.0
:when: 2022-08-16 21:40:21.855388365 Z
- - :approve
- JetBrains.Annotations
Expand All @@ -32,7 +32,7 @@
- :who: woodheadio
:why: MIT (https://github.com/dotnet/aspnetcore/raw/main/LICENSE.txt)
:versions:
- 6.0.14
- 6.0.21
:when: 2023-08-16 16:49:26.950721112 Z
- - :approve
- Microsoft.CodeCoverage
Expand Down Expand Up @@ -60,14 +60,14 @@
- :who: woodheadio
:why: MIT (https://github.com/dotnet/aspnetcore/raw/main/LICENSE.txt)
:versions:
- 6.0.14
- 6.0.21
:when: 2023-08-16 16:49:26.950721112 Z
- - :approve
- Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions
- :who: woodheadio
:why: MIT (https://github.com/dotnet/aspnetcore/raw/main/LICENSE.txt)
:versions:
- 6.0.14
- 6.0.21
:when: 2023-08-16 16:49:26.950721112 Z
- - :approve
- Microsoft.Extensions.FileProviders.Abstractions
Expand Down Expand Up @@ -109,7 +109,7 @@
- :who: woodheadio
:why: MIT (https://github.com/microsoft/vstest/raw/v17.4.1/LICENSE)
:versions:
- 17.5.0
- 17.7.0
:when: 2023-08-16 16:49:26.950721112 Z
- - :approve
- Microsoft.NETCore.Platforms
Expand Down Expand Up @@ -151,7 +151,7 @@
- :who: woodheadio
:why: BSD 3-Clause License ( https://raw.githubusercontent.com/moq/moq4/main/License.txt)
:versions:
- 4.18.4
- 4.20.69
:when: 2023-08-16 16:49:26.950721112 Z
- - :approve
- NETStandard.Library
Expand Down Expand Up @@ -179,14 +179,14 @@
- :who: mocsharp
:why: MIT ( https://licenses.nuget.org/MIT)
:versions:
- 7.2.3
- 7.2.4
:when: 2022-11-09 18:57:32.294717110 Z
- - :approve
- RabbitMQ.Client
- :who: mocsharp
:why: Apache-2.0 (https://github.com/rabbitmq/rabbitmq-dotnet-client/raw/main/LICENSE-APACHE2)
:versions:
- 6.4.0
- 6.5.0
:when: 2022-08-16 21:39:52.474284611 Z
- - :approve
- runtime.debian.8-x64.runtime.native.System.Security.Cryptography.OpenSsl
Expand Down Expand Up @@ -739,7 +739,7 @@
- :who: mocsharp
:why: Apache-2.0 ( https://raw.githubusercontent.com/xunit/xunit/master/license.txt)
:versions:
- 2.4.2
- 2.5.0
:when: 2022-08-16 21:40:29.166018542 Z
- - :approve
- xunit.abstractions
Expand All @@ -760,33 +760,33 @@
- :who: mocsharp
:why: Apache-2.0 ( https://raw.githubusercontent.com/xunit/xunit/master/license.txt)
:versions:
- 2.4.2
- 2.5.0
:when: 2022-08-16 21:40:30.526718458 Z
- - :approve
- xunit.core
- :who: mocsharp
:why: Apache-2.0 ( https://raw.githubusercontent.com/xunit/xunit/master/license.txt)
:versions:
- 2.4.2
- 2.5.0
:when: 2022-08-16 21:40:30.973515441 Z
- - :approve
- xunit.extensibility.core
- :who: mocsharp
:why: Apache-2.0 ( https://raw.githubusercontent.com/xunit/xunit/master/license.txt)
:versions:
- 2.4.2
- 2.5.0
:when: 2022-08-16 21:40:31.401607230 Z
- - :approve
- xunit.extensibility.execution
- :who: mocsharp
:why: Apache-2.0 ( https://raw.githubusercontent.com/xunit/xunit/master/license.txt)
:versions:
- 2.4.2
- 2.5.0
:when: 2022-08-16 21:40:31.845685693 Z
- - :approve
- xunit.runner.visualstudio
- :who: mocsharp
:why: MIT ( https://licenses.nuget.org/MIT)
:versions:
- 2.4.5
:when: 2022-08-16 21:40:32.294717110 Z
:when: 2022-08-16 21:40:32.294717110 Z
6 changes: 3 additions & 3 deletions src/Messaging/Events/ExportCompleteEvent.cs
Original file line number Diff line number Diff line change
Expand Up @@ -76,9 +76,9 @@ public ExportCompleteEvent()

public ExportCompleteEvent(ExportRequestEvent exportRequest, ExportStatus exportStatus, Dictionary<string, FileExportStatus> fileStatuses)
{
Guard.Against.Null(exportRequest);
Guard.Against.Null(exportStatus);
Guard.Against.Null(fileStatuses);
Guard.Against.Null(exportRequest, nameof(exportRequest));
Guard.Against.Null(exportStatus, nameof(exportStatus));
Guard.Against.Null(fileStatuses, nameof(fileStatuses));

WorkflowInstanceId = exportRequest.WorkflowInstanceId;
ExportTaskId = exportRequest.ExportTaskId;
Expand Down
4 changes: 2 additions & 2 deletions src/Messaging/Monai.Deploy.Messaging.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Ardalis.GuardClauses" Version="4.0.1" />
<PackageReference Include="Microsoft.Extensions.Diagnostics.HealthChecks" Version="6.0.14" />
<PackageReference Include="Ardalis.GuardClauses" Version="4.1.1" />
<PackageReference Include="Microsoft.Extensions.Diagnostics.HealthChecks" Version="6.0.21" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
<PackageReference Include="System.IO.Abstractions" Version="17.2.3" />
</ItemGroup>
Expand Down
10 changes: 5 additions & 5 deletions src/Messaging/Tests/Monai.Deploy.Messaging.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
<PackageReference Include="Moq" Version="4.18.4" />
<PackageReference Include="xunit" Version="2.4.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.5">
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.7.0" />
<PackageReference Include="Moq" Version="4.20.69" />
<PackageReference Include="xunit" Version="2.5.0" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.0">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="coverlet.collector" Version="3.2.0">
<PackageReference Include="coverlet.collector" Version="6.0.0">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
Expand Down
10 changes: 5 additions & 5 deletions src/Plugins/RabbitMQ/Factory/RabbitMqConnectionFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@ public RabbitMQConnectionFactory(ILogger<RabbitMQConnectionFactory> logger)

public IModel CreateChannel(ChannelType type, string hostName, string username, string password, string virtualHost, string useSSL, string portNumber)
{
Guard.Against.NullOrWhiteSpace(hostName);
Guard.Against.NullOrWhiteSpace(username);
Guard.Against.NullOrWhiteSpace(password);
Guard.Against.NullOrWhiteSpace(virtualHost);
Guard.Against.NullOrWhiteSpace(hostName, nameof(hostName));
Guard.Against.NullOrWhiteSpace(username, nameof(username));
Guard.Against.NullOrWhiteSpace(password, nameof(password));
Guard.Against.NullOrWhiteSpace(virtualHost, nameof(virtualHost));

var key = $"{type}{hostName}{username}{HashPassword(password)}{virtualHost}";

Expand Down Expand Up @@ -154,7 +154,7 @@ private IConnection CreateConnectionOnly(string hostName, string username, strin

private static object HashPassword(string password)
{
Guard.Against.NullOrWhiteSpace(password);
Guard.Against.NullOrWhiteSpace(password, nameof(password));
var sha256 = SHA256.Create();
var hash = sha256.ComputeHash(Encoding.UTF8.GetBytes(password));
return string.Join("", hash.Select(x => x.ToString("x2", CultureInfo.InvariantCulture)));
Expand Down
4 changes: 2 additions & 2 deletions src/Plugins/RabbitMQ/Monai.Deploy.Messaging.RabbitMQ.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Polly" Version="7.2.3" />
<PackageReference Include="RabbitMQ.Client" Version="6.4.0" />
<PackageReference Include="Polly" Version="7.2.4" />
<PackageReference Include="RabbitMQ.Client" Version="6.5.0" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public RabbitMQMessagePublisherService(IOptions<MessageBrokerServiceConfiguratio
ILogger<RabbitMQMessagePublisherService> logger,
IRabbitMQConnectionFactory rabbitMqConnectionFactory)
{
Guard.Against.Null(options);
Guard.Against.Null(options, nameof(options));

_logger = logger ?? throw new ArgumentNullException(nameof(logger));
_rabbitMqConnectionFactory = rabbitMqConnectionFactory ?? throw new ArgumentNullException(nameof(rabbitMqConnectionFactory));
Expand Down Expand Up @@ -83,7 +83,7 @@ public RabbitMQMessagePublisherService(IOptions<MessageBrokerServiceConfiguratio

internal static void ValidateConfiguration(Dictionary<string, string> configuration)
{
Guard.Against.Null(configuration);
Guard.Against.Null(configuration, nameof(configuration));

foreach (var key in ConfigurationKeys.PublisherRequiredKeys)
{
Expand All @@ -96,8 +96,8 @@ internal static void ValidateConfiguration(Dictionary<string, string> configurat

public Task Publish(string topic, Message message)
{
Guard.Against.NullOrWhiteSpace(topic);
Guard.Against.Null(message);
Guard.Against.NullOrWhiteSpace(topic, nameof(topic));
Guard.Against.Null(message, nameof(message));

using var loggingScope = _logger.BeginScope(new LoggingDataDictionary<string, object>
{
Expand Down
40 changes: 21 additions & 19 deletions src/Plugins/RabbitMQ/Subscriber/RabbitMqMessageSubscriberService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public RabbitMQMessageSubscriberService(IOptions<MessageBrokerServiceConfigurati
ILogger<RabbitMQMessageSubscriberService> logger,
IRabbitMQConnectionFactory rabbitMqConnectionFactory)
{
Guard.Against.Null(options);
Guard.Against.Null(options, nameof(options));

_logger = logger ?? throw new ArgumentNullException(nameof(logger));
_rabbitMqConnectionFactory = rabbitMqConnectionFactory ?? throw new ArgumentNullException(nameof(rabbitMqConnectionFactory));
Expand Down Expand Up @@ -137,7 +137,7 @@ private void Channel_ModelShutdown(object? sender, ShutdownEventArgs e)

internal static void ValidateConfiguration(Dictionary<string, string> configuration)
{
Guard.Against.Null(configuration);
Guard.Against.Null(configuration, nameof(configuration));

foreach (var key in ConfigurationKeys.SubscriberRequiredKeys)
{
Expand Down Expand Up @@ -177,8 +177,8 @@ public void SubscribeAsync(string topic, string queue, Func<MessageReceivedEvent

public void SubscribeAsync(string[] topics, string queue, Func<MessageReceivedEventArgs, Task> messageReceivedCallback, ushort prefetchCount = 0)
{
Guard.Against.Null(topics);
Guard.Against.Null(messageReceivedCallback);
Guard.Against.Null(topics, nameof(topics));
Guard.Against.Null(messageReceivedCallback, nameof(messageReceivedCallback));

var queueDeclareResult = DeclareQueues(topics, queue, prefetchCount);
var consumer = CreateConsumer(messageReceivedCallback, queueDeclareResult);
Expand Down Expand Up @@ -273,7 +273,7 @@ private QueueDeclareOk DeclareQueues(string[] topics, string queue, ushort prefe

public void Acknowledge(MessageBase message)
{
Guard.Against.Null(message);
Guard.Against.Null(message, nameof(message));

CreateChannel();

Expand All @@ -290,6 +290,8 @@ public void Acknowledge(MessageBase message)

public async Task RequeueWithDelay(MessageBase message)
{
Guard.Against.Null(message, nameof(message));

try
{
await Task.Delay(_requeueDelay * 1000).ConfigureAwait(false);
Expand All @@ -305,7 +307,7 @@ public async Task RequeueWithDelay(MessageBase message)

public void Reject(MessageBase message, bool requeue = true)
{
Guard.Against.Null(message);
Guard.Against.Null(message, nameof(message));

CreateChannel();

Expand Down Expand Up @@ -344,8 +346,8 @@ public void Dispose()

private void BindToRoutingKeys(string[] topics, string queue, string deadLetterQueue = "")
{
Guard.Against.Null(topics);
Guard.Against.NullOrWhiteSpace(queue);
Guard.Against.Null(topics, nameof(topics));
Guard.Against.NullOrWhiteSpace(queue, nameof(queue));

foreach (var topic in topics)
{
Expand All @@ -363,17 +365,17 @@ private void BindToRoutingKeys(string[] topics, string queue, string deadLetterQ

private static MessageReceivedEventArgs CreateMessage(string topic, BasicDeliverEventArgs eventArgs)
{
Guard.Against.NullOrWhiteSpace(topic);
Guard.Against.Null(eventArgs);

Guard.Against.Null(eventArgs.Body);
Guard.Against.Null(eventArgs.BasicProperties);
Guard.Against.Null(eventArgs.BasicProperties.MessageId);
Guard.Against.Null(eventArgs.BasicProperties.AppId);
Guard.Against.Null(eventArgs.BasicProperties.ContentType);
Guard.Against.Null(eventArgs.BasicProperties.CorrelationId);
Guard.Against.Null(eventArgs.BasicProperties.Timestamp);
Guard.Against.Null(eventArgs.DeliveryTag);
Guard.Against.NullOrWhiteSpace(topic, nameof(topic));
Guard.Against.Null(eventArgs, nameof(eventArgs));

Guard.Against.Null(eventArgs.Body, nameof(eventArgs.Body));
Guard.Against.Null(eventArgs.BasicProperties, nameof(eventArgs.BasicProperties));
Guard.Against.Null(eventArgs.BasicProperties.MessageId, nameof(eventArgs.BasicProperties.MessageId));
Guard.Against.Null(eventArgs.BasicProperties.AppId, nameof(eventArgs.BasicProperties.AppId));
Guard.Against.Null(eventArgs.BasicProperties.ContentType, nameof(eventArgs.BasicProperties.ContentType));
Guard.Against.Null(eventArgs.BasicProperties.CorrelationId, nameof(eventArgs.BasicProperties.CorrelationId));
Guard.Against.Null(eventArgs.BasicProperties.Timestamp, nameof(eventArgs.BasicProperties.Timestamp));
Guard.Against.Null(eventArgs.DeliveryTag, nameof(eventArgs.DeliveryTag));

return new MessageReceivedEventArgs(
new Message(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,16 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.TestHost" Version="6.0.14" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
<PackageReference Include="Moq" Version="4.18.4" />
<PackageReference Include="Microsoft.AspNetCore.TestHost" Version="6.0.21" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.7.0" />
<PackageReference Include="Moq" Version="4.20.69" />
<PackageReference Include="System.IO.Abstractions.TestingHelpers" Version="17.2.3" />
<PackageReference Include="xunit" Version="2.4.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.5">
<PackageReference Include="xunit" Version="2.5.0" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.0">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="coverlet.collector" Version="3.2.0">
<PackageReference Include="coverlet.collector" Version="6.0.0">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
Expand Down

0 comments on commit 029ea4c

Please sign in to comment.