|
|
|
|
|
by throwaway0asd
1281 days ago
|
|
All my service logic is written with Node.js. It executes fast enough. Now it’s as fast as Java (except arithmetic) and probably similar to .Net. The performance problem is not instruction speed or anything to do with the CPU. The performance penalty comes from GC. Java and C# are also garbage collected. I believe Go is not. A GC bottleneck is encountered when information processing frequency sustainably exceeds processing speed for long enough to encounter a problem. This is extremely unlikely to encounter in real world operation but easily produced during performance stress tests. I have found that I can send web socket messages up to 450,000 per second (on my laptop) with a total message processing frequency of about 60,000 per second. That means I can send messages fast than I can process them on the receiving end, which produces a storage problem. After about 450,000 messages message processing drops to a speed of about 300 per 5 seconds waiting on GC. Since this is a per socket problem I cannot imagine this ever becoming a real world problem. Nonetheless, I don’t suspect Go would have such a bottleneck. |
|