rawlinp commented on a change in pull request #4700:
URL: https://github.com/apache/trafficcontrol/pull/4700#discussion_r427477248



##########
File path: traffic_ops/traffic_ops_golang/ats/atsserver/ipallowdotconfig.go
##########
@@ -77,26 +80,45 @@ func GetIPAllowDotConfig(w http.ResponseWriter, r 
*http.Request) {
 // GetChildServers returns the child servers of the given Mid serverName. This 
should not be called with an Edge server.
 func GetChildServers(tx *sql.Tx, serverName tc.CacheName) 
(map[tc.CacheName]atscfg.IPAllowServer, error) {
        qry := `
-SELECT
-  s.host_name,
-  s.ip_address,
-  COALESCE(s.ip6_address, '')
-FROM
-  server s
-  JOIN type tp on tp.id = s.type
-  JOIN cachegroup cg on cg.id = s.cachegroup
-WHERE
-  (tp.name = '` + tc.MonitorTypeName + `' OR ( tp.name LIKE '` + 
tc.EdgeTypePrefix + `%')
-  AND cg.id IN (
-    SELECT
-      cg2.id
-    FROM
-     server s2
-     JOIN cachegroup cg2 ON (cg2.parent_cachegroup_id = s2.cachegroup OR 
cg2.secondary_parent_cachegroup_id = s2.cachegroup)
-    WHERE
-      s2.host_name = $1 )
-  )
-`
+       SELECT

Review comment:
       Rather than fixing up deprecated endpoints we should consider just 
removing these now, since we already know we need to get rid of them. That 
seems more practical than keeping these alive just to keep the ATS config 
functionality via TP going and keeping CIAB working (which you seem to have 
fixed already in your ORT.py PR which seems done and just needs review?).




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to