Dashboard > Penrose > Use Cases > MySQL 5.0
MySQL 5.0
Added by Jim Yang, last edited by Jim Yang on Mar 10, 2006  (view change)
Labels: 
(None)


Penrose and MySQL 5.0

One of the new feature of MySQL 5.0 is triggers. Triggers are event-driven stored procedures that are attached to a specific table; the trigger code will fire for any write, even one that occurs on that table.

Paired with a new polling connector from Penrose (starting from 0.9.9 release), it allows a bi-directional synchronization between Penrose cache and MySQL tables.

Create Demo Database;

Populate the sample database by following this setup

Create Database Triggers

Populate the sample database with the triggers SQL script provided in PENROSE_HOME/samples/triggers.sql. Exececute the following commands inside a MySQL client:

use penrose_demo;
source PENROSE_HOME/samples/sql/triggers.sql;

Screencast of two way synchronization

Reference

Site running on a free Atlassian Confluence Open Source Project License granted to Safehaus. Evaluate Confluence today.
Powered by Atlassian Confluence, the Enterprise Wiki. (Version: 2.5.4 Build:#809 Jun 12, 2007) - Bug/feature request - Contact Administrators