Hi!
On Mon, Nov 16, 2009 at 01:49:21AM -0800, Đoàn Cao Nghĩa wrote:
> I have do job with doBackground
>
> $job_handle = $client->doBackground("some_func",'my string');
>
> and I have a handle of this job, another process, i want to check
> status of job with :
>
> $status = $client->jobStatus($saved_job_handle);
>
> but when job complete, this return array (false,false,0,0);
This is normal. When the job is done, the job server drops all
knowledge of the job. If you want the result of the background job,
you will want to store that somewhere with a unique key to find
it again. For example, you could use memcached, MySQL, a shared
filesystem, or some other data store appropriate for your application.
Some things on the roadmap for Gearman is a temporary result cache
in the job server, and probably put a TTL on each job result (you
don't want it to grow unbound for obvious reasons).
-Eric