Skip to content

Conversation

@wneessen
Copy link
Owner

Introduced a sendMutex to synchronize access to shared resources in the DialAndSendWithContext method. This ensures thread safety when sending multiple messages concurrently. Added a corresponding test to verify the concurrent sending functionality.

This closes #380

Introduced a sendMutex to synchronize access to shared resources in the DialAndSendWithContext method. This ensures thread safety when sending multiple messages concurrently. Added a corresponding test to verify the concurrent sending functionality.
@wneessen wneessen linked an issue Nov 21, 2024 that may be closed by this pull request
Updated the timeout for the DialAndSend context in 'client_test.go' from 5 seconds to 1 minute to ensure sufficient time for the operation to complete. This change helps prevent premature timeouts that can cause test failures.
@wneessen wneessen merged commit d009698 into main Nov 21, 2024
27 checks passed
@wneessen wneessen deleted the bug/380_use-of-closed-network-connection-error-when-using-concurrently branch November 21, 2024 09:38
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.

"Use of closed network connection" error when using concurrently

2 participants