Skip to content

Conversation

@multippt
Copy link

@multippt multippt commented Apr 12, 2023

Fixes #191

There's a deadlock scenario if the stream is being shutdown while still receiving events, which can occur if using LifecycleEvents and cancelling the context.

Example reproduction case

func TestStreamShutdown(t *testing.T) {
	s := NewStream(1, 2)
	events := testEvents(1)
	s.Shutdown()
	s.Push(events[0])
}

@multippt multippt requested a review from a team as a code owner April 12, 2023 07:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Deadlock if Stream Shutdown races with Push

1 participant