Foreign key constraints should not be created for AccessRulesData and AdminEntityData (from AdminGroupData). These tables are no longer used (except for reading data to upgrade), so they will be empty. Hence it does not make sense to create foregin key contraints on them. Note that you get the error even with empty tables
Figure out why Hibernate is creating foreign key constraints on these tables and disable this, without breaking backwards compatibility and preferably in a standard JPA way.
The motivation for fixing this is that Hibernate is showing a lot of "alter table X add constraint Y" error messages when running an import with the DB CLI.
Note: Currently the error message is disabled in the log4j-cli.xml file. See