Issue
- During an upgrade to newer versions of the portal, warnings like "Attempting to upgrade some table by recreating table due to some reason" may be found in the logs. They can cause confusion and makes one wonder if they will have impact later or can be ignored.
- For example:
2021-03-04 08:40:09.561 WARN [main][UpgradeProcess:400] Attempting to upgrade table DDLRecord by recreating the table due to: Key column 'classPK' doesn't exist in table
Environment
- Any upgrade from one version to a newer one.
Resolution
-
Liferay has a fallback mechanism that is executed when a modification in a database table is needed and cannot be performed by some reason. This mechanism:
- Dumps the table information into the disk.
- Recreates the table with the new defined structure.
- Dumps information of 2. into the database table.
- If it successes, the next message is logged:
2021-03-04 08:40:09.702 WARN [main][UpgradeProcess:419] Successfully recreated and upgraded table DDLRecord
So the warnings can safely be ignored.