Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rename /debug endpoints to /query and add auth (#502)
## Which problem is this PR solving? - Adds a local query token to allow the changes in #500 to be protected by a locally-defined token in a header. ## Short description of the changes - Before #500, there was a single /debug/trace endpoint, but there is also an optional /debug endpoint intended for use with a debugger and profiler. So I renamed /debug to /query for the trace and config. - I added to these new /query endpoints a local configuration value `QueryAuthToken` that can be specified in the config file or in the environment. If specified, the `X-Honeycomb-Refinery-Query` header must be specified on a query request. - If the QueryAuthToken is not specified in the configuration, the /query endpoints are not accessible. Note that because the `/debug/trace` request has been renamed and is now protected by a token, this is technically a breaking change (although `/debug/trace` isn't intended for regular operation and wasn't documented outside of the source code).
- Loading branch information