Thread: Cron Trigger

    #1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2013
    Posts
    2
    Rep Power
    0

    Cron Trigger


    I want to keep watch on mySQL table in time interval to perform some action on table and i want to use servlet and google app engine.How can i get it?.

    thanks,
    hiren
  2. #2
  3. Contributing User
    Devshed Regular (2000 - 2499 posts)

    Join Date
    May 2004
    Location
    Superior, CO, USA
    Posts
    2,418
    Rep Power
    1713
    There are at two common ways:
    1. Use the ScheduledThreadPoolExecutor to create a task to run. Most likely you'd use the scheduleAtFixedRate method for what you're describing.
    2. Use the Quartz scheduler.


    I like to use Quartz when I need to run something at a particular time - it's a bit easier than calulating it myself. But if you're running something, say, every 5 minutes, then the ScheduledThreadPoolExecutor is plenty sufficient.

IMN logo majestic logo threadwatch logo seochat tools logo