note 119474 added to intro.pcntl

From: Date: Wed, 15 Jun 2016 21:02:59 +0000
Subject: note 119474 added to intro.pcntl
Groups: php.notes 
Request: Send a blank email to php-notes+get-205730@lists.php.net to get a copy of this message
Actually it makes perfect sense why process control features are not supported for the Apache module. The Apache HTTP server is the chief process. It invokes the PHP module when steered to PHP by the resource requested (e.g. http://foo.php) It invokes the PHP module, typically on a new thread or a pooled thread. The PHP module then runs your script, but Apache server is still the owning process. In this execution model, the job of your PHP script is generally to go about its business as fast as possible and return. This allows the Apache daemon to do something else useful with the thread it let you borrow. Yes, some scripts take longer to do their duty than others, but blocking the thread for extended periods is usually frowned upon. If your script was allowed to mess with the signal handlers of the running process, it would be messing with the Apache daemon itself! That daemon has already installed signal handlers for its own use. It is just plain sense not to allow the process control operations in this context. ---- Server IP: 72.52.91.14 Probable Submitter: 198.46.10.15 ---- Manual Page -- http://php.net/manual/en/intro.pcntl.php Edit -- https://master.php.net/note/edit/119474 Del: integrated -- https://master.php.net/note/delete/119474/integrated Del: useless -- https://master.php.net/note/delete/119474/useless Del: bad code -- https://master.php.net/note/delete/119474/bad+code Del: spam -- https://master.php.net/note/delete/119474/spam Del: non-english -- https://master.php.net/note/delete/119474/non-english Del: in docs -- https://master.php.net/note/delete/119474/in+docs Del: other reasons-- https://master.php.net/note/delete/119474 Reject -- https://master.php.net/note/reject/119474 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#205730) next »