Skip to content

Commit 069f7eb

Browse files
authored
update messaging lib to fix RMQ connection issues (#187)
* gh-184 update messaging lib to fix RMQ connection issues Signed-off-by: Victor Chang <[email protected]>
1 parent 583f8d3 commit 069f7eb

8 files changed

+15
-17
lines changed

doc/dependency_decisions.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -808,14 +808,14 @@
808808
- :who: mocsharp
809809
:why: Apache-2.0 (https://github.com/Project-MONAI/monai-deploy-messaging/raw/main/LICENSE)
810810
:versions:
811-
- 0.1.5
811+
- 0.1.6
812812
:when: 2022-08-16 23:06:21.051573547 Z
813813
- - :approve
814814
- Monai.Deploy.Messaging.RabbitMQ
815815
- :who: mocsharp
816816
:why: Apache-2.0 (https://github.com/Project-MONAI/monai-deploy-messaging/raw/main/LICENSE)
817817
:versions:
818-
- 0.1.5
818+
- 0.1.6
819819
:when: 2022-08-16 23:06:21.511789690 Z
820820
- - :approve
821821
- Monai.Deploy.Storage
@@ -2370,4 +2370,3 @@
23702370
:versions:
23712371
- 4.0.1
23722372
:when: 2022-08-16 23:10:21.184627612 Z
2373-

docs/compliance/third-party-licenses.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7847,14 +7847,14 @@ Apache License
78477847

78487848

78497849
<details>
7850-
<summary>Monai.Deploy.Messaging 0.1.5</summary>
7850+
<summary>Monai.Deploy.Messaging 0.1.6</summary>
78517851

78527852
## Monai.Deploy.Messaging
78537853

7854-
- Version: 0.1.5
7854+
- Version: 0.1.6
78557855
- Authors: MONAI Consortium
78567856
- Project URL: https://github.com/Project-MONAI/monai-deploy-messaging
7857-
- Source: [NuGet](https://www.nuget.org/packages/Monai.Deploy.Messaging/0.1.5)
7857+
- Source: [NuGet](https://www.nuget.org/packages/Monai.Deploy.Messaging/0.1.6)
78587858
- License: [Apache-2.0](https://github.com/Project-MONAI/monai-deploy-messaging/raw/main/LICENSE)
78597859

78607860

@@ -8075,14 +8075,14 @@ By downloading this software, you agree to the license terms & all licenses list
80758075

80768076

80778077
<details>
8078-
<summary>Monai.Deploy.Messaging.RabbitMQ 0.1.5</summary>
8078+
<summary>Monai.Deploy.Messaging.RabbitMQ 0.1.6</summary>
80798079

80808080
## Monai.Deploy.Messaging.RabbitMQ
80818081

8082-
- Version: 0.1.5
8082+
- Version: 0.1.6
80838083
- Authors: MONAI Consortium
80848084
- Project URL: https://github.com/Project-MONAI/monai-deploy-messaging
8085-
- Source: [NuGet](https://www.nuget.org/packages/Monai.Deploy.Messaging.RabbitMQ/0.1.5)
8085+
- Source: [NuGet](https://www.nuget.org/packages/Monai.Deploy.Messaging.RabbitMQ/0.1.6)
80868086
- License: [Apache-2.0](https://github.com/Project-MONAI/monai-deploy-messaging/raw/main/LICENSE)
80878087

80888088

src/Api/Monai.Deploy.InformaticsGateway.Api.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
</PackageReference>
3131
<PackageReference Include="Macross.Json.Extensions" Version="3.0.0" />
3232
<PackageReference Include="Microsoft.EntityFrameworkCore.Abstractions" Version="6.0.9" />
33-
<PackageReference Include="Monai.Deploy.Messaging" Version="0.1.5" />
33+
<PackageReference Include="Monai.Deploy.Messaging" Version="0.1.6" />
3434
<PackageReference Include="Monai.Deploy.Storage" Version="0.2.7" />
3535
</ItemGroup>
3636

src/Configuration/Monai.Deploy.InformaticsGateway.Configuration.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
</PackageReference>
3131
<PackageReference Include="Microsoft.Extensions.Logging.Abstractions" Version="6.0.2" />
3232
<PackageReference Include="Microsoft.Extensions.Options" Version="6.0.0" />
33-
<PackageReference Include="Monai.Deploy.Messaging" Version="0.1.5" />
33+
<PackageReference Include="Monai.Deploy.Messaging" Version="0.1.6" />
3434
<PackageReference Include="Monai.Deploy.Storage" Version="0.2.7" />
3535
<PackageReference Include="System.IO.Abstractions" Version="17.2.3" />
3636
</ItemGroup>

src/InformaticsGateway/Monai.Deploy.InformaticsGateway.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
<PackageReference Include="Microsoft.Extensions.Logging" Version="6.0.0" />
4848
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="6.0.0" />
4949
<PackageReference Include="Microsoft.Extensions.Options" Version="6.0.0" />
50-
<PackageReference Include="Monai.Deploy.Messaging.RabbitMQ" Version="0.1.5" />
50+
<PackageReference Include="Monai.Deploy.Messaging.RabbitMQ" Version="0.1.6" />
5151
<PackageReference Include="Monai.Deploy.Storage" Version="0.2.7" />
5252
<PackageReference Include="Monai.Deploy.Storage.MinIO" Version="0.2.7" />
5353
<PackageReference Include="Polly" Version="7.2.3" />

src/InformaticsGateway/Services/Connectors/PayloadNotificationActionHandler.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ internal class PayloadNotificationActionHandler : IPayloadNotificationActionHand
4646
private readonly IOptions<InformaticsGatewayConfiguration> _options;
4747

4848
private readonly IServiceScope _scope;
49-
private readonly IMessageBrokerPublisherService _messageBrokerPublisherService;
5049
private bool _disposedValue;
5150

5251
public PayloadNotificationActionHandler(IServiceScopeFactory serviceScopeFactory,
@@ -58,7 +57,6 @@ public PayloadNotificationActionHandler(IServiceScopeFactory serviceScopeFactory
5857
_options = options ?? throw new ArgumentNullException(nameof(options));
5958

6059
_scope = _serviceScopeFactory.CreateScope();
61-
_messageBrokerPublisherService = _scope.ServiceProvider.GetService<IMessageBrokerPublisherService>() ?? throw new ServiceNotFoundException(nameof(IMessageBrokerPublisherService));
6260
}
6361

6462
public async Task NotifyAsync(Payload payload, ActionBlock<Payload> notificationQueue, CancellationToken cancellationToken = default)
@@ -134,7 +132,8 @@ private async Task NotifyPayloadReady(Payload payload)
134132

135133
_logger.PublishingWorkflowRequest(message.MessageId);
136134

137-
await _messageBrokerPublisherService.Publish(
135+
var messageBrokerPublisherService = _scope.ServiceProvider.GetService<IMessageBrokerPublisherService>() ?? throw new ServiceNotFoundException(nameof(IMessageBrokerPublisherService));
136+
await messageBrokerPublisherService.Publish(
138137
_options.Value.Messaging.Topics.WorkflowRequest,
139138
message.ToMessage()).ConfigureAwait(false);
140139

src/InformaticsGateway/appsettings.Development.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
},
2929
"storage": {
3030
"settings": {
31-
"endpoint": "localhost",
31+
"endpoint": "localhost:9000",
3232
"accessKey": "minioadmin",
3333
"accessToken": "minioadmin",
3434
"securedConnection": false

tests/Integration.Test/Monai.Deploy.InformaticsGateway.Integration.Test.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="6.0.0" />
3434
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.3.2" />
3535
<PackageReference Include="Minio" Version="4.0.5" />
36-
<PackageReference Include="Monai.Deploy.Messaging.RabbitMQ" Version="0.1.5" />
36+
<PackageReference Include="Monai.Deploy.Messaging.RabbitMQ" Version="0.1.6" />
3737
<PackageReference Include="Monai.Deploy.Storage.MinIO" Version="0.2.7" />
3838
<PackageReference Include="Moq" Version="4.18.2" />
3939
<PackageReference Include="Polly" Version="7.2.3" />

0 commit comments

Comments
 (0)