Implementing "the lovely" Singleton Pattern

1 ยท Ilija Eftimov ยท May 26, 2015, midnight
In every software, there are some things that have to be unique. For example, a Rails app has only one logger. Also, applications must have configurations, like environment, various API keys and etc. Take the configuration example - we need only one configuration for a runtime of an application. If all of the configuration data is stored into a class, then the whole app will need to use an object of that class....