Chapter 12: Running Background Work with the Task Queue API and Cron

This chapter introduces the task scheduling mechanisms built into the App Engine. There are two ways to schedule tasks used for different purposes. Cron (the task scheduler) should be used to plan repetitive tasks at fixed times for structural work. The Task Queue can be used to execute tasks without making the end user wait for them. This chapter starts with the Task Queue API before introducing cron tasks. At the end of the chapter, both ways of scheduling come together for the App Engine–specific HTTP headers passed to task servlets.

Task Queuing

The task queuing mechanism is a key part of the Google App Engine for at least three reasons. First, and most important, it improves ...

Get Essential App Engine: Building High-Performance Java Apps with Google App Engine now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.