Brighter icon indicating copy to clipboard operation
Brighter copied to clipboard

[Bug] TimedOutboxArchiver is always calling async version of archiver

Open jakoss opened this issue 5 months ago • 1 comments

Describe the bug

TimedOutboxArchived is not checking whether the IAmOutbox is sync or async, it is always calling OutboxArchiver.ArchiveAsync. This causes background exception when outbox have sync implementation. Messages are not archived.

To Reproduce

Register synchronous outbox provider and outbox archiver. You will see exceptions logged in the background

Exceptions (if any)

fail: Paramore.Brighter.OutboxArchiver[0]
      Error while archiving from the outbox
      System.NullReferenceException: Object reference not set to an instance of an object.
         at Paramore.Brighter.OutboxArchiver.ArchiveAsync(Int32 minimumAge, CancellationToken cancellationToken, Boolean parallelArchiving) in /_/src/Paramore.Brighter/OutboxArchiver.cs:line 81

Further technical details

  • Brighter version 9.9.10
  • Include the output of dotnet --info
  • The OS (Window, Linux, MacOs, etc)

jakoss avatar Jul 16 '25 12:07 jakoss

Note to self: we need to check that this works in V10.

iancooper avatar Jul 25 '25 21:07 iancooper