Uploaded image for project: 'OpenNMS'
  1. OpenNMS
  2. NMS-12505

api/v2/ifservices endpoint does not expose ID and IpInterface in JSON results

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 25.1.2
    • Fix Version/s: 25.2.1
    • Component/s: REST
    • Security Level: Default (Default Security Scheme)
    • Labels:
      None
    • Sprint:
      Horizon 2020 - Feb 5th

      Description

      When querying /api/v2/ifservices as JSON, the returned services do not contain the IP interface. The XML version exposes them using their ID.

      The XML version:

      <service down="false" status="A" statusLong="Managed" id="183572">
        <applications/>
        <ipInterfaceId>183565</ipInterfaceId>
        <lastFail>2020-01-28T08:56:56.512+01:00</lastFail>
        <lastGood>2020-01-28T15:12:44.492+01:00</lastGood>
        <serviceType id="16">
          <name>Update</name>
        </serviceType>
      </service>
      

      The JSON version:

      {
        "source": null,
        "qualifier": null,
        "status": "A",
        "notify": null,
        "down": false,
        "lastGood": 1580220768781,
        "lastFail": 1579157858872,
        "statusLong": "Managed",
        "serviceType": {
          "id": 16,
          "name": "Update"
        },
        "applications": []
      },
      

      Also, the ID of the service itself is missing.

        Attachments

          Activity

            People

            Assignee:
            cpape Christian Pape
            Reporter:
            fooker Dustin Frisch
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: