rawlinp opened a new issue #6376: URL: https://github.com/apache/trafficcontrol/issues/6376
<!-- ************ STOP!! ************ If this issue identifies a security vulnerability, DO NOT submit it! Instead, contact the Apache Traffic Control Security Team at [email protected] and follow the guidelines at https://apache.org/security regarding vulnerability disclosure. - For *SUPPORT QUESTIONS*, use the #traffic-control channel on the ASF slack (https://s.apache.org/tc-slack-request) or the Traffic Control Users mailing list (send an email to [email protected] to subscribe). - Before submitting, please **SEARCH GITHUB** for a similar issue or PR * https://github.com/apache/trafficcontrol/issues * https://github.com/apache/trafficcontrol/pulls --> <!-- Do not submit security vulnerabilities or support requests here - see above --> ## This Improvement request (usability, performance, tech debt, etc.) affects these Traffic Control components: <!-- delete all those that don't apply --> - Traffic Monitor ## Current behavior: <!-- Describe how the current features are insufficient. --> https://github.com/apache/trafficcontrol/blob/9516de39fffa3ddda0346720ef98edabc8efa07e/traffic_monitor/towrap/towrap.go#L679-L756 TM first requests the monitoring config snapshot then requests the CRConfig snapshot in order to create its internal `TrafficMonitorConfigMap` representation. It currently overwrites the Traffic Monitor data in the monitoring snapshot with data from the CRConfig snapshot, most likely due to the monitoring config missing Traffic Monitor IPv4 and IPv6 addresses. It will also fall back to using CRConfig delivery service data if not present in the monitoring snapshot (although this should no longer be an issue as of https://github.com/apache/trafficcontrol/pull/5184). Since the monitoring config and CRConfig are now snapshotted together, this is entirely unnecessary. ## New behavior: <!-- Describe how this change would improve Traffic Control --> 1. Traffic Ops should populate the `ip` and `ip6` fields in the `trafficMonitors` array of the monitoring config snapshot instead of leaving them blank: ``` { "profile": "MY_TM_PROFILE", "status": "ONLINE", "port": 80, "cachegroup": "foo", "hostname": "tm1", "fqdn": "example.com", "ip": "", "ip6": "" }, ``` 2. Traffic Ops should exclude delivery service data from the monitoring config snapshot that does not belong to the given CDN being snapshotted. It currently includes all delivery services across all CDNs. 3. TM should be updated to only overwrite the Traffic Monitor data in its monitoring config snapshot (in the code linked above) with CRConfig data if the monitoring snapshot is still missing IPv4 and IPv6 data. Otherwise, it should never have to overwrite the monitoring config data. Eventually, we can remove that fallback code entirely, once it's assumed that TM config snapshots will always have IP data going forward. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
