Questions tagged [gearman]

Gearman is a system to farm out work to other machines, dispatching function calls to machines that are better suited to do work, to do work in parallel, to load balance lots of function calls, or to call functions between languages.

Gearman is an open source application framework originally written in Perl by Brad Fitzpatrick. Brian Aker and Eric Day rewrote the framework in C.

Gearman is designed to distribute appropriate computer tasks to multiple computers, so large tasks can be done more quickly.

In some cases, load balancing rather than raw speed may be the main goal; a Web server, for instance, could use Gearman to send tasks for which it is not optimized to another computer (which may be running on a different architecture, using another operating system, or loaded with a computer language better suited to a particular operation).

Job server is available in three languages:

  • C/C++
  • Java
  • Perl

Client & Worker APIs are available in following languages:

  • libgearman (C)
  • Shell
  • Perl
  • Nodejs
  • PHP
  • Python
  • Java
  • Databases
  • JMS
  • C# / .NET

Some of the use cases provided at the web site:

Resources

IRC channel is #gearman on Freenode.

484 questions
0
votes
2 answers

Callbacks are not getting called when using concurrent tasks in gearman

I did check the example reverse_client_cb with the reverse_worker as a worker. The worker is getting called and executed but not a single callback ( complete,fail,etc) is getting called in the client. Below is a sample worker and client that I wrote…
venu
  • 1
  • 1
0
votes
2 answers

PHP GearmanClient

I am working on a Gearman client-worker script. Can we declare the Gearman callbacks methods as protected or private? i.e. $this->gearmanClient->setCompleteCallback(array($this, 'JobComplete')); $this->gearmanClient->setFailCallback(array($this,…
Ravish
  • 2,383
  • 4
  • 37
  • 55
0
votes
1 answer

Gearman worker client_id python

What is this command GearmanWorker.set_client_id(client_id) ? http://packages.python.org/gearman/worker.html#gearman.worker.GearmanWorker.set_client_id It means that the worker only serves clients with the specified id ? If yes how can I find a…
Giorgos Komnino
  • 433
  • 1
  • 7
  • 20
0
votes
0 answers

Error running supervisord with gearmand on Ubuntu Natty

I am using Ubuntu Natty. I'm trying to use supervisord to deamonize gearmand. I've installed both gearmand and supervisord. However, whenever I start supervisord I get the following log entries: 2012-05-18 12:23:29,219 CRIT Supervisor running as…
ObiHill
  • 11,448
  • 20
  • 86
  • 135
0
votes
1 answer

How can I register functions and gearmanworker when doBackground is called?

Client: addServer(); $gmclient->doBackground("reverse", "this is a test"); echo "done!\n"; Worker:
Scott Foster
  • 465
  • 3
  • 9
  • 17
0
votes
1 answer

is PYTHON Gearman Worker accept multi-tasks

For example: I have a task named "URLDownload", the task's function is download a large file from internet. Now I have a Worker Process running, but have about 1000 files to download. It is easy for a Client Process to create 1000 task, and send…
truease.com
  • 1,261
  • 2
  • 17
  • 30
-1
votes
1 answer

Is it possible to install php gearman extension on wamp or xampp ( windows )

Is it possible to install php gearman extension on wamp or xampp in windows? I'm running after it for many days. No good news.
Binil John
  • 11
  • 3
-1
votes
1 answer

What's the difference between the commands 'sudo gearmand -d' and 'sudo service gearman-job-server start'?

I'm learning gearman and found that there are two ways to start the gearman: sudo gearmand -d sudo service gearman-job-server start What's the difference? When to use each of them? Thanks for any feedback!
尤川豪
  • 459
  • 5
  • 26
-1
votes
1 answer

Why python gearman worker not showing errors

I have some errors while using gearman in python: import gearman gm_worker = gearman.GearmanWorker(['localhost:4730']) def task_listener_reverse(gearman_worker, gearman_job): print d print 'Reversing string: ' + gearman_job.data return…
-1
votes
1 answer

PECL Adding gearman to php extension

Hi i'm really having a hard time here, I'm trying to install gearman job/task queue. I'm using windows, wappstack to be exact, then followed exactly the instructions here, and so far so good. I think I've installed the gearman server. But I can't…
muffin
  • 2,034
  • 10
  • 43
  • 79
-1
votes
1 answer

How can I make sure PHP won't give me the "array to string conversion error"?

I created an app that has a Gearman worker that pushes information to New Relic Insights. Everything works fine, but when I run the testing script on Terminal, the following error messages appears (after process is done):…
-1
votes
1 answer

symfony2 gearman worker stop when clearing the cache

I implementing Mmoreram gearman bundle in my symfony(2.4) project. I have website that users make action and triggers jobs. like: # Get Gearman and tell it to run in the background a 'job' $id =…
Haim Evgi
  • 123,187
  • 45
  • 217
  • 223
-1
votes
1 answer

Gearman php-workers: fork processes on request

I have a gearman server, that has a php worker-script in background (managed by supervisord). The process is asynchronous, so the main script does not have to wait. The problem is that I do not need the worker 100% of the time in background, I only…
user2531657
  • 339
  • 2
  • 9
-1
votes
1 answer

How to make async http request in php across datacenters

We are working on Kafka based event collection pipeline which will accept incoming event through HTTP GET / POST requests. It should be able to receive event by user browser as well as web server which are running on Nginx + PHP-FPM. By the very…
pseudonym
  • 129
  • 1
  • 8
-2
votes
1 answer

Increase connections to mysql cause rising sending data time in each on same query

Forking multiple process in php (Supervisor). Each create connection to same Mysql DB and execute same SELECT query in parallel (Gearman). If i increase amount of processes (i.e. same time connections) and more same queries will run in parallel lead…
1 2 3
32
33