upgrade to lr7 (com.liferay.journal.service LPS-63245)upgrade to lr7 (com.liferay.journal.service LPS-63245)https://liferay.dev/en/c/message_boards/find_thread?p_l_id=119785333&threadId=823298842024-03-28T12:45:16Z2024-03-28T12:45:16ZRE: upgrade to lr7 (com.liferay.journal.service LPS-63245)Michael Rohlederhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=823414042016-11-13T11:34:12Z2016-11-13T11:34:12ZI debugged this something further:<br /><br />The problem is in ~/modules/apps/web-experience/journal/journal-service/src/main/java/com/liferay/journal/internal/upgrade/v0_0_5/UpgradeJournal.java:addDDMStorageLinks()<br /><br />there this<br /><br />select DDMStructure.structureId, JournalArticle.id_ from JournalArticle inner join DDMStructure on<br />(DDMStructure.groupId in (select distinct Group_.groupId from Group_ where (Group_.groupId = JournalArticle.groupId) or<br />(Group_.companyId = JournalArticle.companyId and Group_.friendlyURL = '/global')) and DDMStructure.structureKey = JournalArticle.DDMStructureKey and JournalArticle.classNameId != 51689);<br /><br />is executed and if there are any duplicate id_ returned (as in my case), the insert of a DDMStorageLink fails, because this id_ gets the classPK for DDMStorageLink which is UNIQUE...<br /><br />If I compare the source of this (7.0.2-ga3) with the current git master source it seems that exactly this is fixed, because in the current master this id_ gets the key of a Map, so it cant be duplicate any more...<br /><br />This means, I have to run the update with the current git master source or wait for the next release.<br /><br />Still, I wonder whats wrong with my data and also, why this thing adds data to DDMStorageLink that is already there?Michael Rohleder2016-11-13T11:34:12Zupgrade to lr7 (com.liferay.journal.service LPS-63245)Michael Rohlederhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=823298832016-11-12T13:04:42Z2016-11-12T13:04:42ZHeya!<br /><br />Im trying to update my data to lr7 (wildfly bundle):<br /><br /><blockquote>g! upgrade:check<br />Dry run upgrade com.liferay.journal.service from 0.0.5-step-6 to 1.0.0 and its dependent modules<br />g! upgrade:execute com.liferay.journal.service<br />INFO - Upgrading com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal<br />INFO - Starting com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal#updateJournalArticles<br />INFO - Completed com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal#updateJournalArticles in 73 ms<br />INFO - Starting com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal#addDDMStorageLinks<br />INFO - Completed com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal#addDDMStorageLinks in 15 ms<br />INFO - Completed upgrade process com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal in 93ms<br />gogo: RuntimeException: com.liferay.portal.kernel.upgrade.UpgradeException: com.liferay.portal.kernel.dao.orm.ORMException: org.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch update<br /></blockquote><br /><br />How to find out what exactly is the problem?<br /><br />This is the same as in issue https://issues.liferay.com/browse/LPS-63245<br /><br />I tried setting "hibernate.show_sql=true" in the portal-ext.properties.<br />I also tried setting the log level of org.hibernate to DEBUG, but still only this in the log file:<br /><br /><blockquote>14:08:59,188 INFO [Thread-138][UpgradeProcess:82] Upgrading com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal<br />14:08:59,190 INFO [Thread-138][LoggingTimer:70] Starting com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal#updateJournalArticles<br />14:08:59,256 INFO [Thread-138][LoggingTimer:38] Completed com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal#updateJournalArticles in 66 ms<br />14:08:59,257 INFO [Thread-138][LoggingTimer:70] Starting com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal#addDDMStorageLinks<br />14:08:59,291 INFO [Thread-138][LoggingTimer:38] Completed com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal#addDDMStorageLinks in 34 ms<br />14:08:59,292 INFO [Thread-138][UpgradeProcess:97] Completed upgrade process com.liferay.journal.inter