Fixed AWC-1254: Schema changes run in auto-commit mode without rollback.

Some databases support transactional changes of the schema, but most don't.
Some don't update the schema metadata until the transaction ends.
To workaround all of these issues, a lock table is created at the beginning of the schema bootstrap
and removed afterwards.  Each statement is executed in auto-commit mode.  If there is a failure,
there is no alternative but to revert to the original data and try again.


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6215 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2007-07-11 23:20:47 +00:00
parent edd333a029
commit 9cd707b76f
2 changed files with 111 additions and 16 deletions

View File

@@ -1,5 +1,6 @@
# Schema update messages
schema.update.msg.dialect_used=Schema managed by database dialect {0}.
schema.update.msg.bypassing=Bypassing schema update checks.
schema.update.msg.all_statements=All executed statements written to file {0}.
schema.update.msg.no_changes=No changes were made to the schema.
@@ -7,6 +8,8 @@ schema.update.msg.executing_generated_script=Executing database script {0} (Gene
schema.update.msg.executing_copied_script=Executing database script {0} (Copied from {1}).
schema.update.msg.executing_statement= Executing statement: {0}
schema.update.msg.optional_statement_failed=Optional statement execution failed:\n SQL: {0}\n Error: {1}\n File: {2}\n Line: {3}
schema.update.warn.dialect_unsupported=Alfresco should not be used with database dialect {0}.
schema.update.err.previous_failed=A previous schema upgrade failed. Revert to the original database before attempting the upgrade again.
schema.update.err.statement_failed=Statement execution failed:\n SQL: {0}\n Error: {1}\n File: {2}\n Line: {3}
schema.update.err.update_failed=Schema auto-update failed
schema.update.err.validation_failed=Schema validation failed