nicholasjackson/fake-service

Upstreams not displaying body or call chain

Closed this issue · 1 comments

First, fantastic service for helping debug and deploy. Thank you

We did notice that upstream URIs done seem to be showing the full call chain in 0.12.0. We have the following set up in nomad

web
--> api
    --> cache
    --> backend

Fabio Routing Table
Screen Shot 2020-06-25 at 1 47 19 PM

output from web call

{
  "name": "preflight-web",
  "uri": "/",
  "type": "HTTP",
  "ip_addresses": [
    "10.0.2.15",
    "192.168.50.95",
    "172.31.16.1"
  ],
  "start_time": "2020-06-25T10:49:38.552290",
  "end_time": "2020-06-25T10:49:38.555257",
  "duration": "2.9672ms",
  "body": "Hello from preflight-web:728c4f03-df5b-6e3a-aad1-d5ef6d26ee29",
  "upstream_calls": [
    {
      "uri": "http://localhost:29998/preflight-api",
      "headers": {
        "Content-Type": "text/html; charset=utf-8",
        "Date": "Thu, 25 Jun 2020 17:49:38 GMT"
      },
      "code": 200
    }
  ],
  "code": 200
}

output from api call

{
  "name": "preflight-api",
  "uri": "/",
  "type": "HTTP",
  "ip_addresses": [
    "10.0.2.15",
    "192.168.50.94",
    "172.17.0.1"
  ],
  "start_time": "2020-06-25T17:49:55.554057",
  "end_time": "2020-06-25T17:49:55.560151",
  "duration": "6.056823ms",
  "body": "Hello from preflight-api:a14411f9-048a-0447-ac6a-47e11834d3db",
  "upstream_calls": [
    {
      "uri": "http://localhost:29998/preflight-cache",
      "headers": {
        "Content-Type": "text/html; charset=utf-8",
        "Date": "Thu, 25 Jun 2020 17:49:55 GMT"
      },
      "code": 200
    },
    {
      "uri": "http://localhost:29998/preflight-backend",
      "headers": {
        "Content-Type": "text/html; charset=utf-8",
        "Date": "Thu, 25 Jun 2020 17:49:55 GMT"
      },
      "code": 200
    }
  ],
  "code": 200
}

UI for API call (reason I'm suspicious about the localhost causing the issue)
Screen Shot 2020-06-25 at 1 50 42 PM

Any thoughts on what could be tripping this up? It seems like the UPSTREAM call isn't ever actually making it successfully (but still reporting 200)

Nomad Job:
fake-service.nomad.txt

For context this is being used to show a "path to connect/mesh" story that we are telling. Starting with the most basic of things running on a host network, then slowly migrating to bridge, then mesh, then mesh using gateways

Operator error.....incorrect fabio port mapping.

:shame: