Join Slack
Powered by
In the world of containers - how are people doing ...
# cfml-general
a
aliaspooryorik
06/22/2023, 10:13 AM
In the world of containers - how are people doing locking?
aliaspooryorik
06/22/2023, 10:15 AM
Redis maybe?
s
sknowlton
06/22/2023, 11:32 AM
redis and in the db mostly
a
aliaspooryorik
06/22/2023, 11:34 AM
thanks. That's what I was thinking. I guess with redis I'd do "if lock key exists -> throw".
aliaspooryorik
06/22/2023, 11:34 AM
It's that or "if lock key exists -> sleep(1000) -> try again".
s
sknowlton
06/22/2023, 11:35 AM
usually we do the latter, and then throw after that if it still isn't working
a
aliaspooryorik
06/22/2023, 11:36 AM
Useful to know that works in the real world. The latter would be closer to how
cflock
behaves
aliaspooryorik
06/22/2023, 11:39 AM
Looks like Redisson has an implementation of countdownLatch
https://redisson.org/glossary/java-countdownlatch.html
aliaspooryorik
06/22/2023, 11:41 AM
Ah - pro version only
Open in Slack
Previous
Next