Uploaded image for project: 'OpenDJ'
  1. OpenDJ
  2. OPENDJ-7258

Status tool JSON output contains null values

    Details

    • Type: Bug
    • Status: Done
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 6.5.2, 6.5.1, 6.5.0, 6.5.3, 7.0.0
    • Fix Version/s: 7.0.0
    • Component/s: tools
    • Labels:

      Description

      The status tool JSON output contains null values whereas, in JSON, it is recommended not to add a key if the associated value is null.
      Here is an example of the status tool JSON output:

      $ ./opendj/bin/status --offline --script-friendly
      {
        "isRunning" : true,
        "hostname" : "macgrady",
        "adminConnectorPort" : 5444,
        "openConnections" : null,
        "version" : "ForgeRock Directory Services 7.0.0-SNAPSHOT",
        "installPath" : "/Users/cyril/deploy2/opendj",
        "instancePath" : "/Users/cyril/deploy2/opendj",
        "javaVersion" : null,
        "javaVendor" : null,
        "jvmCpus" : null,
        "jvmMaxHeapSizeBytes" : null,
        "connectionHandlers" : [ {
          "name" : "HTTPS",
          "port" : 9443,
          "type" : "HTTP",
          "security" : "SSL",
          "enabled" : true,
          "avgLoadM1Rate" : null,
          "avgLoadM5Rate" : null
        }, {
          "name" : "LDAP",
          "port" : 2389,
          "type" : "LDAP",
          "security" : "STARTTLS",
          "enabled" : true,
          "avgLoadM1Rate" : null,
          "avgLoadM5Rate" : null
        }, {
          "name" : "LDAPS",
          "port" : 2636,
          "type" : "LDAP",
          "security" : "SSL",
          "enabled" : true,
          "avgLoadM1Rate" : null,
          "avgLoadM5Rate" : null
        }, {
          "name" : "LDIF",
          "port" : null,
          "type" : "LDIF",
          "security" : null,
          "enabled" : false,
          "avgLoadM1Rate" : null,
          "avgLoadM5Rate" : null
        }, {
          "name" : "SNMP",
          "port" : 161,
          "type" : "SNMP",
          "security" : null,
          "enabled" : false,
          "avgLoadM1Rate" : null,
          "avgLoadM5Rate" : null
        }, {
          "name" : "Replication port",
          "port" : 9989,
          "type" : "Replication",
          "security" : "NONE",
          "enabled" : true,
          "avgLoadM1Rate" : null,
          "avgLoadM5Rate" : null
        } ],
        "backends" : [ {
          "name" : "dsEvaluation",
          "type" : "DB",
          "enabled" : true,
          "dbCacheSizeBytes" : null,
          "baseDNs" : [ {
            "dn" : "dc=example,dc=com",
            "entryCount" : null,
            "replicationStatus" : null,
            "replicationDelayMs" : null
          } ]
        }, {
          "name" : "monitorUser",
          "type" : "LDIF",
          "enabled" : true,
          "dbCacheSizeBytes" : null,
          "baseDNs" : [ {
            "dn" : "uid=Monitor",
            "entryCount" : null,
            "replicationStatus" : null,
            "replicationDelayMs" : null
          } ]
        }, {
          "name" : "proxyRoot",
          "type" : "Proxy",
          "enabled" : true,
          "dbCacheSizeBytes" : null,
          "baseDNs" : [ {
            "dn" : "ou=myorg,dc=example,dc=com",
            "entryCount" : null,
            "replicationStatus" : null,
            "replicationDelayMs" : null
          }, {
            "dn" : "ou=people,dc=example,dc=com",
            "entryCount" : null,
            "replicationStatus" : null,
            "replicationDelayMs" : null
          }, {
            "dn" : "ou=whatever,dc=example,dc=com",
            "entryCount" : null,
            "replicationStatus" : null,
            "replicationDelayMs" : null
          } ]
        }, {
          "name" : "rootUser",
          "type" : "LDIF",
          "enabled" : true,
          "dbCacheSizeBytes" : null,
          "baseDNs" : [ {
            "dn" : "uid=admin",
            "entryCount" : null,
            "replicationStatus" : null,
            "replicationDelayMs" : null
          } ]
        } ],
        "disks" : [ ]
      } 
      

      This issue can be closed once the script-friendly output of the status tool does not contain null values.

        Attachments

          Activity

            People

            • Assignee:
              miroslav.meca Miroslav Meca
              Reporter:
              cyril.quinton Cyril Quinton
              Dev Assignee:
              Cyril Quinton
              QA Assignee:
              Miroslav Meca
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: