Cron Tutorial

2 views
Skip to first unread message

Smola

unread,
Nov 8, 2009, 8:40:18 PM11/8/09
to Google Wave API
I know what a cron job is, I have just never created one. For ANY
platform. Google Wave is a very specific platform and there isn't
much documentation on it (crons with Wave). In the Java API tutorial,
cron jobs are mentioned as being available, but that's all I could
find on them. I have seen some other posts about cron jobs in groups
here and gathered that some lines of code should be added to the
capabilities.xml but I don't know the extent of the attributes I can
use or even how to use the ones I saw in the post (i think there was a
directory for a script? and then a time given that appeared to be an
interval like every 10 seconds).

So my question is this: Is there some documentation I have missed in
terms of cron jobs with wave (for the Java API)? If not, could
someone give a quick run down of their understanding of how this could
be used?

I am also aware that a mechanism is being developed that could replace
the need for cron jobs but I'd still like to familiarize myself with
the cron capabilities. Thanks for your time!

Smola

Austin Chau (Google employee)

unread,
Nov 8, 2009, 9:14:23 PM11/8/09
to google-...@googlegroups.com
We do not have documentation for the current cron setup for robot, due the reason you have mentioned that we are soon replacing it with a more robust mechanism.  In the meanwhile, please check out the sample robot Stocky which uses the current cron setup - 


Essentially you specify your cron spec in the capabilities.xml.  Map a handler to the URL in web.xml - 
<url-pattern>/_wave/robot/fetchupdate</url-pattern>
Austin

hcvst

unread,
Nov 9, 2009, 9:03:32 AM11/9/09
to Google Wave API
Hi Austin,

so cron works again? Last time I checked, my bot was never notified
and all
threads here spoke of cron not working for now (possibly until the new
mechanism
is rolled out).

HC

On Nov 9, 4:14 am, "Austin Chau (Google employee)"
<api.aus...@google.com> wrote:
> We do not have documentation for the current cron setup for robot, due the
> reason you have mentioned that we are soon replacing it with a more robust
> mechanism.  In the meanwhile, please check out the sample robot Stocky which
> uses the current cron setup -
>
> http://google-wave-resources.googlecode.com/svn/trunk/samples/extensi...
>
> <http://google-wave-resources.googlecode.com/svn/trunk/samples/extensi...>Essentially
> you specify your cron spec in the capabilities.xml.  Map a handler to the
> URL in web.xml -
>
> <url-pattern>/_wave/robot/fetchupdate</url-pattern>
>
> Austin
>

Richard Korff

unread,
Nov 9, 2009, 9:19:26 AM11/9/09
to Google Wave API
Austin,

The reference to Stocky, is for education/documentation only,
correct ?
I have read other messages which says that cron does not work at the
moment.

I have tried to do the same as Stocky, but it seems the cron does not
fire.

Also, any idea when the new cron environment is going to be rolled
out ?

Thanks,

Richard

On Nov 9, 10:14 am, "Austin Chau (Google employee)"
<api.aus...@google.com> wrote:
> We do not have documentation for the current cron setup for robot, due the
> reason you have mentioned that we are soon replacing it with a more robust
> mechanism.  In the meanwhile, please check out the sample robot Stocky which
> uses the current cron setup -
>
> http://google-wave-resources.googlecode.com/svn/trunk/samples/extensi...
>
> <http://google-wave-resources.googlecode.com/svn/trunk/samples/extensi...>Essentially
> you specify your cron spec in the capabilities.xml.  Map a handler to the
> URL in web.xml -
>
> <url-pattern>/_wave/robot/fetchupdate</url-pattern>
>
> Austin
>

Austin Chau (Google employee)

unread,
Nov 9, 2009, 2:14:09 PM11/9/09
to google-...@googlegroups.com
The are instabilities around the current cron setup, which is the reason why we w are upgrading to a new mechanism.  I personally have had trouble running crons (I haven't tried it in the last few weeks, I wrote Stocky BTW).  Sorry if this is an inconvenience to you guys, we are trying to push the new stuff as soon as possible.  

Austin

jhouk

unread,
Jan 5, 2010, 4:55:33 PM1/5/10
to Google Wave API
Hi Austin,

Have there been any updates on the cron front in the last couple of
months? I'm also interested in using it but ran into the same problem
Smola did--no docs. I'll try to hack up Stocky if that's our best
resource, but if the new cron system was close to being completed
maybe it would be better to go that route.

Thanks!
--Justin

On Nov 9 2009, 2:14 pm, "Austin Chau (Google employee)"

jhouk

unread,
Jan 8, 2010, 12:19:55 AM1/8/10
to Google Wave API
Hi all,

I've gone ahead and tried to use Stocky's sample code to get Wave to
regularly check back with my robot for updates, but it doesn't seem to
be working. I think I've got everything all set up to log a simple
test message to the AppEngine logs every time Wave connects to my cron
servlet, but I'm not seeing any logs appear. You can see my
capabilities file here:

http://bastion-rm-mgr.appspot.com/_wave/capabilities.xml

and you can see that there's a RobotServlet running at the URL
referenced in the capabilities file (because it sends
a "GET not supported" error message if you type the URL in your
browser:

http://bastion-rm-mgr.appspot.com/_wave/robot/cronUpdate

But I'm only seeing logs print out from my servlet listening on the "/
_wave/robot/jsonrpc" URL, not the cron URL. It looks like the cron
heartbeat isn't firing. Any ideas?

Thanks!
--Justin

On Jan 5, 4:55 pm, jhouk <jsh...@gmail.com> wrote:
> Hi Austin,
>

> Have there been any updates on thecronfront in the last couple of


> months?  I'm also interested in using it but ran into the same problem
> Smola did--no docs.  I'll try to hack up Stocky if that's our best

> resource, but if the newcronsystem was close to being completed


> maybe it would be better to go that route.
>
> Thanks!
> --Justin
>
> On Nov 9 2009, 2:14 pm, "Austin Chau (Google employee)"
>
> <api.aus...@google.com> wrote:

> > The are instabilities around the currentcronsetup, which is the reason why


> > we w are upgrading to a new mechanism.  I personally have had trouble
> > running crons (I haven't tried it in the last few weeks, I wrote Stocky
> > BTW).  Sorry if this is an inconvenience to you guys, we are trying to push
> > the new stuff as soon as possible.
>
> > Austin
>
> > On Mon, Nov 9, 2009 at 6:19 AM, Richard Korff <kor...@gmail.com> wrote:
>
> > > Austin,
>
> > > The reference to Stocky, is for education/documentation only,
> > > correct ?

> > > I have read other messages which says thatcrondoes not work at the
> > > moment.
>
> > > I have tried to do the same as Stocky, but it seems thecrondoes not
> > > fire.
>
> > > Also, any idea when the newcronenvironment is going to be rolled


> > > out ?
>
> > > Thanks,
>
> > > Richard
>
> > > On Nov 9, 10:14 am, "Austin Chau (Google employee)"
> > > <api.aus...@google.com> wrote:

> > > > We do not have documentation for the currentcronsetup for robot, due


> > > the
> > > > reason you have mentioned that we are soon replacing it with a more
> > > robust
> > > > mechanism.  In the meanwhile, please check out the sample robot Stocky
> > > which

> > > > uses the currentcronsetup -

> > > > you specify yourcronspec in the capabilities.xml.  Map a handler to the


> > > > URL in web.xml -
>
> > > > <url-pattern>/_wave/robot/fetchupdate</url-pattern>
>
> > > > Austin
>
> > > > On Sun, Nov 8, 2009 at 5:40 PM, Smola <callmesm...@gmail.com> wrote:
>

> > > > > I know what acronjob is, I have just never created one.  For ANY


> > > > > platform.  Google Wave is a very specific platform and there isn't
> > > > > much documentation on it (crons with Wave).  In the Java APItutorial,

> > > > >cronjobs are mentioned as being available, but that's all I could
> > > > > find on them.  I have seen some other posts aboutcronjobs in groups


> > > > > here and gathered that some lines of code should be added to the
> > > > > capabilities.xml but I don't know the extent of the attributes I can
> > > > > use or even how to use the ones I saw in the post (i think there was a
> > > > > directory for a script? and then a time given that appeared to be an
> > > > > interval like every 10 seconds).
>
> > > > > So my question is this:  Is there some documentation I have missed in

> > > > > terms ofcronjobs with wave (for the Java API)?  If not, could


> > > > > someone give a quick run down of their understanding of how this could
> > > > > be used?
>
> > > > > I am also aware that a mechanism is being developed that could replace

> > > > > the need forcronjobs but I'd still like to familiarize myself with
> > > > > thecroncapabilities.  Thanks for your time!
>
> > > > > Smola

Reply all
Reply to author
Forward
0 new messages