php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #53315 can php support threading?
Submitted: 2010-11-15 10:50 UTC Modified: 2010-11-15 10:54 UTC
From: yangqingrong at gmail dot com Assigned:
Status: Wont fix Package: Unknown/Other Function
PHP Version: 5.3.3 OS: all
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: yangqingrong at gmail dot com
New email:
PHP Version: OS:

 

 [2010-11-15 10:50 UTC] yangqingrong at gmail dot com
Description:
------------
Hi sir:
   I am a php programmer work in php area for more than 3 years.i have a suggestion about threading for you. i found than php doesn't support threading. could you develop threading in the new version?
i think the threading will like this:

<?php
using namespace Php.Threading;
class MyThread extends Thread
{
   public $num;
   public function __construct()
   {

   }
   
   public function run()
   {
     echo $num . "\n"; 
   }
}
$thread1 = new MyThread();
$thread2 = new MyThread();

$thread1->start();
$thread2->start();

?>


Yang Qing-rong
http://www.wudimei.com


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-11-15 10:53 UTC] pajoye@php.net
-Status: Open +Status: Bogus
 [2010-11-15 10:54 UTC] rasmus@php.net
-Status: Bogus +Status: Wont fix
 [2010-11-15 10:54 UTC] rasmus@php.net
Nope, sorry.  Use out-of-band solutions like Gearman, or use event-driven 
mechanisms like socket_select/curl_multi.  Much more robust than trying to do 
threading in PHP.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Fri Sep 19 15:00:02 2025 UTC