Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
enki42
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
3 ms
·
1.
▲
by
enki42
14y ago
I understand your point of view, but that kind of problem is application specific. When we have to deal with these constraints, of course the use of a Singleton is dumb. If I had to deal with these, I'll change my implementation to fit to m
2.
▲
by
enki42
14y ago
Why should a Singleton be thread safe? Nothing says that it will be used in a multi-threaded environment... For me a Singleton must fulfill the specification given by the Gang of Four. I'm not saying that it should not be thought thread saf
3.
▲
by
enki42
14y ago
Hi everyone! I'm the author of this blog. I agree with most of you that Singleton can lead to destroy a design. I just think that we should not ban something globally, and I'm sure that this (anti-?)pattern can be useful sometimes. The aim