original_string: public function ping()
      {
          $options = static::getOptions();
          $debug = @$options['debug'] === true;
  
          $gmClient = new GearmanClient();
          $gmClient->addServer($options['gearman']['host'], $options['gearman']['port']);
  
          $ping = $gmClient->ping(self::generateUnique());
  
          if ($debug)
              echo "==> Pinging job server: " . ($ping ? 'Success' : 'Failure') . PHP_EOL;
  
          $code = $gmClient->returnCode();
          if ($code != GEARMAN_SUCCESS)
              throw new \Exception("Ping failed ($code)");
  
          return $ping;
      }
code: public function ping()
      {
          $options = static::getOptions();
          $debug = @$options['debug'] === true;
  
          $gmClient = new GearmanClient();
          $gmClient->addServer($options['gearman']['host'], $options['gearman']['port']);
  
          $ping = $gmClient->ping(self::generateUnique());
  
          if ($debug)
              echo "==> Pinging job server: " . ($ping ? 'Success' : 'Failure') . PHP_EOL;
  
          $code = $gmClient->returnCode();
          if ($code != GEARMAN_SUCCESS)
              throw new \Exception("Ping failed ($code)");
  
          return $ping;
      }
code_tokens: public function ping ( ) { $ options = static :: getOptions ( ) ; $ debug = @ $ options [ 'debug' ] === true ; $ gmClient = new GearmanClient ( ) ; $ gmClient -> addServer ( $ options [ 'gearman' ] [ 'host' ] , $ options [ 'gearman' ] [ 'port' ] ) ; $ ping = $ gmClient -> ping ( self :: generateUnique ( ) ) ; if ( $ debug ) echo "==> Pinging job server: " . ( $ ping ? 'Success' : 'Failure' ) . PHP_EOL ; $ code = $ gmClient -> returnCode ( ) ; if ( $ code != GEARMAN_SUCCESS ) throw new \ Exception ( "Ping failed ($code)" ) ; return $ ping ; }
docstring: Ping job servers
  
  @return TaskDaemon
docstring_tokens: Ping job servers