Uploaded image for project: 'CloudStack'
  1. CloudStack
  2. CLOUDSTACK-6472

listUsageRecords generates NPEs for expunging instances

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 4.3.0
    • 4.4.0, 4.3.1
    • Management Server, Usage
    • Security Level: Public (Anyone can view this level - this is the default.)
    • None
    • linux

    Description

      The listUsageRecords API command, pulls down the list of usage records in the cloud_usage database and augments records with information pulled from the cloud database.

      When dealing with instance records, only instances which are do not have a value for the removed field are considered. Unfortunately, since the output of _entityMgr.findById is not checked this means that Null Pointer Exceptions are generated when trying to access the output for expunged VMs.

      The attached patch fixes the issue and applies a similar fix for other similar cases.

      Attachments

        1. 0001-handle-removed-entities.patch
          7 kB
          Pierre-Yves Ritschard

        Issue Links

          Activity

            People

              Unassigned Unassigned
              pyritschard Pierre-Yves Ritschard
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: