LSPE @Yahoo mysql-proxy By Farhad Saberi - Overview and architecture - Making The case for a proxy - Lua - Lua examples - The admin interface - currently known issues
Overview and Architecture Same idea as any other proxy. Sits between the application and its Database:
Overview and Arhitecture Read only Load Balancing with multiple –proxy-read-only-backend-addresses option
Making The case for mysql-proxy Easier sites management.  Hundreds of connection definitions use the same host and port. DB Host connection changes are done at one place only.
No need to restart for configuration or behavioral changes. It all happens in real time.
Making the case for mysql-proxy Flexible, Powerful and invisible: intercept, tokenize and modify queries
Deny/allow queries based on DB or DB User.
Deny/allow based on a regex
Construct your own results set and return it to the application without ever actually querying the backend database.
LUA embedded
Making the case for a proxy It's fast and stable: Small daemon, about 35 MB in VSZ compared to a preforked apache child being 50 to 100 MB.
Coded in C
implements connection pooling
Doesn't need to do NS lookups every time
Has never “crashed” on me so far!
Making the case for mysql-proxy Open source.
LUA Simple scripting language
Small: its whole distribution fits in a floppy disk.
Extensible; it is easy to interface with C code.
LUA Widely used in games:

Mysql proxy presentation_yahoo