fsek / fsek/rustsystem

RwLock order enforcement

Open
#22 0 comments 0 reactions 0 assignees View on GitHub
medium reliability
Dominant language
TypeScript
Stars
2
Forks
0
PR merge metrics
No merged PRs in 30d

Description

The order in which the RwLocks are currently acquired in `meeting` is not enforced. The order:
1. `vote_auth`
2. `voters`
3. `admin_auth`
4. `invite_auth`
is only in that order because it was the most practical. Deadlocks could easily arise from changes to endpoints locking in another order (eg `voters` then `vote_auth` would deadlock with the logic in `start-vote`). The order could (and probably should) be enforced at compile time https://www.youtube.com/watch?v=Ba7fajt4l1M&t=1115s

The chances of deadlock is currently quite small, since the system is currently maintained my me, and I know what the order should be, but this should be seen as a future-proofing enhancement.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.