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

HttpMonitor doesn't check JSON responses for response-text

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved (View Workflow)
    • Major
    • Resolution: Fixed
    • 1.6.2
    • None
    • Security Level: Default (Default Security Scheme)
    • Operating System: All
      Platform: PC
    • 3124

    Description

      The HttpMonitor does not correctly check JSON repsonses for response-text. I don't know if you're checking Content-Type headers or what, but it fails when the content is application/json. Here's the poller debug log:

      2009-04-17 01:14:22,170 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: Port = 8882, Address = /10.0.0.68, timeout: 6000ms retry: 0 of 3
      2009-04-17 01:14:22,170 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: HttpMonitor: connected to host: /10.0.0.68 on port: 8882
      2009-04-17 01:14:22,170 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: determineServerResponse: valid server response: 200 found.
      2009-04-17 01:14:22,170 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: poll: response= HTTP/1.1 200 OK
      2009-04-17 01:14:22,171 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: poll: responseTime= 0.946ms
      2009-04-17 01:14:28,171 INFO [PollerScheduler-15 Pool-fiber14] HttpMonitor: checkStatus: did not connect to host with timeout: 6000ms retry: 0 of 3
      2009-04-17 01:14:28,172 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: HttpMonitor: connected to host: /10.0.0.68 on port: 8882
      2009-04-17 01:14:28,173 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: determineServerResponse: valid server response: 200 found.
      2009-04-17 01:14:28,173 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: poll: response= HTTP/1.1 200 OK
      2009-04-17 01:14:28,173 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: poll: responseTime= 1.464ms
      2009-04-17 01:14:34,173 INFO [PollerScheduler-15 Pool-fiber14] HttpMonitor: checkStatus: did not connect to host with timeout: 6000ms retry: 1 of 3
      2009-04-17 01:14:34,174 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: HttpMonitor: connected to host: /10.0.0.68 on port: 8882
      2009-04-17 01:14:34,174 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: determineServerResponse: valid server response: 200 found.
      2009-04-17 01:14:34,174 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: poll: response= HTTP/1.1 200 OK
      2009-04-17 01:14:34,174 DEBUG [PollerScheduler-15 Pool-fiber14] HttpMonitor: poll: responseTime= 0.947ms

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              richard@mochimedia.com Richard Hesse (Inactive)
              Votes:
              1 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: