You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficcontrol.apache.org by GitBox <gi...@apache.org> on 2020/11/05 15:44:45 UTC

[GitHub] [trafficcontrol] rob05c commented on a change in pull request #5247: Change ORT/atstccfg to use standard TC objects

rob05c commented on a change in pull request #5247:
URL: https://github.com/apache/trafficcontrol/pull/5247#discussion_r518152471



##########
File path: lib/go-atscfg/astatsdotconfig.go
##########
@@ -19,23 +19,41 @@ package atscfg
  * under the License.
  */
 
+import (
+	"github.com/apache/trafficcontrol/lib/go-tc"
+)
+
 const AstatsSeparator = "="
 const AstatsFileName = "astats.config"
 
 const ContentTypeAstatsDotConfig = ContentTypeTextASCII
 const LineCommentAstatsDotConfig = LineCommentHash
 
 func MakeAStatsDotConfig(
-	profileName string,
-	paramData map[string]string, // GetProfileParamData(tx, profile.ID, AstatsFileName)
-	toToolName string, // tm.toolname global parameter (TODO: cache itself?)
-	toURL string, // tm.url global parameter (TODO: cache itself?)
-) string {
-	hdr := GenericHeaderComment(profileName, toToolName, toURL)
+	server *tc.ServerNullable,

Review comment:
       ORT/atstccfg uses the objects returned by the latest TO client. I think it should probably always do that, and upgrade the objects from the previous client to them. 
   
   This matches https://github.com/apache/trafficcontrol/blob/f42709effc973528d3a3b844ae473189e3f2321a/traffic_ops/v3-client/server.go#L196
   
   If it needs changed, I think that needs changed before this.




----------------------------------------------------------------
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:
users@infra.apache.org