From a07dfbb2e045d96510068256322cdac177e0b212 Mon Sep 17 00:00:00 2001 From: Jack Schofield Date: Wed, 31 Aug 2022 13:14:21 +0100 Subject: [PATCH 1/3] update export routing key Signed-off-by: Jack Schofield --- .../WorkflowExecuter/Services/WorkflowExecuterService.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/WorkflowManager/WorkflowExecuter/Services/WorkflowExecuterService.cs b/src/WorkflowManager/WorkflowExecuter/Services/WorkflowExecuterService.cs index 2608be9ba..d72128c6d 100644 --- a/src/WorkflowManager/WorkflowExecuter/Services/WorkflowExecuterService.cs +++ b/src/WorkflowManager/WorkflowExecuter/Services/WorkflowExecuterService.cs @@ -74,7 +74,7 @@ public WorkflowExecuterService( _storageConfiguration = storageConfiguration.Value; TaskDispatchRoutingKey = configuration.Value.Messaging.Topics.TaskDispatchRequest; - ExportRequestRoutingKey = $"{configuration.Value.Messaging.Topics.ExportRequestPrefix}.{configuration.Value.Messaging.DicomAgents.DicomWebAgentName}"; + ExportRequestRoutingKey = $"{configuration.Value.Messaging.Topics.ExportRequestPrefix}.{configuration.Value.Messaging.DicomAgents.ScuAgentName}"; _logger = logger ?? throw new ArgumentNullException(nameof(logger)); _workflowRepository = workflowRepository ?? throw new ArgumentNullException(nameof(workflowRepository)); From 106f8cea8586a67a96adcdcc7e6433c93484b40b Mon Sep 17 00:00:00 2001 From: Jack Schofield Date: Wed, 31 Aug 2022 14:02:02 +0100 Subject: [PATCH 2/3] fix tests Signed-off-by: Jack Schofield --- .../Services/WorkflowExecuterServiceTests.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/UnitTests/WorkflowExecuter.Tests/Services/WorkflowExecuterServiceTests.cs b/tests/UnitTests/WorkflowExecuter.Tests/Services/WorkflowExecuterServiceTests.cs index aafc594ea..19ba51f21 100644 --- a/tests/UnitTests/WorkflowExecuter.Tests/Services/WorkflowExecuterServiceTests.cs +++ b/tests/UnitTests/WorkflowExecuter.Tests/Services/WorkflowExecuterServiceTests.cs @@ -382,7 +382,7 @@ public async Task ProcessPayload_WithExportTask_DispatchesExport() var result = await WorkflowExecuterService.ProcessPayload(workflowRequest, new Payload() { Id = Guid.NewGuid().ToString() }); - _messageBrokerPublisherService.Verify(w => w.Publish($"{_configuration.Value.Messaging.Topics.ExportRequestPrefix}.{_configuration.Value.Messaging.DicomAgents.DicomWebAgentName}", It.IsAny()), Times.Exactly(1)); + _messageBrokerPublisherService.Verify(w => w.Publish($"{_configuration.Value.Messaging.Topics.ExportRequestPrefix}.{_configuration.Value.Messaging.DicomAgents.ScuAgentName}", It.IsAny()), Times.Exactly(1)); Assert.True(result); } @@ -1041,7 +1041,7 @@ public async Task ProcessTaskUpdate_ValidTaskUpdateEventWithExportTaskDestinatio var response = await WorkflowExecuterService.ProcessTaskUpdate(updateEvent); - _messageBrokerPublisherService.Verify(w => w.Publish($"{_configuration.Value.Messaging.Topics.ExportRequestPrefix}.{_configuration.Value.Messaging.DicomAgents.DicomWebAgentName}", It.IsAny()), Times.Exactly(1)); + _messageBrokerPublisherService.Verify(w => w.Publish($"{_configuration.Value.Messaging.Topics.ExportRequestPrefix}.{_configuration.Value.Messaging.DicomAgents.ScuAgentName}", It.IsAny()), Times.Exactly(1)); response.Should().BeTrue(); } From 511f50c691b2d19d80c1f28217d36f7cd75cd77b Mon Sep 17 00:00:00 2001 From: Jack Schofield Date: Wed, 31 Aug 2022 14:43:05 +0100 Subject: [PATCH 3/3] fix int tests Signed-off-by: Jack Schofield --- .../IntegrationTests/WorkflowExecutor.IntegrationTests/Hooks.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/IntegrationTests/WorkflowExecutor.IntegrationTests/Hooks.cs b/tests/IntegrationTests/WorkflowExecutor.IntegrationTests/Hooks.cs index 3602e97ee..f8a0d2c96 100644 --- a/tests/IntegrationTests/WorkflowExecutor.IntegrationTests/Hooks.cs +++ b/tests/IntegrationTests/WorkflowExecutor.IntegrationTests/Hooks.cs @@ -73,7 +73,7 @@ public static void Init() TestExecutionConfig.RabbitConfig.TaskCallbackQueue = "md.tasks.callback"; TestExecutionConfig.RabbitConfig.TaskUpdateQueue = "md.tasks.update"; TestExecutionConfig.RabbitConfig.ExportCompleteQueue = config.GetValue("WorkflowManager:messaging:topics:exportComplete"); - TestExecutionConfig.RabbitConfig.ExportRequestQueue = $"{config.GetValue("WorkflowManager:messaging:topics:exportRequestPrefix")}.{config.GetValue("WorkflowManager:messaging:dicomAgents:dicomWebAgentName")}"; + TestExecutionConfig.RabbitConfig.ExportRequestQueue = $"{config.GetValue("WorkflowManager:messaging:topics:exportRequestPrefix")}.{config.GetValue("WorkflowManager:messaging:dicomAgents:scuAgentName")}"; TestExecutionConfig.MongoConfig.ConnectionString = config.GetValue("WorkloadManagerDatabase:ConnectionString"); TestExecutionConfig.MongoConfig.Database = config.GetValue("WorkloadManagerDatabase:DatabaseName");