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

Fix parent.config generation for MSO with required capabilities#5383

Merged
zrhoffman merged 1 commit intoapache:masterfrom
rawlinp:fix-atstccfg-origin-cap
Dec 18, 2020
Merged

Fix parent.config generation for MSO with required capabilities#5383
zrhoffman merged 1 commit intoapache:masterfrom
rawlinp:fix-atstccfg-origin-cap

Conversation

@rawlinp
Copy link
Copy Markdown
Contributor

@rawlinp rawlinp commented Dec 18, 2020

What does this PR (Pull Request) do?

Server capabilities do not apply to ORG servers (origins), so don't
check for them.

Which Traffic Control components are affected by this PR?

  • Traffic Ops ORT

What is the best way to verify this PR?

Create an MSO delivery service (multiSiteOrigin: true) and a required capability. Assign 2 ORG servers and at least 1 EDGE server to the delivery service. The EDGE server must have the required capability. Make sure at least 1 MID in the CDN also has the required capability. On that MID, run ORT and verify that the line in parent.config for this delivery service contains the 2 ORG servers.

Next, create a topology with your edge -> mid -> origin cachegroups, and assign it to your MSO delivery service. On the same MID as before, run ORT and verify that the line in parent.config for this delivery service contains the 2 ORG servers.

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

  • master
  • 5.0.x
  • 4.x

The following criteria are ALL met by this PR

  • This PR includes tests
  • bugfix, no docs necessary
  • This PR includes an update to CHANGELOG.md
  • This PR includes any and all required license headers
  • This PR DOES NOT FIX A SERIOUS SECURITY VULNERABILITY (see the Apache Software Foundation's security guidelines for details)

Server capabilities do not apply to ORG servers (origins), so don't
check for them.
@rawlinp rawlinp added bug something isn't working as intended Traffic Ops ORT *DEPRECATED* related to the traffic_ops_ort.pl script labels Dec 18, 2020
@rawlinp rawlinp added this to the 5.0.0 milestone Dec 18, 2020
@ocket8888
Copy link
Copy Markdown
Contributor

re-running ciab check

Copy link
Copy Markdown
Member

@zrhoffman zrhoffman left a comment

Choose a reason for hiding this comment

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

  • TestMakeParentDotConfigTopologiesMSOWithCapabilities and TestMakeParentDotConfigMSOWithCapabilities fail without the fixes included in parentdotconfig.go (but pass with fixes included)

  • Without the patch:

    • A MSO DS whose origin servers do not satisfy its required capabilities yields an empty parent.config (other than the # DO NOT EDIT comment) for servers in the child cachegroup of the ORG_LOC cachegroup.
    • parent.config is successfully populated if the origin servers do satisfy the DS's required capabilities (by inserting server server capabilities directly into the DB).
    • This is the case for topology-based and non-topology-based delivery services.
  • With the patch, the parent.config has a dest_domain= line that includes the origin servers assigned to the MSO DS, for both topology-based and non-topology-based DSes.

The tests include redundant types, but that is a code style choice and is fine because it is more explicit that way.

@zrhoffman zrhoffman merged commit df927ac into apache:master Dec 18, 2020
ocket8888 pushed a commit that referenced this pull request Dec 18, 2020
Server capabilities do not apply to ORG servers (origins), so don't
check for them.

(cherry picked from commit df927ac)
@rawlinp rawlinp deleted the fix-atstccfg-origin-cap branch December 18, 2020 16:08
@zrhoffman zrhoffman added the multi-site origin Related to the Multi-Site Origin feature label Dec 6, 2021
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 multi-site origin Related to the Multi-Site Origin feature Traffic Ops ORT *DEPRECATED* related to the traffic_ops_ort.pl script

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants