PUBLIC - Liferay Portal Community Edition
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-30469

UpgradePermission fails at startup when upgrade.database.transactions.disabled=true

    Details

    • Branch Version/s:
      6.1.x
    • Fix Priority:
      5
    • Caused by:
      Another improvement
    • Similar Issues:
      Show 3 results 

      Description

      Added check to see if the callback list is empty

      Relevant logs:

      14:11:52,676 INFO  [pool-2-thread-1][UpgradeProcess:177] Upgrading com.liferay.portal.upgrade.v6_0_12_to_6_1_0.UpgradePermission
      14:12:35,995 ERROR [pool-2-thread-1][MainServlet:217] com.liferay.portal.kernel.events.ActionException: com.liferay.portal.kernel.upgrade.UpgradeException: com.liferay.portal.kernel.upgrade.UpgradeException: java.lang.ArrayIndexOutOfBoundsException: -1
      com.liferay.portal.kernel.events.ActionException: com.liferay.portal.kernel.upgrade.UpgradeException: com.liferay.portal.kernel.upgrade.UpgradeException: java.lang.ArrayIndexOutOfBoundsException: -1
      	at com.liferay.portal.events.StartupAction.run(StartupAction.java:58)
      	at com.liferay.portal.servlet.MainServlet.processStartupEvents(MainServlet.java:1306)
      	at com.liferay.portal.servlet.MainServlet.init(MainServlet.java:214)
      	at javax.servlet.GenericServlet.init(GenericServlet.java:160)
      	at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1266)
      	at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1185)
      	at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1080)
      	at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5015)
      	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5302)
      	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
      	at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895)
      	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
      	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
      	at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:649)
      	at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1585)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
      	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      	at java.lang.Thread.run(Thread.java:662)
      Caused by: com.liferay.portal.kernel.upgrade.UpgradeException: com.liferay.portal.kernel.upgrade.UpgradeException: java.lang.ArrayIndexOutOfBoundsException: -1
      	at com.liferay.portal.kernel.upgrade.UpgradeProcess.upgrade(UpgradeProcess.java:183)
      	at com.liferay.portal.upgrade.UpgradeProcessUtil._upgradeProcess(UpgradeProcessUtil.java:103)
      	at com.liferay.portal.upgrade.UpgradeProcessUtil.upgradeProcess(UpgradeProcessUtil.java:56)
      	at com.liferay.portal.upgrade.UpgradeProcessUtil.upgradeProcess(UpgradeProcessUtil.java:36)
      	at com.liferay.portal.events.StartupHelper.upgradeProcess(StartupHelper.java:130)
      	at com.liferay.portal.events.StartupHelperUtil.upgradeProcess(StartupHelperUtil.java:48)
      	at com.liferay.portal.tools.DBUpgrader.upgrade(DBUpgrader.java:147)
      	at com.liferay.portal.events.StartupAction.doRun(StartupAction.java:144)
      	at com.liferay.portal.events.StartupAction.run(StartupAction.java:52)
      	... 20 more
      Caused by: com.liferay.portal.kernel.upgrade.UpgradeException: java.lang.ArrayIndexOutOfBoundsException: -1
      	at com.liferay.portal.kernel.upgrade.UpgradeProcess.upgrade(UpgradeProcess.java:183)
      	at com.liferay.portal.kernel.upgrade.UpgradeProcess.upgrade(UpgradeProcess.java:197)
      	at com.liferay.portal.upgrade.UpgradeProcess_6_0_12_to_6_1_0.doUpgrade(UpgradeProcess_6_0_12_to_6_1_0.java:61)
      	at com.liferay.portal.kernel.upgrade.UpgradeProcess.upgrade(UpgradeProcess.java:180)
      	... 28 more
      Caused by: java.lang.ArrayIndexOutOfBoundsException: -1
      	at java.util.ArrayList.get(ArrayList.java:324)
      	at com.liferay.portal.spring.transaction.TransactionCommitCallbackUtil.registerCallback(TransactionCommitCallbackUtil.java:39)
      	at com.liferay.portal.service.impl.ResourceBlockLocalServiceImpl.updateResourceBlockId(ResourceBlockLocalServiceImpl.java:870)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      	at java.lang.reflect.Method.invoke(Method.java:597)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:122)
      	at com.liferay.portal.spring.aop.ServiceBeanAopProxy.invoke(ServiceBeanAopProxy.java:211)
      	at $Proxy80.updateResourceBlockId(Unknown Source)
      	at com.liferay.portal.service.ResourceBlockLocalServiceUtil.updateResourceBlockId(ResourceBlockLocalServiceUtil.java:701)
      	at com.liferay.portal.upgrade.v6_0_12_to_6_1_0.UpgradePermission.convertResourcePermissions(UpgradePermission.java:71)
      	at com.liferay.portal.upgrade.v6_0_12_to_6_1_0.UpgradePermission.convertResourcePermissions(UpgradePermission.java:98)
      	at com.liferay.portal.upgrade.v6_0_12_to_6_1_0.UpgradePermission.doUpgrade(UpgradePermission.java:146)
      	at com.liferay.portal.kernel.upgrade.UpgradeProcess.upgrade(UpgradeProcess.java:180)
      	... 31 more
      Stopping the server due to unexpected startup errors
      

        Issue Links

          Activity

          Hide
          Michael Saechang added a comment -

          Committed on:
          Portal 6.2.x GIT ID: d4e4ad488826bcc250e33d75fd8462484d098580.

          Show
          Michael Saechang added a comment - Committed on: Portal 6.2.x GIT ID: d4e4ad488826bcc250e33d75fd8462484d098580.
          Hide
          Mark Jin added a comment -

          PASSED Manual Testing using the following steps:

          1. Start 6012 bundle.
          2. Add a bookmark.
          3. Upgrade.

          Reproduced on:
          Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: 2041896544e8193280bba6d75d9a7af2e41af413.

          Can not upgrade. Tomcat throw the error message.

          Fixed on:
          Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: ce1c85a369a14ab5d685432add650aba4929166b.
          Tomcat 7.0 + MySQL 5. Portal 6.2.x GIT ID: 14a70be11e16deaac76199c4ad38f5d55459d714.

          Upgrade to head works well. Unable to see any error message.

          Show
          Mark Jin added a comment - PASSED Manual Testing using the following steps: 1. Start 6012 bundle. 2. Add a bookmark. 3. Upgrade. Reproduced on: Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: 2041896544e8193280bba6d75d9a7af2e41af413. Can not upgrade. Tomcat throw the error message. Fixed on: Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: ce1c85a369a14ab5d685432add650aba4929166b. Tomcat 7.0 + MySQL 5. Portal 6.2.x GIT ID: 14a70be11e16deaac76199c4ad38f5d55459d714. Upgrade to head works well. Unable to see any error message.
          Hide
          Michael Saechang added a comment -

          Thank you Mark for testing. Closing as 'Fixed'.

          Show
          Michael Saechang added a comment - Thank you Mark for testing. Closing as 'Fixed'.

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                2 years, 17 weeks, 3 days ago

                Development

                  Structure Helper Panel