Uploaded image for project: 'Felix'
  1. Felix
  2. FELIX-3946

NullPointerException in BundleServlet.bundleDetails when not called through HTTP

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • webconsole-4.2.0
    • webconsole-4.2.0
    • Web Console
    • None

    Description

      With the introduction of the Inventory bundle and the migration of ConfigurationStatusPrinter to InventoryPrinter, these services may be called through other channels than through the Web Console over HTTP.

      Thus the appRoot and pluginRoot parameters to the BundleServlet.writeJSON method may be null and therefore the following code in the bundleDetails method throws a NullPointerException:

      > bundleInfoDetails(jw, bundle, pluginRoot.substring(0, pluginRoot.lastIndexOf("/")), locale);

      A number of fixes are required:

      • Prevent NPE at this code location
      • Clarify BundleInfoProvider interface that webConsoleRoot may be null
      • Fix ServicesUsedInfoProvider to create VALUE type BundleInfo if webConsoleRoot is null

      Attachments

        Activity

          People

            fmeschbe Felix Meschberger
            fmeschbe Felix Meschberger
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: