Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-77827

DB Upgrade Client: in case of exception, upgrade commands of gogo console doesn't display stacktrace

    Details

      Description

      DB Upgrade Client: in case of exception, upgrade commands of gogo console:

      • upgrade:execute
      • upgrade:executeAll
        doesn't display stacktrace

      For more information about upgrade process, see: https://dev.liferay.com/discover/deployment/-/knowledge_base/7-0/running-the-upgrade-process

      Steps to reproduce

      1. Install Liferay 6.2
      2. Create a webcontent using basic structure
      3. Stop Liferay 6.2
      4. In order to cause an error during upgrade, execute following sql update in 6.2 database (in this case we can use an direct SQL because we just want to demonstrate that our way to print log does not work prperly):
        update JournalArticle set content=''
        
      5. Install Liferay 7.0
      6. Create a file called com.liferay.portal.upgrade.internal.configuration.ReleaseManagerConfiguration.cfg in LIFERAY_HOME/osgi/configs/
      7. Add autoUpgrade=false inside of previous created file
      8. Go to LIFERAY_HOME/tools/portal-tools-db-upgrade-client
      9. Execute upgrade: java -jar com.liferay.portal.tools.db.upgrade.client.jar
      10. Wait until core upgrade is executed and gogo shell is open
      11. Execute upgrade:executeAll
      12. After all commands are executed, execute again: upgrade:execute com.liferay.journal.service
        • Expected behavior: Full stacktrace is printed
        • Wrong behavior: Only first line of exception is printed
          gogo: RuntimeException: com.liferay.portal.kernel.upgrade.UpgradeException: com.liferay.portal.kernel.xml.DocumentException: Error on line -1 of document  : Premature end of file. Nested exception: Premature end of file.
          

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                raven.song Raven Song
                Reporter:
                jorge.diaz Jorge Diaz
                Participants of an Issue:
                Recent user:
                Csaba Turcsan
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  1 year, 40 weeks, 2 days ago

                  Packages

                  Version Package
                  7.0.0 DXP FP40
                  7.0.0 DXP SP7
                  7.0.5 CE GA6
                  7.0.X
                  7.1.0 M1
                  7.1.X
                  Master