SqueakDBX - GLORP integration
Last updated at 9:21 pm UTC on 19 April 2009
The integration of GLORP with Squeak is completely hardcoded with PostgreSQL driver.
We has stated with the SqueakDBX/Glorp integration. Our intention is to make a refactor over glorp that will permit the background compatibility and support different drivers. So, if you want to use SqueakDBX in an actual Glorp application, it will have no problems. You will be able to replace the native driver with SqueakDBX driver, in a quickly and easy way. We invited Alan Night to have dinner with us when he came to Argentina. We told him our ideas and discuss for a while till we get a first design of this refactor.
This is the classes diagram of GLORP. You can see that Glorp in Squeak, has coupled PostgreSQL native driver, using PGConnection Class into SqueakDatabaseAccesor. PGConnection is a connection class of the Posgres native driver in Squeak.
Our solution is create an abstract layer to uncoupling the native Driver. The Next image is the our refactor to GLORP. You can see, that DatabaseDriver is the new layer charged of this. Then, It has two implementations. First, the native driver implementation (NativePosgresDriver) and second the squeakDBX implementation (SqueakDBXDriver).
For now, we have made the refactor to keep the background compatibility and we have all Glorp Test running successful. We has started with the squeakDBX driver
development and running some test successful with the squeakDBX driver to posgres. The Glorp tests successful are those for running DDL scripts.
We have in mind that we would prefer to finish the SqueakDBX development to PostgreSQL, running all Glorp test successfully and then we will started with others backends link oracle, mysql, MS SQL Server, ODBC and Sqlite.
Through this integration, the squeak and pharo community will hopefully be able to interact with major database engines, such as oracle and mssql, besides those which are open source, like postgresql and mysql. Moreover, by integrating this plugin with GLORP, will allow us to generate a complete and open source solution to relational data base access.