-
Notifications
You must be signed in to change notification settings - Fork 752
Properly get workers pids when running on SunOS. #139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
On my Debian system, the output of Maybe we should simply switch completely over to the more widely-supported Of course, that's just me. |
This may not be the best place to discuss it, since it's not directly related to the changes being made here, but it involves the code being changed, so I'll bring it up while I'm at it. This function relies on either It might be nice to mention this limitation (because there isn't an obvious clean fix) somewhere in the documentation so that implementers can be aware that either |
Proctitle would not be needed for a PHP 5.5 implementation (cli_set_process_title), but I assume it will be YEARS before many area actually able to use 5.5 in their shared hosts. |
True on both counts. Though it would still have to work. No idea why the extension isn't working on this particular host; the bug might also affect 5.5's native implementation. |
Anyone else have any feedback on this? @chrisboulton? |
I think I agree with this decision too, but then again Resque (2.0) itself has gone all out with separations for each OS variation which may be even safer in the long run: https://github.com/resque/resque/blob/master/lib/resque/process_coordinator.rb |
It may ultimately come down to how much we wish to emulate Ruby Resque:
Which approach we wish to take (either one of these [relative] extremes, or something elsewhere on the spectrum) isn't entirely clear at the moment. Obviously some aspects will need to be modified to account for PHP idiosyncrasies, but aside from those, how close to the Ruby implementation are we aiming? |
i think, to be as close to the ruby implementation as possible is the best way to go. in our situation we're using php-resque as queueing mechanism, and using the ruby resque as dashboard component. it works fine at the moment and hope, that this is not going to break in near future. |
@johannesnagl The only part that needs to be identical for that is the in-Redis stuff. Indeed, your exact setup is cited as one of the main reasons the in-Redis stuff is the way it is - so we don't have to reinvent the web interface as well. That aspect isn't likely to change in the foreseeable future. |
maybe this should be an extensibility option like so: protected $unix_flavor;
function set_unix_flavor(UnixInterface $unix) {
$this->unix_flavor = $unix;
}
function get_worker_pids() {
$this->unix_flavor->get_worker_pids();
} |
When getting worker pids on SunOS (OpenIndiana or any other Solaris derivative) the ps command does not support the arguments as on linux. So to be able to get the worker pids the command line arguments for ps need to be changed.