Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
liquibase integration
Java HTML Shell
Branch: master
Pull request Compare This branch is 16 commits ahead, 1 commit behind 7uc0:master.

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
conf
documentation/manual
src
test/play/modules/liquibase
tests/testchangelog
.gitignore
README.textile
build.properties
build.sh
build.xml

README.textile

Liquibase Module

You never develop code without version control, why do you develop your database without it ?™

Liquibase (http://www.liquibase.org) is a simple, reliable and elegant solution for database refactoring management. It comes with main features :

  • multi dabase support (SGBDR)
  • structural / data changeset
  • safety check (on md5sum basis)
  • safety database upgrade process (cluster is liquibase friend)
  • contexts execution filter (you Player know what I’m talking about)
  • automation tooling provided (ant / servlet, and now PlayFramework !)

Liquibase module differs from Migrate module for the main following reason :

Database changes follow application changes just the same way source code does

Getting started

Bundle changelog files within your Play application (see example),

Add liquibase dependency to your Play application

# Additional modules
# ~~~~~
# A module is another play! application. Add a line for each module you want
# to add to your application. Module paths are either absolutes or relative to
# the application root.
module.liquibase=${play.path}/modules/liquibase

Configuration

First version configuration options are the following :

liquibase.active=true/false
liquibase.changelog=changelog_path (classpath loaded)
liquibase.properties=properties_path (classpath loaded)
liquibase.contexts=ctxt1[,ctx2]

More features (hosts execution filter, underlying database changelog structure visualization…) to come

Example

Changeset files / properties can be jared and integrated – thus versioned – as 3rd party libs, at module / application level, just the same way jdbc drivers are.

One may also handle changeset at the same level as domainmodel declaration – that’s what we do at GdTeam -, within dedicated module/application, using play module dependency mechanism to create modular app.
Modules archives are still built and maintained against 3rd party repository such as nexus / archiva / artifactory, and then released agains private / public play module repository (see http://code.google.com/p/play-repo/ for more information)

Something went wrong with that request. Please try again.