Skip to content

Introduce AbstractSpinlockWithTokenMutex class#72

Merged
mvorisek merged 24 commits intomasterfrom
expirable_lock
Dec 9, 2024
Merged

Introduce AbstractSpinlockWithTokenMutex class#72
mvorisek merged 24 commits intomasterfrom
expirable_lock

Conversation

@mvorisek
Copy link
Member

@mvorisek mvorisek commented Dec 8, 2024

The original AbstractSpinlockMutex class tried to support timeout* but not token. And token support is not exclusive to AbstractRedlockMutex class.

* but wrongly as "acquire timeout" has no meaning during lock release

BC break: RedisMutex constructor lock expire timeout param was added

Previously the single timeout param was used as "acquire timeout" and "expire timeout". Specify the "expire timeout" manually, otherwise the lock will never expire.

@mvorisek mvorisek marked this pull request as ready for review December 8, 2024 23:52
@mvorisek mvorisek changed the title Introduce AbstractSpinlockExpireMutex class Introduce AbstractSpinlockWithTokenMutex class Dec 8, 2024
@mvorisek mvorisek merged commit c9ad6c1 into master Dec 9, 2024
@mvorisek mvorisek deleted the expirable_lock branch December 9, 2024 00:00
@mvorisek mvorisek mentioned this pull request Dec 10, 2024
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.

1 participant