3 ms·
Unfortunatly, I know a lot of devs that don't even know it's a joke. Singleton is still a design pattern used in the wild.
by BiteCode_dev 6y ago
Unfortunatly, I know a lot of devs that don't even know it's a joke.
Singleton is still a design pattern used in the wild.
- Nursie 6y agoI'm not going to argue there are lots of ridiculous patterns out there, which seem to be embraced and encouraged by the various frameworks that a lot of developers seem to rely on. Why bother setting things up explicitly in the way you want when you can declare things as injected, other things as singletons, and then have no real idea why it all went horribly wrong?
- BiteCode_dev 6y agoIt's starting to be the same in Python though. Inertia is huge in our industry, and the HN bubble doesn't gives a good picture of it. Behind corporate firewalls I now see things done the way they were 10 years ago: packaging, string handling, concurrency... I assume it's the curse of being popular and old. And java has been popular for longer than Python, so inertia is even stronger. It doesn't matter if it has lambda since V8 if people still believe the best practice is to pass fat objects around.
- drdec 6y agoThe cool devs don't use the Singleton pattern anymore, we use @ApplicationScoped. (Poe's Law disclaimer: yes, that was light sarcasm.)