Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix t3c Capability to not continue on error #6626

Merged
merged 1 commit into from
Mar 9, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
- [#6590](https://github.com/apache/trafficcontrol/pull/6590) Python client: Corrected parameter name in decorator for get\_parameters\_by\_profile\_id
- [#6368](https://github.com/apache/trafficcontrol/pull/6368) Fixed validation response message from `/acme_accounts`
- [#6603](https://github.com/apache/trafficcontrol/issues/6603) Fixed users with "admin" "Priv Level" not having Permission to view or delete DNSSEC keys.
- [#6626](https://github.com/apache/trafficcontrol/pull/6626) Fixed t3c Capabilities request failure issue which could result in malformed config.
- [#6370](https://github.com/apache/trafficcontrol/pull/6370) Fixed docs for `POST` and response code for `PUT` to `/acme_accounts` endpoint

### Removed
Expand Down
6 changes: 2 additions & 4 deletions cache-config/t3cutil/getdatacfg.go
Original file line number Diff line number Diff line change
Expand Up @@ -605,8 +605,7 @@ func GetConfigData(toClient *toreq.TOClient, disableProxy bool, cacheHostName st
caps, reqInf, err := toClient.GetServerCapabilitiesByID(nil, reqHdr) // TODO change to not take a param; it doesn't use it to request TO anyway.
log.Infoln(toreq.RequestInfoStr(reqInf, "GetServerCapabilitiesByID"))
if err != nil {
log.Errorln("Server Capabilities error, skipping!")
// return errors.New("getting server caps from Traffic Ops: " + err.Error())
return errors.New("getting server caps from Traffic Ops: " + err.Error())
} else {
if reqInf.StatusCode == http.StatusNotModified {
log.Infof("Getting config: %v not modified, using old config", "ServerCapabilities")
Expand All @@ -631,8 +630,7 @@ func GetConfigData(toClient *toreq.TOClient, disableProxy bool, cacheHostName st
caps, reqInf, err := toClient.GetDeliveryServiceRequiredCapabilitiesByID(nil, reqHdr)
log.Infoln(toreq.RequestInfoStr(reqInf, "GetDeliveryServiceRequiredCapabilitiesByID"))
if err != nil {
log.Errorln("DS Required Capabilities error, skipping!")
// return errors.New("getting DS required capabilities: " + err.Error())
return errors.New("getting DS required capabilities: " + err.Error())
} else {
if reqInf.StatusCode == http.StatusNotModified {
log.Infof("Getting config: %v not modified, using old config", "DSRequiredCapabilities")
Expand Down