Skip to content
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

Uncaught Error: Call to undefined method Beanie\Producer::use() #2

Closed
wozzup opened this issue May 15, 2016 · 1 comment
Closed

Uncaught Error: Call to undefined method Beanie\Producer::use() #2

wozzup opened this issue May 15, 2016 · 1 comment

Comments

@wozzup
Copy link

wozzup commented May 15, 2016

producer.php

<?php
require  __DIR__.'/vendor/autoload.php';

use Beanie\Beanie;

// create a Producer for the pool
$producer = Beanie::pool(['localhost:11300'])->producer();

// tell the producer all jobs created should go to a certain tube
$producer->use('some-tube');

// put the job on a random connection in the pool
$job = $producer->put('some job data');
print_r($job->stats());

php producer.php

PHP Fatal error:  Uncaught Error: Call to undefined method Beanie\Producer::use() in /home/username/beanstalkd/producer.php:11
Stack trace:
#0 {main}
  thrown in /home/username/beanstalkd/producer.php on line 11

php -v

PHP 7.0.4-7ubuntu2 (cli) ( NTS )
beanstalkd 1.10
@zwilias
Copy link
Owner

zwilias commented May 31, 2016

You're right, that's a mistake in the documentation. useTube is the correct verb here 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants