Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-46634

LockInfo results missing a layer of hierarchy

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 4.7.0
    • Internal Code
    • None
    • Fully Compatible
    • ALL
    • Dev Tools 2020-03-09, Dev Tools 2020-03-23

    Description

      It's obvious we're missing a layer of hierarchy in the structure.

      The group of repeating keys (resourceId,granted,pending) should instead be the keys of a subobject created for each lock in the bucket.

      existing (bad) format:

           // add an element to result object:
            //     "lockInfo": [
            //         // for each nonempty bucket in LockManager, add a suboject.
            //         {
            //             "resourceId": <string>,
            //             "granted": [ {}, ... ],  // array of lock requests
            //             "pending": [ {}, ... ],  // array of lock requests
            //
            //             // this triple of repeated keys are used to represent each lock in a bucket
            //             "resourceId": <string>,
            //             "granted": [ {}, ... ],  // array of lock requests
            //             "pending": [ {}, ... ],  // array of lock requests
            //
            //             ...
            //         },
            //         ...
            //     ]
      
      

      Attachments

        Issue Links

          Activity

            People

              billy.donahue@mongodb.com Billy Donahue
              billy.donahue@mongodb.com Billy Donahue
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: