Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-8967

Use status endpoint to determine if puppetserver is reachable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: PUP 6.0.0
    • Component/s: DOCS
    • Labels:
      None
    • Release Notes:
      Bug Fix
    • Release Notes Summary:
      When the agent is configured with a list of servers (via server_list), it will now request server status from the "status" endpoint instead of the "node" endpoint.
    • QA Risk Assessment:
      Needs Assessment

      Description

      When the agent has a server_list it makes a node request to find the first available server. The node request will cause a puppetdb query to retrieve node and fact information, which is expensive and unnecessary. It would be better to just hit the puppetserver /status/v1/simple endpoint. This is preferable to using the ruby status endpoint, because that would require locking a JRuby instance. To do that will require making a normal HTTP request, not using the indirector.

      curl -v -k https://localhost:8140/status/v1/simple
      *   Trying ::1...
      * Connected to localhost (::1) port 8140 (#0)
      * TLS 1.2 connection using TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA
      * Server certificate: localhost
      > GET /status/v1/simple HTTP/1.1
      > Host: localhost:8140
      > User-Agent: curl/7.43.0
      > Accept: */*
      >
      < HTTP/1.1 200 OK
      < Date: Thu, 30 Aug 2018 21:30:25 GMT
      < Content-Type: text/plain;charset=utf-8
      < Vary: Accept-Encoding, User-Agent
      < Content-Length: 7
      < Server: Jetty(9.4.11.v20180605)
      <
      * Connection #0 to host localhost left intact
      running
      

        Attachments

          Issue Links

            Activity

              jsd-sla-details-panel

                People

                • Assignee:
                  jacob.helwig Jacob Helwig
                  Reporter:
                  josh Josh Cooper
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  6 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: