没有任何数据可供显示
开源项目社区 | 当前位置 : |
|
www.trustie.net/open_source_projects | 主页 > 开源项目社区 > c5-db-migration |
c5-db-migration
|
1 | 0 | 72 |
贡献者 | 讨论 | 代码提交 |
Latest Version: 0.9.9-m3 (check out the new check goal!)
OverviewThe Carbon Five Database Migration framework and Maven plugin for Java provides a simple solution to the problem of managing discrete, incremental changes to databases over time across multiple environments. Each migration is versioned and tracked when applied to the database. Sensible defaults reduce the amount of necessary configuration, though the framework can be configured and extended. Before this google code page, this framework was announced on our Community Blog.
Key Maven Plugin Goals
Goal Description db-migration:createCreate a new, empty database db-migration:migrateApply all pending migrations db-migration:resetDrop the existing database, create a new one, and apply all pending migrations db-migration:newCreate a new, empty migration script db-migration:checkCheck for pending migrations, fail the build if the db is not up to date
Sample Maven Plugin Configuration...
com.carbonfive.db-support
db-migration-maven-plugin
RELEASE
jdbc:mysql://localhost/myapp_test
dev
dev
mysql
mysql-connector-java
5.1.6
c5-public-repository
http://mvn.carbonfive.com/public
...Other DetailsBy default, migrations are loaded from the directory src/main/db/migrations and follow the naming convention yyyymmddhhmmss_some_description.sql. Version history is stored in the database in the schema_version table, which captures the version, date-applied, and how long it took for the migration to execute for each applied migration.
Supported DatabasesAll functionality is supported for MySQL, PostgreSQL, MS SQL Server, HSQL, and H2Database, though the migrate functionality is likely to work with many other database systems. Create/drop/reset are less likely to work out of the box. Our goal is to support all of the major database systems and we're eager to hear how it works with other systems.
DocumentationCheck out the Maven Plugin Guide if you're interested in manually triggering database updates. If you want to embed the migration framework in your application, check out the Application Embedding Guide.