Managed to get the auth working (which turned out to be as easy as setting one bool flag). Anyway, I attached a failing test. It takes ~10 seconds to run because of few Thread.Sleeps but it shows where the problem is:
[31120,16,19:37:07.364,ERROR] Error while processing message EventStore.Core.Messages.ClientMessage+ReadStreamEventsBackwardCompleted in queued handler ‘Projection Core #0’.
EXCEPTION(S) OCCURRED:
System.NullReferenceException: Object reference not set to an instance of an object.
at EventStore.Projections.Core.Services.Processing.StreamPositionTagger.AdjustTag(CheckpointTag tag) in c:\Projects\EventStore\src\EventStore\EventStore.Projections.Core\Services\Processing\StreamPositionTagger.cs:line 89
at EventStore.Projections.Core.Services.Processing.CheckpointTagVersion.AdjustBy(PositionTagger tagger, ProjectionVersion version) in c:\Projects\EventStore\src\EventStore\EventStore.Projections.Core\Services\Processing\CheckpointTagExtensions.cs:line 52
at EventStore.Projections.Core.Services.Processing.EmittedStream.ReadStreamEventsBackwardCompleted(ReadStreamEventsBackwardCompleted message, CheckpointTag upTo) in c:\Projects\EventStore\src\EventStore\EventStore.Projections.Core\Services\Processing\EmittedStream.cs:line 334
at EventStore.Projections.Core.Services.Processing.EmittedStream.<>c__DisplayClass1.b__0(ReadStreamEventsBackwardCompleted completed) in c:\Projects\EventStore\src\EventStore\EventStore.Projections.Core\Services\Processing\EmittedStream.cs:line 416
at EventStore.Core.Messaging.RequestResponseDispatcher`2.Handle(TResponse message) in c:\Projects\EventStore\src\EventStore\EventStore.Core\Messaging\RequestResponseDispatcher.cs:line 85
at EventStore.Core.Bus.MessageHandler`1.TryHandle(Message message) in c:\Projects\EventStore\src\EventStore\EventStore.Core\Bus\MessageHandler.cs:line 59
at EventStore.Core.Bus.InMemoryBus.Publish(Message message) in c:\Projects\EventStore\src\EventStore\EventStore.Core\Bus\InMemoryBus.cs:line 349
at EventStore.Core.Bus.QueuedHandlerMRES.ReadFromQueue(Object o) in c:\Projects\EventStore\src\EventStore\EventStore.Core\Bus\QueuedHandlerMRES.cs:line 143
If the code that emits the events directly to dest stream is commented out, everything works perfectly fine.
Cheers,
Szymon
EmitBugRepro.cs (5.23 KB)