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

Use cachegroupIndex to find cachegroup type, not parentIndex#4773

Merged
rawlinp merged 4 commits into
apache:masterfrom
zrhoffman:cachegroup-index
Jun 11, 2020
Merged

Use cachegroupIndex to find cachegroup type, not parentIndex#4773
rawlinp merged 4 commits into
apache:masterfrom
zrhoffman:cachegroup-index

Conversation

@zrhoffman
Copy link
Copy Markdown
Member

@zrhoffman zrhoffman commented Jun 9, 2020

What does this PR (Pull Request) do?

Which Traffic Control components are affected by this PR?

  • Traffic Ops

What is the best way to verify this PR?

Make Rob's cachegroups, POST his topology, and make sure it succeeds:

{
  "name": "Foo",
  "description": "bar",
  "nodes": [
    {
      "cachegroup": "mid-west",
      "parent": "",
      "secParent": "",
      "parents": []
    },
    {
      "cachegroup": "sacramento-ca-usa",
      "parent": "mid-west",
      "secParent": "mid-east",
      "parents": [
        0,
        2
      ]
    },
    {
      "cachegroup": "mid-east",
      "parent": "",
      "secParent": "",
      "parents": []
    },
    {
      "cachegroup": "albany-ny-usa",
      "parent": "mid-east",
      "secParent": "mid-west",
      "parents": [
        2,
        0
      ]
    },
    {
      "cachegroup": "tallahassee-fl-usa",
      "parent": "mid-east",
      "secParent": "mid-west",
      "parents": [
        2,
        0
      ]
    }
  ]
}

If this is a bug fix, what versions of Traffic Control are affected?

The following criteria are ALL met by this PR

  • We are going to take out edge parentage validation anyway, so no tests
  • Bugfix, no documentation necessary
  • An update to CHANGELOG.md is not necessary
  • This PR includes any and all required license headers
  • This PR does not include a database migration
  • This PR DOES NOT FIX A SERIOUS SECURITY VULNERABILITY (see the Apache Software Foundation's security guidelines for details)

Additional Information

@rawlinp rawlinp added bug something isn't working as intended Traffic Ops related to Traffic Ops labels Jun 9, 2020
Copy link
Copy Markdown
Contributor

@rawlinp rawlinp left a comment

Choose a reason for hiding this comment

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

This looks good, but we should add some more positive test cases to the TO API tests (the example in the description would be a good one).

@zrhoffman
Copy link
Copy Markdown
Member Author

zrhoffman commented Jun 10, 2020

More positive test cases for the TO API tests added in 9709073e08, including @rob05c's.

@zrhoffman zrhoffman requested a review from rawlinp June 10, 2020 23:23
Copy link
Copy Markdown
Contributor

@rawlinp rawlinp left a comment

Choose a reason for hiding this comment

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

TO unit tests and API tests pass, new positive test cases look good.

@rawlinp rawlinp merged commit 1ed80c6 into apache:master Jun 11, 2020
@zrhoffman zrhoffman deleted the cachegroup-index branch October 18, 2020 00:34
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

bug something isn't working as intended Traffic Ops related to Traffic Ops

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Traffic Ops Topology with Secondary Parent returns error

2 participants