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

Its possible for a NPE to be thrown in SystemCheckOSGiCommands due to Commerce modules being activated randomly in startup with Licensing activation

    Details

    • Type: Bug
    • Status: Closed
    • Resolution: No Longer Reproducible
    • Affects Version/s: Master
    • Fix Version/s: None
    • Component/s: Core Infrastructure
    • Labels:
    • Fix Priority:
      3

      Description

      Description
      It seems that System Check OSGi Commands will check for OSGi dependencies, however the values of the OSGi depdencies are still changing on startup even after

      11:14:14,435 INFO  [main][SystemCheckOSGiCommands:126] Declarative Service Soft Circular Dependency Checker check result: No issues were found.
      11:14:14,436 INFO  [main][SystemCheckOSGiCommands:114] Running "Declarative Service Unsatisfied Component Checker". You can run this by itself with command "ds:unsatisfied" in gogo shell.
      

      This is due to commerce modules being activated on their own due to them being dependent on when the license gets deployed. This is likely a race condition in its own. No known functional impact seems to have yet occured as a result of this

      Steps to Reproduce

      1. Start Liferay with a Commerce License and a Liferay DXP License already in deploy folder
      2. Keep trying with a clean bundle (likely a race condition), or dont try to directly reproduce, it could be a rare race condition

      Expected Result
      No Liferay errors on startup

      Actual Result

      !ENTRY com.liferay.portal.osgi.debug.impl 4 0 2020-09-24 11:14:18.388
      !MESSAGE bundle com.liferay.portal.osgi.debug.impl:3.0.5 (1281)[com.liferay.portal.osgi.debug.internal.osgi.commands.SystemCheckOSGiCommands(3196)] : The activate method has thrown an exception
      !STACK 0
      java.lang.NullPointerException
      	at org.apache.felix.scr.impl.ComponentRegistry.getComponentHolders(ComponentRegistry.java:360)
      	at org.apache.felix.scr.impl.runtime.ServiceComponentRuntimeImpl.getComponentDescriptionDTOs(ServiceComponentRuntimeImpl.java:76)
      	at com.liferay.portal.osgi.debug.declarative.service.internal.UnsatisfiedComponentUtil._collectUnsatisfiedInformation(UnsatisfiedComponentUtil.java:50)
      	at com.liferay.portal.osgi.debug.declarative.service.internal.UnsatisfiedComponentUtil._listUnsatisfiedComponents(UnsatisfiedComponentUtil.java:105)
      	at com.liferay.portal.osgi.debug.declarative.service.internal.UnsatisfiedComponentUtil.listUnsatisfiedComponents(UnsatisfiedComponentUtil.java:38)
      	at com.liferay.portal.osgi.debug.declarative.service.internal.DeclarativeServiceUnsatisfiedComponentSystemChecker.check(DeclarativeServiceUnsatisfiedComponentSystemChecker.java:34)
      	at com.liferay.portal.osgi.debug.internal.osgi.commands.SystemCheckOSGiCommands._check(SystemCheckOSGiCommands.java:117)
      	at com.liferay.portal.osgi.debug.internal.osgi.commands.SystemCheckOSGiCommands.activate(SystemCheckOSGiCommands.java:74)
      

      Testray Link
      https://testray.liferay.com/home/-/testray/case_results/1293993347

      Liferay Log
      https://testray.liferay.com/reports/production/logs/test-1-1/1600941511591/test-portal-release/2534/functional-bundle-tomcat-db2111-jdk8/12/0/liferay-log.txt.gz

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              support-lep@liferay.com SE Support
              Reporter:
              kyle.miho Kyle Miho
              Participants of an Issue:
              Recent user:
              Tina Tian
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Days since last comment:
                37 weeks, 6 days ago

                  Packages

                  Version Package