Skip to content
This repository has been archived by the owner on Apr 17, 2019. It is now read-only.

Fix thread safe issue in status streaming #1991

Merged
merged 1 commit into from
Dec 26, 2018

Conversation

luckychess
Copy link
Contributor

Description of the Change

Pull request replaces static local variable in to a generic local one in status streaming handler to prevent races on it (actually, initialisation by itself is safe but % operator is not).

Benefits

Clients can now perform streaming status requests without unknown status issue (IR-76).

Possible Drawbacks

None.

Usage Examples or Tests

Correctness of fix was tested with help of thread sanitizer. Also instance of irohad is now able to survive under load of 4 clients bombarding it with transactions and streaming status requests on it for at least 30 minutes.

@neewy neewy added this to the rc2 milestone Dec 26, 2018
@luckychess luckychess merged commit 428ab64 into dev Dec 26, 2018
@luckychess luckychess deleted the fix/streaming_unknown_status branch December 26, 2018 09:58
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants