Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix/Fix server race conditions #127

Merged
merged 1 commit into from
Nov 16, 2022

Conversation

bestwebua
Copy link
Member

@bestwebua bestwebua commented Nov 16, 2022

This PR is a sequel of #125 by @benjamin-rood and fix for: #124

  • Resolved race conditions with R/W lock in Server
  • Resolved race conditions with R/W lock in Message
  • Updated CircleCI config to test race conditions

It will be released in a new major smtpmock release.

@codecov-commenter
Copy link

codecov-commenter commented Nov 16, 2022

Codecov Report

Merging #127 (9eb0e70) into develop (decf20d) will not change coverage.
The diff coverage is 100.00%.

❗ Current head 9eb0e70 differs from pull request most recent head ad53d87. Consider uploading reports for the commit ad53d87 to get more accurate results

@@            Coverage Diff            @@
##           develop      #127   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           16        16           
  Lines          757       790   +33     
=========================================
+ Hits           757       790   +33     
Impacted Files Coverage Δ
message.go 100.00% <100.00%> (ø)
server.go 100.00% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@bestwebua bestwebua marked this pull request as ready for review November 16, 2022 11:34
@bestwebua bestwebua changed the title Bugfix/fix server race conditions Bugfix/Fix server race conditions Nov 16, 2022
@bestwebua bestwebua linked an issue Nov 16, 2022 that may be closed by this pull request
4 tasks
@bestwebua bestwebua force-pushed the bugfix/fix-server-race-conditions branch from 137cc73 to 9eb0e70 Compare November 16, 2022 11:59
* Resolved race conditions with R/W lock in Server
* Changed lock type on messages to regular sync.Mutex
* Changed all *Message methods on concrete Message type instead
* Added Message#IsConsistent(), tests
* Updated tests
* Updated CircleCI config
* Updated project documentation, changelog
@bestwebua bestwebua force-pushed the bugfix/fix-server-race-conditions branch from 9eb0e70 to ad53d87 Compare November 16, 2022 16:15
@bestwebua bestwebua merged commit 2b0dfc1 into develop Nov 16, 2022
@bestwebua bestwebua deleted the bugfix/fix-server-race-conditions branch November 16, 2022 16:23
Copy link
Collaborator

@benjamin-rood benjamin-rood left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything good. (sorry for the delay)
👍 🚀

message.go Show resolved Hide resolved
server_test.go Show resolved Hide resolved
message.go Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

[BUG] Race condition detected when run in test files
3 participants