Creating a Database Independent CMS

The CCM persistence layer provides developer level APIs to the database for all services provided by CCM-CMS. The persistence layer shields CMS developers from the specifics of the database thereby allowing them to concentrate on modeling information within the site. One of the unique challenges faced in building the system was the requirment to build a system that is able to run on any transactional SQL database. In order for the persistence layer to be portable, it must know how to handle the different syntaxes and transactional behaviors of each database. It must also abstract away all database specific syntax from the calling java code including all standard SQL operations such as joining tables and filtering and ordering the results while still providing a mechanism to execute custom queries in certain situations. This talk will discuss some of the challenges involved in building such a system from the ground up. It will outline how the system is able to take the definition of an object and automatically generate not only the required SQL to persist the information to the database but also enough information to generate the database schema itself. It will also discuss how developers can manually override actions and how these two features work together, along with a solid object oriented API, to allow the system to be easily ported to work on any transactional SQL database.

Randy Graebner
Red Hat, Inc.
randyg@redhat.com

< Connexions Project - An Open Content Licensing Case Study Culture Shock Therapy: Getting the Suits to Use Your CMS >