How to check Rails app's thread safety for Puma
Thread safety can not be detected in general. If there was some way to detect it automatically, probably your compiler/interpreter would warn you about it.Race conditions can not be detected by automatic systems, they can be even hard to reproduce.
Depending on your interpreter:
CRuby
has GIL, so usingPuma
with it is pointless.- If you are using
JRuby
orRubinius
than you can probably benefit fromPuma
and most probably the gems you use have documented their methods/classes thread-safety. In this case all you need is to check your code.