From 618f65d1ff9d9a75ae0d1dcc58c9b9c20632079e Mon Sep 17 00:00:00 2001 From: Tomasz Maruszak Date: Sun, 17 Nov 2024 14:37:11 +0100 Subject: [PATCH] AmazonSQS transport Signed-off-by: Tomasz Maruszak --- src/SlimMessageBus.Host/Collections/AsyncTaskList.cs | 2 +- src/SlimMessageBus.Host/MessageBusBase.cs | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/SlimMessageBus.Host/Collections/AsyncTaskList.cs b/src/SlimMessageBus.Host/Collections/AsyncTaskList.cs index 25dca3c1..41b70d8a 100644 --- a/src/SlimMessageBus.Host/Collections/AsyncTaskList.cs +++ b/src/SlimMessageBus.Host/Collections/AsyncTaskList.cs @@ -33,7 +33,7 @@ static async Task AddNext(Task prevTask, Func taskFactory) /// - /// Awaits (if any) bus intialization (e.g. topology provisining) before we can produce message into the bus. + /// Awaits (if any) bus intialization tasks (e.g. topology provisining) before we can produce message into the bus (or consume messages). /// /// public async Task EnsureAllFinished() diff --git a/src/SlimMessageBus.Host/MessageBusBase.cs b/src/SlimMessageBus.Host/MessageBusBase.cs index 4ae8063a..78c5c112 100644 --- a/src/SlimMessageBus.Host/MessageBusBase.cs +++ b/src/SlimMessageBus.Host/MessageBusBase.cs @@ -64,7 +64,13 @@ public abstract class MessageBusBase : IDisposable, IAsyncDisposable, protected bool IsDisposed { get; private set; } #endregion - + + /// + /// Maintains a list of tasks that should be completed before the bus can produce the first message or start consumers. + /// Add async things like + /// - connection creations here to the underlying transport client + /// - provision topology + /// protected readonly AsyncTaskList InitTaskList = new(); #region Start & Stop