mitchell852 commented on a change in pull request #2229: Add Traffic Ops Golang 
deliveryservicesregexes
URL: 
https://github.com/apache/incubator-trafficcontrol/pull/2229#discussion_r186821702
 
 

 ##########
 File path: traffic_ops/traffic_ops_golang/routes.go
 ##########
 @@ -214,6 +215,14 @@ func Routes(d ServerData) ([]Route, []RawRoute, 
http.Handler, error) {
                {1.3, http.MethodPost, `servers/{id}/deliveryservices$`, 
server.AssignDeliveryServicesToServerHandler(d.DB), auth.PrivLevelOperations, 
Authenticated, nil},
                {1.3, http.MethodGet, `servers/{host_name}/update_status$`, 
server.GetServerUpdateStatusHandler(d.DB), auth.PrivLevelReadOnly, 
Authenticated, nil},
 
+               //Delivery Services Regexes
+               {1.1, http.MethodGet, `deliveryservices_regexes/?(\.json)?$`, 
deliveryservicesregexes.Get(d.DB), auth.PrivLevelReadOnly, Authenticated, nil},
+               {1.1, http.MethodGet, 
`deliveryservices/{dsid}/regexes/?(\.json)?$`, 
deliveryservicesregexes.DSGet(d.DB), auth.PrivLevelReadOnly, Authenticated, 
nil},
+               {1.1, http.MethodGet, 
`deliveryservices/{dsid}/regexes/{regexid}?(\.json)?$`, 
deliveryservicesregexes.DSGetID(d.DB), auth.PrivLevelReadOnly, Authenticated, 
nil},
+               {1.1, http.MethodPost, 
`deliveryservices/{dsid}/regexes/?(\.json)?$`, 
deliveryservicesregexes.Post(d.DB), auth.PrivLevelReadOnly, Authenticated, nil},
 
 Review comment:
   I don't think the POST, PUT and DELETE have the correct priv levels. Looking 
at DeliveryServiceRegexes.pm, it looks like the operations priv level is 
required.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to