Doc #64219 [NEW]: Hostname and port number not optional for GearmanClient::addServer()
| From: | php at bitblit dot net | Date: | Fri, 15 Feb 2013 17:23:57 +0000 |
| Subject: | Doc #64219 [NEW]: Hostname and port number not optional for GearmanClient::addServer() | ||
| Groups: | php.doc.bugs | ||
| Request: | Send a blank email to doc-bugs+get-9522@lists.php.net to get a copy of this message | ||
From: php at bitblit dot net
Operating system: Ubuntu LTS 12.04
PHP version: Irrelevant
Package: gearman
Bug Type: Documentation Problem
Bug description:Hostname and port number not optional for GearmanClient::addServer()
Description:
------------
---
From manual page: http://www.php.net/gearmanclient.addserver#refsect1-
gearmanclient.addserver-description
---
Documentation clearly shows that hostname and port numbers are optional.
However
in practice, the function fails to connect with default values when they
are left
unspecified.
Test script:
---------------
$gearman_client = new \GearmanClient();
$gearman_client->addServer();
// call verify() function in my worker and send pathname
$task = $gearman_client->doNormal('verify', $pathname);
Expected result:
----------------
I expect to see my debug output from the worker but it never runs because
Gearman
never receives a connect (according to the Gearman log).
Actual result:
--------------
Apache error log contains:
[Fri Feb 15 11:55:38 2013] [error] [client 10.0.1.32] PHP Warning:
GearmanClient::doNormal(): send_packet(GEARMAN_COULD_NOT_CONNECT) Failed to
send
server-options packet -> libgearman/connection.cc:430
--
Edit bug report at https://bugs.php.net/bug.php?id=64219&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=64219&r=trysnapshot54
Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=64219&r=trysnapshot53
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=64219&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=64219&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=64219&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=64219&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=64219&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=64219&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=64219&r=support
Expected behavior: https://bugs.php.net/fix.php?id=64219&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=64219&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=64219&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=64219&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=64219&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=64219&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=64219&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=64219&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=64219&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=64219&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=64219&r=mysqlcfg