Project title SQL::Translator rewrite
I will rewrite/refactor SQL::Translator. Over time, SQL::Translator has seen the addition of modules from varying developers, leaving an inconsistent API and coding style. The test coverage also leaves something to be desired and makes development difficult. I will implement a consistent API and coding style as w ell as extend the test suite.
Benefits to the Perl/Open Source Community
When completed, the SQL::Translator rewrite will have restructured the codebase so that it is easier to test. This combined with more introspectable code will provide the base for better uptake within the community. Additionally, a cleaner codebase will provide better opportunities for plugin development, allo wing for support of rare SQL dialects. It will also make cross-DBMS schema porting easier, resulting in easier provability.
The SQL::Translator rewrite will also be done with the help of Moose, which has become the de facto choice for Perl OODeliverables
- Provide code/API consistency
Provide code that is in the modern perl style, has a unified API that is extension friendly
- Provide better/complete test coverage
With comprehensive tests, changes to core/module code could be done easier and with fewer if n o regressions.
- unify the column types between different DBMSs
DBI provides a list of constants for all the ansi defined column types, so it will us e that, rather than doing a translation on the arbitrary column type string, as this can vary from DBMS to DBMS. This will greatly simplify the producers (pa rt that outputs DML), as they will only deal with a single mapping, no one for each potential DBMS.
SQL::Translator has grown organically over the years and parts of the current code base can be fragile and lack uniformity. A fresh start can be used to reso lve this.
I will start with discussing an API with DBIx::Class users and the current SQL::Translator mailing list, then porting across all the existing Parse::RecDecen t parsers since they work and a lot of time has gone into them.
Then, I will create a schema object layer, where the parsed data is stored in object form (indexes, tables, fields, triggers, constraints etc)
Finally, I will write producers that will use the schema object layer to output DDL.
Preparation, Apr 20th to May 22nd
First phase, May 23rd to July 13th
port API over existing Parse::RecDecent parsers, create schema object layer
Second phase, July 14th to August 17th
complete schema object layer, write producers
Ash Berlin <firstname.lastname@example.org>
Matt S Trout <email@example.com>
You may distribute this code under the same terms as Perl itself.
Bio I am a 26 year old student and perl developer located in the United States. I utilize and contribute to many perl open source projects (netdisco, SNMP::Info, DBIx::Class, SQL::Abstract, Catalyst).
While I am not directly familiar with SQL::Translator itself, I am very familiar with SQL::Abstract, DBIx::Class (which makes heavy use of SQL::Translator), and SQL DML/DDL. I have also patched/refactored large portions of SQL::Abstract previously.
I am currently a part-time student at Arizona State University and can provide documentation upon request.