What language is the Threading feature enhanced in? PHP or Ruby

I am creating a web application that requires streaming processing, and I am trying to figure out which langauge between PHP and Ruby has the best streaming function and better performance.

Even if it is not built-in, some light work around or add-ons.

+3
source share
6 answers

I would say Ruby, since Ruby really supports it. PHP is not working.

With PHP, you can create new processes (this is a bad idea) or write several web services and use curl_multi_ * functions to perform some tasks, but streaming is not a PHP function.

+9
source

, , , , , Ruby . JRuby. JVM .

( Groovy, Java .)

+5

PHP .

+2

PHP (, ).

Ruby , 1.8 , 1.9 GIL. ( MRI YARV - 1,8 1,9 Ruby) , 2 ( ), .

.

+2

PHP ; PHP- HTTP- ( , Zend), PHP-.

+2
source

None of these can be a good way to achieve what you are trying to do.

Consider Gearman for asynchronous job processing. If you want to freely connect your service with other services, you will need a messaging service such as RabbitMQ .

It seems that the Gearman will suit your needs.

0
source

Source: https://habr.com/ru/post/1725162/


All Articles