Hacker News new | past | comments | ask | show | jobs | submit login

Bluebird is mainly designed for node (V8) and promise performance can make a massive difference on the server. On the client there tend to be fewer async calls and so promise performance is usually less of a factor, but obviously, it depends what you're doing.



> promise performance can make a massive difference on the server.

Great, got data on the type of difference?


This is a thing you can just infer.

If it takes 100ms CPU time to process 10 promises and 1 request involves creating 10 promises, the server can then only handle 100 requests per second at theoretical max.

IO time doesn't matter as much (for throughput) because IO is asynchronous so the server is free to process other requests while waiting for it. But CPU time is only being used for 1 thing at at time.

So to get e.g. 10k rps out of a node server, handling 100000 promises must take well under a second of CPU time. Looking at the benchmark results you can see how many implementations will bottleneck this.


Check out the Bluebird benchmarks [0], or you can easily try it for yourself - create a simple web server which does some makework async task, like stating a bunch of files, then benchmark with ab or something better.

[0] https://github.com/petkaantonov/bluebird/blob/master/docs/do...


Why should I do the work, you made the claim?


By the same token, why do I owe you any further evidence?


You haven't provided any evidence so far. You owe evidence because you made a claim. If you are unsure whether Bluebird's Promise performance makes a difference in a real-world scenario, why make such a claim?


You are asking a question, I do not owe you an answer, it's up to you to find out whether this stuff matters for your use case. I've done these tests myself, it is trivial for you to do the same. Do your own homework.


> You are asking a question, I do not owe you an answer

I agree! But you did answer it:

> Bluebird is mainly designed for node (V8) and promise performance can make a massive difference on the server.

If I'm sacrificing simplicity (by using a non-native Promise implementation with a very large API) because of performance improvements, I want data (proof) of these performance improvements. If you don't have the data that's fine! No harm done, I'll keep waiting until someone does.


Which they provided by linking to the benchmark/data.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: