moltzaum commented on issue #2940: /api/1.x/cdns/{{ID}} gives incorrect
response for non-existant IDs
URL: https://github.com/apache/trafficcontrol/issues/2940#issuecomment-445031499
Most other api endpoints are like this as well. They are like this because
there isn't much of a distinction between query and path parameters. I used to
think
```
curl -Lvsk -b $mc https://localhost/api/1.2/cdns/42`
{"alerts":[{"text":"not found","level":"error"}]}
curl -Lvsk -b $mc https://localhost/api/1.2/cdns?id=42
{"response":[]}
```
should have been correct, but now I think both should return a 404 on the
premise that the id is unique. This would imply that other unique parameters
should also return a 404.
----------------------------------------------------------------
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