pluggable storage engine ver0.0.1
できた。まだ何のpatchも移植してないのでSenna検索できないけど。
[test]> install plugin tritonn soname 'libtritonn_engine.so'; Query OK, 0 rows affected (0.00 sec) [test]> show engines; +------------+---------+--------------------------------------------------------------------+--------------+-----+------------+ | Engine | Support | Comment | Transactions | XA | Savepoints | +------------+---------+--------------------------------------------------------------------+--------------+-----+------------+ | Tritonn | YES | MyISAM engine enchanced with Senna embedded fulltext search engine | NO | NO | NO | | MRG_MYISAM | YES | Collection of identical MyISAM tables | NO | NO | NO | | BLACKHOLE | YES | /dev/null storage engine (anything you write to it disappears) | NO | NO | NO | | CSV | YES | CSV storage engine | NO | NO | NO | | MEMORY | YES | Hash based, stored in memory, useful for temporary tables | NO | NO | NO | | FEDERATED | YES | Federated MySQL storage engine | NO | NO | NO | | ARCHIVE | YES | Archive storage engine | NO | NO | NO | | InnoDB | YES | Supports transactions, row-level locking, and foreign keys | YES | YES | YES | | MyISAM | DEFAULT | Default engine as of MySQL 3.23 with great performance | NO | NO | NO | +------------+---------+--------------------------------------------------------------------+--------------+-----+------------+ 9 rows in set (0.00 sec) [test]> create table t1 (c1 int primary key auto_increment, c2 int) engine = tritonn; Query OK, 0 rows affected (0.00 sec) [test]> insert into t1 values(null,100); Query OK, 1 row affected (0.00 sec) [test]> insert into t1 values(null,100); Query OK, 1 row affected (0.00 sec) [test]> select * from t1; +----+------+ | c1 | c2 | +----+------+ | 1 | 100 | | 2 | 100 | +----+------+ 2 rows in set (0.00 sec) [test]> show create table t1\G *************************** 1. row *************************** Table: t1 Create Table: CREATE TABLE `t1` ( `c1` int(11) NOT NULL AUTO_INCREMENT, `c2` int(11) DEFAULT NULL, PRIMARY KEY (`c1`) ) ENGINE=Tritonn AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 1 row in set (0.00 sec)
とりあえずこのコードをsourceforgeにcommitして、ちょっとずつ既存のTritonnのコードを移植していこうかな。