You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Improve the example of ActiveSupport::Cache::Store#fetch
The original example has race condition issue that the output of the example isn't conistent, see rails#43588.
The change improves the example by removing unnecessary thread and add detailed comments.
In the new example, there will be race condition only if `ActiveSupport::Cache::MemoryStore` took longer than 0.1 second to extend expiry but that's unlikely to happen.
Closerails#43588
0 commit comments