Hi,
Yes, someday, hopefully, MariaDB can get transactional DDL.
I want to make a good case for a pluggable parser, so I am going to briefly describe the tools I write and how they could benefit from one.
I need a pluggable parser or at the least, table functions(which can return more than one column) for Shard-Query, which provides transparent sharding, parallel query, and window functions. Shard-Query puts a lot of work into rewriting a query. I does things like semijoin materialization, after all how else could a semijoin work on a sharded data set? Shard-Query is much more powerful than Spider for reads, though spider is probably better for writes. There is no reason they couldn't work together. Shard-Query can be called from a stored procedure wrapping gearman UDF, but I would MUCH prefer if I could implement the logic in the server for parallel query. This is something that MariaDB really needs and it would set it apart from MySQL in a major way. Much of the work on Shard-Query was done in cooperation with an employee of the Ericsson corporation, which was (and still is to my knowledge) used for analysis and billing of cell phone charges. One of the changes for ericsson was pluggable aggregate functions like percentile. Another prerequisite for putting parallel query in the database is the unified interface for running SQL in the server (there is an MDEV for it). Basically I envision a parser plugin which would rewrite the query internally to each partition, each query being an insert into one temporary table. Once all inserts complete the query will be rewritten to use the temp table and sent through the normal query pipeline where the results will be sent to the end user, and a deinit function will happen to drop the temporary table and free up any memory that was allocated, etc.
I also need the pluggable parser for Flexviews, which implements incrementally refreshable materialized views. It includes FlexCDC, a complete change data capture tool that supports ALTER TABLE and that supports plugins, so you can replicate to other systems or send rows to a message queue. FlexCDC processes the binary log and inserts data into log tables. The log tables are then used to refresh the views. Joins and all major aggregate functions are supported and it is in use in production in major internet properties. Flexviews needs a pluggable parser to rewrite queries to access the views transparent. FlexCDC could be rewritten as a daemon plugin which acts as a replication slave inside the database. The pluggable parser could support CREATE MATERIALIZED VIEW.
I think these are good cases for a pluggable parser. Let me know if you have any questions or ideas.
Btw, there are KB articles on both of the tools. I'm going to work up a tutorial for both soon. Let me know if you have questions.
You can find my tools here:
Also, you might find this UDF useful, or a comical abuse of a plugin, or both:
--Justin