Details
-
Bug
-
Status: Resolved
-
Blocker
-
Resolution: Fixed
-
1.4.0
-
None
-
None
Description
See FINERACT-932 for general background; I'm currently seeing this in logs of https://www.fineract.dev, and it's preventing upgrading the demo to recently merged PRs:
Caused by: java.sql.SQLException: Field 'version_rank' doesn't have a default value at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException (SQLError.java:129) at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException (SQLError.java:97) at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException (SQLExceptionsMapping.java:122) at com.mysql.cj.jdbc.ClientPreparedStatement.executeInternal (ClientPreparedStatement.java:953) at com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdateInternal (ClientPreparedStatement.java:1092) at com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdateInternal (ClientPreparedStatement.java:1040) at com.mysql.cj.jdbc.ClientPreparedStatement.executeLargeUpdate (ClientPreparedStatement.java:1347) at com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdate (ClientPreparedStatement.java:1025) at org.flywaydb.core.internal.jdbc.JdbcTemplate.update (JdbcTemplate.java:331) at org.flywaydb.core.internal.schemahistory.JdbcTableSchemaHistory.doAddAppliedMigration (JdbcTableSchemaHistory.java:163) at org.flywaydb.core.internal.schemahistory.SchemaHistory.addAppliedMigration (SchemaHistory.java:163) at org.flywaydb.core.internal.command.DbMigrate.doMigrateGroup (DbMigrate.java:384) at org.flywaydb.core.internal.command.DbMigrate.access$200 (DbMigrate.java:54) at org.flywaydb.core.internal.command.DbMigrate$3.call (DbMigrate.java:282) at org.flywaydb.core.internal.jdbc.TransactionalExecutionTemplate.execute (TransactionalExecutionTemplate.java:66) at org.flywaydb.core.internal.command.DbMigrate.applyMigrations (DbMigrate.java:279) at org.flywaydb.core.internal.command.DbMigrate.migrateGroup (DbMigrate.java:244) at org.flywaydb.core.internal.command.DbMigrate.access$100 (DbMigrate.java:54) at org.flywaydb.core.internal.command.DbMigrate$2.call (DbMigrate.java:162) at org.flywaydb.core.internal.command.DbMigrate$2.call (DbMigrate.java:159) at org.flywaydb.core.internal.database.mysql.MySQLNamedLockTemplate.execute (MySQLNamedLockTemplate.java:60) at org.flywaydb.core.internal.database.mysql.MySQLConnection.lock (MySQLConnection.java:161) at org.flywaydb.core.internal.schemahistory.JdbcTableSchemaHistory.lock (JdbcTableSchemaHistory.java:140) at org.flywaydb.core.internal.command.DbMigrate.migrateAll (DbMigrate.java:159) at org.flywaydb.core.internal.command.DbMigrate.migrate (DbMigrate.java:137) at org.flywaydb.core.Flyway$1.execute (Flyway.java:199) at org.flywaydb.core.Flyway$1.execute (Flyway.java:159) at org.flywaydb.core.Flyway.execute (Flyway.java:530) at org.flywaydb.core.Flyway.migrate (Flyway.java:159) at org.apache.fineract.infrastructure.core.service.TenantDatabaseUpgradeService.upgradeAllTenants (TenantDatabaseUpgradeService.java:80)
The "trigger" seems to have been the merge of fynmanoj's https://github.com/apache/fineract/pull/769 for FINERACT-893 by avikg (avikganguly ? avikganguly010 ??) but the core_db/V358__fixed_deposit_rollover_transfer.sql from that PR is unlikely to have caused this?
Field version_rank which doesn't have a default value appears to be in (Flyway's own!) schema_version table, defined in https://github.com/apache/fineract/blob/develop/fineract-db/mifospltaform-tenants-first-time-install.sql ... so is this an impact of and related to FINERACT-979 / FINERACT-810 ? (Perhaps that PR above was just the first time that we merged a PR with a schema migration after the Flyway upgrade?)
I haven't been able to locally reproduce this though.
Attachments
Issue Links
- blocks
-
FINERACT-932 Parent Issue for Error Logs seeing during "normal" usage (e.g. on fineract.dev)
- Open
- links to