wolverine icon indicating copy to clipboard operation
wolverine copied to clipboard

Service Bus Configured with AutoPurgeOnStartup Can't Configure Topics With Sessions Enabled

Open zjohnson-messagedigital opened this issue 8 months ago • 2 comments

Describe the bug Wolverine throws errors during listener initialization if AutoPurgeOnStartup is set and a listener is configured on a topic that enables sessions. It looks like the PurgeAsync method in https://github.com/JasperFx/wolverine/blob/295ea29e83f23e80b0c3dcfad56dcc3f46e649f5/src/Transports/Azure/Wolverine.AzureServiceBus/Internal/AzureServiceBusSubscription.cs#L121 is calling ServiceBusClient.CreateReceiver instead of AcceptNextSessionAsync causing it to fail.

To Reproduce Steps to reproduce the behavior:

  1. Configure with AzureServiceBusConfiguration.AutoPurgeOnStartup()
  2. Create a Service Bus Sender and Listener that connected to a Topic with Sessions enabled.
  3. Start
  4. See error

zjohnson-messagedigital avatar Mar 10 '26 20:03 zjohnson-messagedigital

@zjohnson-messagedigital Got it, and do remember you have a private Discord room for JasperFx support too! I'll aim to have this out soon. Read your company wrong the first time:/

jeremydmiller avatar Mar 10 '26 21:03 jeremydmiller

Thanks @jeremydmiller, this was just a behavior I came across and isn't blocking me at this time. Figured I'd post it here in case anybody else came across it.

zjohnson-messagedigital avatar Mar 11 '26 12:03 zjohnson-messagedigital