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

ScopedConfigurationManager configurations aren't reloaded



      Initially, from ConfigurationBeanManagedService, we use as bundleContext the bundle that registers the managed service, as for now: com.liferay.portal.configuration.settings. That bundle location is used by the ConfigurationManager to assign the configuration location.

      When the ConfigurationManager handles a configuration update it fires a CM_UPDATED event. In an async way the ComponentRegistry gets notified from the UpdateThread and starts to check if every component holder (in the specific case of the ticket CheckArticleMessageListener) should be notified. To check so there is an exact comparison performed between CheckArticleMessageListener module (com.liferay.journal.web) location and com.liferay.portal.configuration.settings.jar, and because there isn't a match the component isn't notified:

      private boolean checkBundleLocation(String configBundleLocation, Bundle bundle)
          boolean result;
          if ( configBundleLocation == null )
              result = true;
          else if ( configBundleLocation.startsWith( "?" ) )
              result = bundle.hasPermission(new ConfigurationPermission(
                  configBundleLocation, ConfigurationPermission.TARGET ) );
              result = configBundleLocation.equals( bundle.getLocation() );
          return result; // later means notify or not



      Steps to Repduce:

      1. Create a com.liferay.journal.configuration.JournalServiceConfiguration.config file in osgi/configs folder adding, as single line, the following: checkInterval="1"
      2. Start the portal.
      3. Navigate to Control Panel > Configuration > System Settings > Web Content and select Web Content from under VIRTUAL INSTANCE SCOPE.
      4. Check that the field "Check Interval" value is set to "1".
      5. From Content > Web Content create a basic web content and schedule it to be published in a few minutes.
      6. Refresh the page where the content is scheduled.

      Expected Results:
      The web content should be published within 1 minute of its display date.

      Actual Results:
      A period of time up to 15 minutes is passed before the web content is published.




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


              • Created:
                Days since last comment:
                1 year, 10 weeks, 3 days ago


                Version Package