Skip to content
This repository was archived by the owner on Apr 30, 2025. It is now read-only.

Conversation

@ameowlia
Copy link
Member

@ameowlia ameowlia commented Dec 15, 2023

A short explanation of the proposed change:

Add availability zones to endpoints as as step towards az-aware routing. Also, remove easyjson which hasn't been released since 2021, and hasn't been committed to for the past 19 months.

Instructions to functionally test the behavior change using operator interfaces (BOSH manifest, logs, curl, and metrics)

  1. Deploy with latest diego and this gorouter code
  2. Push an app
  3. Ssh onto the router VM and run /var/vcap/jobs/gorouter/bin/retrieve-local-routes | jq . and find your route.

Expected result after the change

It will have the availability zone of the endpoint listed.

  "potato.opus-404117.cf-app.com": [                                                                                                                                                                                                  
    {
      "address": "10.0.1.14:61002",
      "availability_zone": "z1",
      "protocol": "http1",
      "tls": true,
      "ttl": 120,
      "tags": {
        "app_id": "9a866875-67af-4ff0-b9f9-b05df0694cb4",
        "app_name": "potato",
        "component": "route-emitter",
        "instance_id": "0",
        "organization_id": "7b8595d6-6f8b-4be5-97d5-be7f5aa202bc",
        "organization_name": "system",
        "process_id": "9a866875-67af-4ff0-b9f9-b05df0694cb4",
        "process_instance_id": "d55daa22-338b-4c41-7499-5625",
        "process_type": "web",
        "source_id": "9a866875-67af-4ff0-b9f9-b05df0694cb4",
        "space_id": "208286e3-0adf-4851-95f7-3a4162ee6738",
        "space_name": "system"
      },
      "private_instance_id": "d55daa22-338b-4c41-7499-5625",
      "server_cert_domain_san": "d55daa22-338b-4c41-7499-5625"
    }
  ],

Current result before the change

No availability zone information is provided.

Links to any other associated PRs

  • I have viewed signed and have submitted the Contributor License Agreement

  • I have made this pull request to the main branch

  • I have run all the unit tests.

  • (Optional) I have run Routing Acceptance Tests and Routing Smoke Tests

  • (Optional) I have run CF Acceptance Tests

@ameowlia ameowlia requested a review from a team as a code owner December 15, 2023 13:19
* get it to show up in /routes endpoint
* remove easyjson. it has not been released since 2021 and has had no
  commits in 19 months.
Copy link
Contributor

@jrussett jrussett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes look good to me 👍

I was able to observe the new field in the route:

router/0055525f-d27a-4ca7-870f-8b1e20ed6c6b:~# /var/vcap/jobs/gorouter/bin/retrieve-local-routes | jq -r '.["rutabaga.opus-404117.cf-app.com"]'
[
  {
    "address": "10.0.1.13:61002",
    "availability_zone": "z1", 👈 New Field hooray! 🎉
    "protocol": "http1",
    "tls": true,
    "ttl": 120,
    "tags": {
      "app_id": "f3567c2d-0d82-4e3c-9b9e-c1254ef47303",
      "app_name": "rutabaga",
      "component": "route-emitter",
      "instance_id": "0",
      "organization_id": "7b8595d6-6f8b-4be5-97d5-be7f5aa202bc",
      "organization_name": "system",
      "process_id": "f3567c2d-0d82-4e3c-9b9e-c1254ef47303",
      "process_instance_id": "db2c1075-a05d-4c78-40c8-ab5f",
      "process_type": "web",
      "source_id": "f3567c2d-0d82-4e3c-9b9e-c1254ef47303",
      "space_id": "208286e3-0adf-4851-95f7-3a4162ee6738",
      "space_name": "system"
    },
    "private_instance_id": "db2c1075-a05d-4c78-40c8-ab5f",
    "server_cert_domain_san": "db2c1075-a05d-4c78-40c8-ab5f"
  }
]

@jrussett jrussett merged commit 5d4febe into main Dec 15, 2023
@jrussett jrussett deleted the add-az-to-endpoint branch December 15, 2023 17:57
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants