swagger-core
                                
                                 swagger-core copied to clipboard
                                
                                    swagger-core copied to clipboard
                            
                            
                            
                        Fix thread safety in `Json.mapper()`
Closes #4672
Instead of following the suggested approach in the issue, a more elegant method was used, where the initialization is delegated to the JVM code for static initialization.
See https://stackoverflow.com/questions/8297705/how-to-implement-thread-safe-lazy-initialization for a thread about this implementation. See also https://en.wikipedia.org/wiki/Initialization-on-demand_holder_idiom for the chosen pattern.