What is so bad about Singletons

Posted by Ewan Makepeace on Stack Overflow See other posts from Stack Overflow or by Ewan Makepeace
Published on 2008-09-26T06:02:00Z Indexed on 2010/04/07 13:33 UTC
Read the original article Hit count: 254

The Singleton pattern is a fully paid up member of the GoF Patterns Book but lately seems rather orphaned by the developer world. I still use quite a lot of singletons, especially for Factory classes, and while you have to be a bit careful about multithreading issues (like any class actually) fail to see why they are so awful.

This site especially seems to assume that everyone agrees that Singletons are evil. Why?

© Stack Overflow or respective owner

Related posts about best-practices

Related posts about design-patterns