You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@sling.apache.org by 王鑫 <wa...@3dly.net> on 2012/11/25 10:43:09 UTC

how to use sling cluster and job

Hi,

I'm new sling user.

I would like to ask is:
first: sling clustering solution has not been tested?
I think how in the cluster, the use of the the job mechanism and jackrabbite.

second: find the JobUtil acknowledgeJob method, reported such an exception:
JobStatusNotifier context is not available in event properties.
Context is null, what causes it?


wangxin  from China

Re: how to use sling cluster and job

Posted by Carsten Ziegeler <cz...@apache.org>.
Hi,

2012/11/25 王鑫 <wa...@3dly.net>:
> Hi,
>
> I'm new sling user.
>
> I would like to ask is:
> first: sling clustering solution has not been tested?

Could you elaborate a little bit on this question? Sling is used and
tested in clustered scenarios.

> I think how in the cluster, the use of the the job mechanism and jackrabbite.
The job mechanism in a jackrabbit cluster works

>
> second: find the JobUtil acknowledgeJob method, reported such an exception:
> JobStatusNotifier context is not available in event properties.
> Context is null, what causes it?
You're calling this method from outside of a job.
The best way of implementing a job is to call
JobUtil.processJob(Event, JobProcessor). Implement the JobProcessor
interface and perform all job tasks in there. Call
JobUtil.processJob() from your event handler method as soon as you get
a job. That's all you have to take care of

Regards
Carsten

>
>
> wangxin  from China



-- 
Carsten Ziegeler
cziegeler@apache.org