3 ms·
The article isn't compelling. I'd argue most scripting languages, including Ruby are too slow for many situations. The author is thinking of one request. What i
by mnm1 9y ago
The article isn't compelling. I'd argue most scripting languages, including Ruby are too slow for many situations. The author is thinking of one request. What if I have multiple Ruby APIs to hit? 100ms for each one adds up quickly. The frontend being a mess of many megabytes and taking 15 seconds to load is also not an excuse to make the backend shitty. Fix the front end, then the backend speed will matter. Yes, there are other considerations, but these days there are plenty of languages to choose from for the back end that offer memory management and instant reloading of code like Ruby and other scripting languages while being quite a few times faster. They also offer a chance to escape with a decent app in case the company you're working for hired a bunch of idiot architects that put in database wrapper code that takes 10x as long as the database itself to run and you don't have time or resources to rewrite the last four years worth of work in a faster language with a proper architecture. I personally cannot see choosing Ruby or any similar language (PHP, Python, JS) in the future for webdev stuff.
- schneems 9y ago> What if I have multiple Ruby APIs to hit? Then hit them with multiple concurrent threads and move on.
- flavio81 9y ago... do you think available memory and CPU time do not decrease when you spawn more threads?
- schneems 9y agoUse threads. They exist. Use em'. Know what threads are really good at? Hiding IO time. They're like REALLY good at it. When a thread is blocked on IO, it's not spinning your CPU. So is the thread "free"? No. Is it pretty cheap compared to re-writing an app in another lang? Yes.
- mnm1 9y agoAnd if I need to hit them in serial?