Ruby Ep. 7: Concurrency and avoiding race conditions with Ruby on Rails

Опубликовано: 16 Октябрь 2024
на канале: Atomic Jolt
2,589
38

Shows how to use the ActiveRecord method 'lock' which uses 'Select for update' in order to ensure only one process can change a database value. We also illustrate how to test with concurrent processes.

The refreshably method can be found in the Atomic Jolt lti_starter_app project here: https://github.com/atomicjolt/lti_sta....

Code for the breakpoints can be found here: http://eng.flipp.com/breakpoints-a-ru...