|
Project Information
Members
Links
|
Taskr is a stand-alone HTTP daemon, providing a cron-like networked scheduling service. Tasks can be created and managed problematically via REST calls over HTTP allowing other REST-aware services to schedule and manage jobs, or manually via a nice web interface. One common use for Taskr is to schedule jobs to be executed on remote Rails servers. However, Taskr is a far more generic tool, capable of performing a wide range of scheduled actions. Taskr jobs can be as simple as single-line shell commands (similar to cron), but support is built-in for more complex, higher-level actions. For example, Taskr can be used to place a REST call to another RESTful service, such as sending out a timed message via the Howlr RESTful messaging daemon, or it can be used to execute arbitrary code on a remote Ruby on Rails server via the Taskr4rails plugin. Behind the scenes, Taskr is written in Ruby using the Camping framework and uses the OpenWFEru-Scheduler. Screenshot
Taskr's task list shown in the built-in web interface. Installation
gem install taskr sudo taskr mysqladmin -u root -p create taskr Have a look at the Downloads page for further installation and configuration help. UsageTaskr has a simple, self-explanatory web interface. This is by default accessible at http://localhost:7007/tasks. The web interface is meant to be intuitive, although you might want to have a look at BuiltInActionTypes for info on the kinds of actions Taskr can be scheduled to execute. If you're interested in interacting with Taskr programmatically (i.e. via its REST API), have a look at the Documentation section below. Once you have Taskr configured, you will probably want to run it as a background daemon. This is done using the taskr-ctl script: taskr-ctl start taskr-ctl status taskr-ctl stop You can use taskr-ctl to incorporate Taskr into your system as a background service. On Linux for example, you'll want to create an init.d script; have a look at HowToInstallAsaService. If you encounter errors like "could not obtain a database connection within 5 seconds. The max pool size is currently 5; consider increasing it.", try adding the pool parameter to your database connection config. As a rule of thumb, your pool may need to be at least as big as the maximum number of tasks that are scheduled to execute simultaneously: database: pool: 10 DocumentationFor information about talking to Taskr as a REST web service, have a look at the API and at sample client code for Ruby and PHP. You'll also probably be interested in the BuiltInActionTypes and their parameters. For integration with Rails (i.e. executing remote code on Rails applications) see Taskr4rails. |