New Event Feature in MySQL 5.1.6
In this article, I'll give a preliminary description of a new MySQL feature for scheduling and executing tasks. In version 5.1.6, MySQL has added support for events. That is, you can now say: "I want the MySQL server to execute this SQL statement every day at 9:30am, until the end of the year" -- or anything similar that involves any number of SQL statements, and a schedule. Note that events are new and still in alpha, so there is still a good chance that we'll have to make adjustments as people experiment with them. This article describes the state of affairs only for the 5.1.6 release of MySQL."
Posted Jan 19, 2006 8:34 UTC (Thu)
by jwb (guest, #15467)
[Link] (3 responses)
I can only assume that somewhere out there exists a version of the cron daemon which stores the crontabs in a MySQL table, making a kind of perfect Escher-like cycle of horror.
Posted Jan 19, 2006 10:59 UTC (Thu)
by nix (subscriber, #2304)
[Link] (2 responses)
'If the time has moved back to {X time somewhere in the past}...'
Posted Jan 26, 2006 1:18 UTC (Thu)
by pimlott (guest, #1535)
[Link] (1 responses)
Posted Jan 26, 2006 20:04 UTC (Thu)
by nix (subscriber, #2304)
[Link]
(er, OK, perhaps not... although I *have* designed a database-backed filesystem sitting atop FUSE which works like this. Now all I have to do is *implement* the damn thing.)
Posted Jan 25, 2006 1:57 UTC (Wed)
by zblaxell (subscriber, #26385)
[Link]
This sounds like something that would be useful to a web hosting customer who has access to CGI and MySQL but nothing else, and wants to get access to cron the next time their ISP upgrades the database without reading the release notes first.
As a MySQL user and paying customer, I know that the top of my wishlist reads "Implement a half-baked buggy featureless version of cron". Thank you MySQL AB for this wonderful contribution to humanity.New Event Feature in MySQL 5.1.6
I have a hideous vision of combining this with PostgreSQL's Point-In-Time Recovery feature.New Event Feature in MySQL 5.1.6
While jwb's post was riotous, the ability to run a query "in the past" would be terribly useful. Imagine you find out today that your database-using application did something wacko yesterday. You want to figure out why, but the data's changed in the meantime. Encoding time-series data yourself is quite tedious, so in a perfect world the DBMS would do it. Of course, this should be an on-line, not recovery, feature.New Event Feature in MySQL 5.1.6
And of course having gone back, changes should lead to the creation of a branch! w00t!New Event Feature in MySQL 5.1.6
While I have built a number of large and small applications with various time-based event scheduling tables stored in an SQL database, including things like triggers that send asynchronous notifications to daemon clients to advise them to re-query for updated schedules, it never in my wildest imaginings occured to me to actually initiate execution autonomously from the database back end.New Event Feature in MySQL 5.1.6