Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:65726 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 13017 invoked from network); 8 Feb 2013 08:20:17 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 8 Feb 2013 08:20:17 -0000 Authentication-Results: pb1.pair.com header.from=crosse@2bepublished.at; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=crosse@2bepublished.at; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain 2bepublished.at from 78.142.132.104 cause and error) X-PHP-List-Original-Sender: crosse@2bepublished.at X-Host-Fingerprint: 78.142.132.104 server3.zimbrahosting.at Linux 2.6 Received: from [78.142.132.104] ([78.142.132.104:45742] helo=server3.zimbrahosting.at) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 32/11-32656-C35B4115 for ; Fri, 08 Feb 2013 03:20:14 -0500 Received: from [192.168.62.62] (unknown [217.116.179.162]) by server3.zimbrahosting.at (Postfix) with ESMTPSA id BA0B1DAC112 for ; Fri, 8 Feb 2013 09:20:09 +0100 (CET) Message-ID: <5114B537.2050802@2bepublished.at> Date: Fri, 08 Feb 2013 09:20:07 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130106 Thunderbird/17.0.2 MIME-Version: 1.0 To: internals@lists.php.net References: <2B76A3EF-66AC-4E73-B186-236E9C2AE891@gmail.com> <5113AE8F.4060402@2bepublished.at> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] [RFC] Improved Linux process title support in the CLI SAPI From: crosse@2bepublished.at (Christoph Rosse) Hi, could you rename these functions to: cli_process_set_title cli_process_get_title http://www.php.net/manual-lookup.php?pattern=set_&scope=quickref gives me a lot of hits like: xml_parser_set_options stream_set_read_buffer pg_set_info ps_set_border_color etc. its also a lot more readable as it is: object_action_subject. Am 2013-02-07 20:59, schrieb Keyur Govande: > Addressing a bunch of comments at once: > 1) I've removed is_available and renamed the set/get methods to: > cli_process_title_set/get. I've also removed the test dependencies on > pcntl and posix. The patch is updated: > https://gist.github.com/keyurdg/4728770 > 2) Updated the RFC's introduction section with more concrete details > about why this is necessary > > In terms of doing this as an extension: the RFC addresses why this isn't > possible. > > For folks who will not be using this feature, at worst they'll loose a > few KB of memory: the amount needed to store the original argv and the > original environ. > > On Thu, Feb 7, 2013 at 1:25 PM, Nikita Popov > wrote: > > On Thu, Feb 7, 2013 at 2:39 PM, Christoph Rosse > >wrote: > > > why wouldn't this go into core? setting the name of the current > > php-process is definitely something everyone that develops > php-cli scripts > > could use. > > > I use a lot of php-cli scripts and I've never seen the need. Without > having > hard data to back this up, I am pretty sure that this applies to > nearly all > php-cli scripts. > > > > We should not base the decision of putting something into the core on > > assumptions on how many people are going to use the feature. > > > Obviously we should. Whether people will use it is pretty much the most > important aspect for deciding whether or not something should be added. > Even a trivial addition is a loose for the project if nobody is going to > use it. And this is no trivial addition. This seems to be quite a bit > system dependent and uses some odd methods like overwriting argv memory. > And on that note, it also has to copy the argv data if I got that right, > which is something it has to do always and not just when people are > actually using the feature ;) > > I'm not saying I'm against this feature. I'd just really appreciate > it if > we could drop the good old "it doesn't matter if people are going to use > it" non-arguments and instead provide a bit more info for people > like me, > who are not in the process-title-hacking business. I.e. what this is > needed > for an why this is needed in core. E.g. what Arvid mentioned, that > this is > useful when you are running many PHP-based daemons and want to > distinguish > them. That's the kind of stuff I'd like to see in the RFC. > > Regarding core/non-core. People mentioned that this is not > implementable as > an extension. That can be either solved by putting it into core or by > adding the necessary API hook ;) [I'm not arguing which variant is > better, > just saying that not being implementable with current core does not mean > that we can't make it implementable :)] > > Thanks, > Nikita > >