"you won't see discussion on why double-checked locking implementations of the Singleton pattern don't work. "
... nor should you.
Two scenarios:
1.There must be only one Singleton instance at a time, and if this rule is broken it has negative consequences for the correctness of your application, or a large performance overhead.
Make the getInstance() method synchronized.
2. A short-lived second instance is not a huge problem.
Don't worry about it.
There is far too much emphasise placed on the avoidance of synchronization, when greater gains can be made by optimizing other things like your algorithms. The performance cost has been reduced in VMs in the last few years anyway. The double locking idiom existed purely to avoid synchronization, and never worked anyway.
I heard a great quote at JavaOne a few years ago: "The cost of synchronization is less than the cost of stupidity".
I've seen criticism of Java because of these choices from certain quarters at various times. It is interesting to see the same decisions being made again 6 years on, which I believe vindicates Mr. Gosling.
I have Windows NT 4.0 on my work PC. We got it from a company called "Microsoft". The operating system hasn't crashed for a lot longer than a week, in fact I cannot remember the last time it did.
I'm not a rabid Windows advocate by any stretch of the imagination, but these posts are flamebait.
>On the other hand, There's a law against >Breaking and Entering my house.
Yes, but if you buy a VCR, there is no law against dismantling it yourself. There is such a law against doing the same for software. The software equivalent of breaking and entering would be hacking into someones private computer and extracting data.
>Darn, you beat me to it. But I'd like to add to
>your comments.
>I've seen this kind of flame-fest ever since I
>started using the internet. Take usenet as an
>example. Outside of pr0n, I'd say more than half
>the posts in many unmoderated technical
>newsgroups are childish chatter.
You are wrong. I noticed one exception a few years ago. There is printer newsgroup (I think it was comp.sys...printers), where people just discussed printer issues and features with no discernable flaming. Boring - professional, but boring. I unsubscribed as soon as I got my Lazerjet problem sorted.
Apart from that case, you are completely correct.:-)
...and the tests have to be kept current with public API changes (and implementation changes if the test delves into the backend like initialising the DB etc.)
I am not criticising unit testing, just the posters assertion.
The commissionars were almost fired a few years ago because of corruption, but the EU Parliment chickened out in the end.
The Commission is a giant quango (an unelected government body) appointed by individual EU governments. Such an important role should be directly elected by the public or else the powers should be handed over to the EU parliment.
This news on copyright law is disgusting. I thought this had recently been ruled out for the EU?
If the primary area where you would benefit from improved performance is games (which is true for a lot of us as most office apps have not been CPU limited for a while now), then the benefit of $600 spent on a GF3 is likely to be greater, and the cost less, than upgrading to a P4 and new motherboard.
Not that I'm going to be buying a GF3 at that price...
ColdFusion is not an OO language, it is not even a structured programming language (you can't write functions that you call elsewhere in the same file). This means that any non-trivial web apps rapidly grow into an unmaintainable mess of code.
And in spite of their benchmarks, any procedural code in CF is dog slow. If you hit on a bug (and there are quite a few) that causes problems with what you trying to do, you cannot switch app server vendors as you would with JSP.
It may have been faster that Tomcat, as configured by them, but this does not mean that ColdFusion is faster than JSP. ColdFusion is interpreted, more so than Java, and is not nearly as optimised and researched as Java virtual machines are.
The one thing I would give ColdFusion credit for is DB access, which is extremely quick and easy. You configure a DB connection in the CF administration interface, and you then refer to it by name in the code, no specifying all the connection info. This allows you to create dynamic webpages that show DB records much more quickly than with the competitive systems.
In this regard, ColdFusion does for Web Apps what VB did for Windows desktop client apps, in that it allows very rapid development of frontends for databases. Arguably it is "the VB of web development", even more so than ASP+VBScript. But as you can imagine, the resulting code frequently ends up about as maintainable as a lot of VB apps.
is whether this is a resurrected species of bacteria, or a 250 million year old specimen of a species which is still around today?
If it is the latter, then you guys have nothing to worry about. If not, then all such research should be carefully quarantined. Even if it is one of the 99.99% of bacteria that are harmless, it might have unforseen environmental effects...
May point was these post were funny, cause they were witty variations of the normal troll or puns on the post (e.g. "how about a Beowulf *2* cluster...").
but the cool this is that the display actually works like RAM (it retains its state until voltage is applied to reset it)
:-)
So it works like RAM, except for the way it works.
This changes everything. I never realised how harmful it could be.
"you won't see discussion on why double-checked locking implementations of the Singleton pattern don't work. "
... nor should you.
Two scenarios:
1.There must be only one Singleton instance at a time, and if this rule is broken it has negative consequences for the correctness of your application, or a large performance overhead.
Make the getInstance() method synchronized.
2. A short-lived second instance is not a huge problem.
Don't worry about it.
There is far too much emphasise placed on the avoidance of synchronization, when greater gains can be made by optimizing other things like your algorithms. The performance cost has been reduced in VMs in the last few years anyway. The double locking idiom existed purely to avoid synchronization, and never worked anyway.
I heard a great quote at JavaOne a few years ago: "The cost of synchronization is less than the cost of stupidity".
For comparison, how much do US launches cost?
What about the European Arienne rocket?
How is the MS management serving the best interests of their shareholders with this action?
Provided you can't pirate the OS MS has nothing to gain by impeding the copying/access to content, however a new "No mon, no fun" OS will not sell.
"If that's not a path to base your entire life on, I don't know what is."
:-)
Hmm... perhaps reality?
"is it good to see Apache embrassing a Microsoft framework "
:-)
You've miss-spelt "embarassing".
Some of the features dropped from C++:
Multiple Inheritance
Templates
Operator Overloading
Some of the features added/retained:
Garbage Collection
Exception handling
I've seen criticism of Java because of these choices from certain quarters at various times. It is interesting to see the same decisions being made again 6 years on, which I believe vindicates Mr. Gosling.
I have Windows NT 4.0 on my work PC. We got it from a company called "Microsoft". The operating system hasn't crashed for a lot longer than a week, in fact I cannot remember the last time it did.
I'm not a rabid Windows advocate by any stretch of the imagination, but these posts are flamebait.
That answer your question?
>On the other hand, There's a law against >Breaking and Entering my house. Yes, but if you buy a VCR, there is no law against dismantling it yourself. There is such a law against doing the same for software. The software equivalent of breaking and entering would be hacking into someones private computer and extracting data.
>Darn, you beat me to it. But I'd like to add to
:-)
>your comments.
>I've seen this kind of flame-fest ever since I
>started using the internet. Take usenet as an
>example. Outside of pr0n, I'd say more than half
>the posts in many unmoderated technical
>newsgroups are childish chatter.
You are wrong. I noticed one exception a few years ago. There is printer newsgroup (I think it was comp.sys...printers), where people just discussed printer issues and features with no discernable flaming. Boring - professional, but boring. I unsubscribed as soon as I got my Lazerjet problem sorted.
Apart from that case, you are completely correct.
...and the tests have to be kept current with public API changes (and implementation changes if the test delves into the backend like initialising the DB etc.)
I am not criticising unit testing, just the posters assertion.
I hate that.
The only difference in this case would be that the traditional fibre would be easier to repair (assuming you can repair them).
That is a very worrying analogy :-)
The commissionars were almost fired a few years ago because of corruption, but the EU Parliment chickened out in the end.
The Commission is a giant quango (an unelected government body) appointed by individual EU governments. Such an important role should be directly elected by the public or else the powers should be handed over to the EU parliment.
This news on copyright law is disgusting. I thought this had recently been ruled out for the EU?
If the primary area where you would benefit from improved performance is games (which is true for a lot of us as most office apps have not been CPU limited for a while now), then the benefit of $600 spent on a GF3 is likely to be greater, and the cost less, than upgrading to a P4 and new motherboard.
Not that I'm going to be buying a GF3 at that price...
Who modded that up?
"462mm x 462mm? You want large? There are 25.4 mm per inch. This is saying it is almost 18.2 inches x 18.2 inches"
462 mm^2 means the height multiplied by the width is 462, so the sides are equal to the square root of 462 (assuming it is square).
... shows their cluelessness.
ColdFusion is not an OO language, it is not even a structured programming language (you can't write functions that you call elsewhere in the same file). This means that any non-trivial web apps rapidly grow into an unmaintainable mess of code.
And in spite of their benchmarks, any procedural code in CF is dog slow. If you hit on a bug (and there are quite a few) that causes problems with what you trying to do, you cannot switch app server vendors as you would with JSP.
It may have been faster that Tomcat, as configured by them, but this does not mean that ColdFusion is faster than JSP. ColdFusion is interpreted, more so than Java, and is not nearly as optimised and researched as Java virtual machines are.
The one thing I would give ColdFusion credit for is DB access, which is extremely quick and easy. You configure a DB connection in the CF administration interface, and you then refer to it by name in the code, no specifying all the connection info. This allows you to create dynamic webpages that show DB records much more quickly than with the competitive systems.
In this regard, ColdFusion does for Web Apps what VB did for Windows desktop client apps, in that it allows very rapid development of frontends for databases. Arguably it is "the VB of web development", even more so than ASP+VBScript. But as you can imagine, the resulting code frequently ends up about as maintainable as a lot of VB apps.
is whether this is a resurrected species of bacteria, or a 250 million year old specimen of a species which is still around today?
If it is the latter, then you guys have nothing to worry about. If not, then all such research should be carefully quarantined. Even if it is one of the 99.99% of bacteria that are harmless, it might have unforseen environmental effects...
"RSI, and other psychological conditions come and go."
RSI isn't a psychological condition, it is having very painfull wrists or hands. I hope you never get it.
May point was these post were funny, cause they were witty variations of the normal troll or puns on the post (e.g. "how about a Beowulf *2* cluster...").
"One in ten office workers in Britain, the United States, Germany, Finland and Poland suffers from depression, anxiety, stress or burnout"
Might it be the case that one in ten *people* suffers from those conditions, whether they are office workers or not?
This post and the first post are both funny. Lighten up.