MariaDB uses '@@system_versioning_alter_history = 1' now. Removed obsolete "lock tables" statements

This commit is contained in:
Roland Praml committed 2022-03-14 14:01:21 +01:00
1 parent 10c01574d2
commit d629fb2dbd
14 files changed
+39 -62

No files matched your search

@@ -2,11 +2,9 @@ package misc.migration.v1_1;
import io.ebean.annotation.DbDefault;
import io.ebean.annotation.DbMigration;
import io.ebean.annotation.History;
import io.ebean.annotation.HistoryExclude;
import io.ebean.annotation.NotNull;
import io.ebean.annotation.Platform;
import javax.persistence.Entity;
import javax.persistence.Id;
@@ -22,13 +20,6 @@ public class EHistory2 {
Integer id;
@NotNull
// see: https://mariadb.com/de/resources/blog/use-cases-for-mariadb-data-versioning/
@DbMigration(preAlter = {
"SET @@system_versioning_alter_history = 1",
"update ${table} set ${column} = 'unknown' where ${column} is null"}, platforms = Platform.MARIADB)
// other platforms
@DbMigration(preAlter = "update ${table} set ${column} = 'unknown' where ${column} is null")
@DbDefault("unknown")
String testString;