Follow up: It looks like it is not just a problem with creation of the audit tables, but also using them.
After trying to create the DB by starting jmix 2.7.2 against an empty DB, I tried to restore the DB from my 8.0 version into MySQL 8.4.x. I was thinking if it was just a problem creating the tables, maybe I can avoid that and restore the tables from the old DB.
Now I get this error when logging in:
2025-12-27T13:07:43.003-05:00 WARN 17304 --- [cTaskExecutor-1] eclipselink.logging.all : Exception [EclipseLink-4002] (Eclipse Persistence Services - 4.0.6-3-jmix.v202511172336-9dc6ae0a264e78253f0d9518d0a389b982412bfa): org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: java.sql.SQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'MANUAL, NAME FROM AUDIT_LOGGED_ENTITY WHERE ((AUTO = 1) OR (MANUAL = 1))' at line 1
Error Code: 1064
Call: SELECT ID, AUTO, CREATE_TS, CREATED_BY, MANUAL, NAME FROM AUDIT_LOGGED_ENTITY WHERE ((AUTO = ?) OR (MANUAL = ?))
bind => [true, true]
Query: ReadAllQuery(referenceClass=LoggedEntity sql="SELECT ID, AUTO, CREATE_TS, CREATED_BY, MANUAL, NAME FROM AUDIT_LOGGED_ENTITY WHERE ((AUTO = ?) OR (MANUAL = ?))")
2025-12-27T13:07:43.004-05:00 WARN 17304 --- [cTaskExecutor-1] io.jmix.audit.impl.EntityLogImpl : Unable to log entity org.myapp.membership.entity.AccessLog-48137 [new,managed], id=48137
jakarta.persistence.PersistenceException: Exception [EclipseLink-4002] (Eclipse Persistence Services - 4.0.6-3-jmix.v202511172336-9dc6ae0a264e78253f0d9518d0a389b982412bfa): org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: java.sql.SQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'MANUAL, NAME FROM AUDIT_LOGGED_ENTITY WHERE ((AUTO = 1) OR (MANUAL = 1))' at line 1
Error Code: 1064
Call: SELECT ID, AUTO, CREATE_TS, CREATED_BY, MANUAL, NAME FROM AUDIT_LOGGED_ENTITY WHERE ((AUTO = ?) OR (MANUAL = ?))
bind => [true, true]
Query: ReadAllQuery(referenceClass=LoggedEntity sql="SELECT ID, AUTO, CREATE_TS, CREATED_BY, MANUAL, NAME FROM AUDIT_LOGGED_ENTITY WHERE ((AUTO = ?) OR (MANUAL = ?))")
at org.eclipse.persistence.internal.jpa.QueryImpl.getDetailedException(QueryImpl.java:392) ~[org.eclipse.persistence.jpa-4.0.6-3-jmix.jar:na]
at org.eclipse.persistence.internal.jpa.QueryImpl.executeReadQuery(QueryImpl.java:265) ~[org.eclipse.persistence.jpa-4.0.6-3-jmix.jar:na]
at org.eclipse.persistence.internal.jpa.QueryImpl.getResultList(QueryImpl.java:483) ~[org.eclipse.persistence.jpa-4.0.6-3-jmix.jar:na]
at io.jmix.eclipselink.impl.JmixEclipseLinkQuery.getResultFromCache(JmixEclipseLinkQuery.java:845) ~[jmix-eclipselink-2.7.2.jar:na]
at io.jmix.eclipselink.impl.JmixEclipseLinkQuery.getResultList(JmixEclipseLinkQuery.java:139) ~[jmix-eclipselink-2.7.2.jar:na]
at io.jmix.audit.impl.EntityLogImpl.lambda$loadEntities$10(EntityLogImpl.java:346) ~[jmix-audit-2.7.2.jar:na]
at org.springframework.transaction.support.TransactionOperations.lambda$executeWithoutResult$0(TransactionOperations.java:68) ~[spring-tx-6.2.14.jar:6.2.14]
at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:140) ~[spring-tx-6.2.14.jar:6.2.14]
at org.springframework.transaction.support.TransactionOperations.executeWithoutResult(TransactionOperations.java:67) ~[spring-tx-6.2.14.jar:6.2.14]
at io.jmix.audit.impl.EntityLogImpl.loadEntities(EntityLogImpl.java:342) ~[jmix-audit-2.7.2.jar:na]
at io.jmix.audit.impl.EntityLogImpl.getLoggedAttributes(EntityLogImpl.java:316) ~[jmix-audit-2.7.2.jar:na]
at io.jmix.audit.impl.EntityLogImpl.registerCreate(EntityLogImpl.java:398) ~[jmix-audit-2.7.2.jar:na]
at io.jmix.audit.impl.EntityLogImpl.onEntityChange(EntityLogImpl.java:143) ~[jmix-audit-2.7.2.jar:na]