-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add API delete curl examples #6680
Add API delete curl examples #6680
Conversation
./tools/diff_coverage.sh ../loki-main/test_results.txt test_results.txt ingester,distributor,querier,querier/queryrange,iter,storage,chunkenc,logql,loki Change in test coverage per package. Green indicates 0 or positive change, red indicates that test coverage for a package fell. + ingester 0%
+ distributor 0%
+ querier 0%
+ querier/queryrange 0%
+ iter 0%
+ storage 0%
+ chunkenc 0%
+ logql 0%
- loki -0.6% |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed!
Co-authored-by: Jennifer Villa <jvilla2013@gmail.com>
Co-authored-by: Jennifer Villa <jvilla2013@gmail.com>
Co-authored-by: Jennifer Villa <jvilla2013@gmail.com>
Co-authored-by: Jennifer Villa <jvilla2013@gmail.com>
./tools/diff_coverage.sh ../loki-main/test_results.txt test_results.txt ingester,distributor,querier,querier/queryrange,iter,storage,chunkenc,logql,loki Change in test coverage per package. Green indicates 0 or positive change, red indicates that test coverage for a package fell. + ingester 0%
+ distributor 0%
+ querier 0%
+ querier/queryrange 0%
+ iter 0%
+ storage 0%
+ chunkenc 0%
+ logql 0%
+ loki 0% |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
* Add API delete curl examples * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> (cherry picked from commit 1f676ad)
* Add API delete curl examples * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> (cherry picked from commit 1f676ad) Co-authored-by: Karen Miller <84039272+KMiller-Grafana@users.noreply.github.com>
```bash | ||
curl -u "Tenant1:$API_TOKEN" \ | ||
-g -X POST \ | ||
'http://127.0.0.1:3100/loki/api/v1/delete?query={foo="bar"}&start=1591616227&end=1591619692' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We've found out that running these kinds of post requests in bash causes problems with escaping the &
, =
and characters. The --data-urlencode
parameter for curl is preferred. https://github.com/grafana/deployment_tools/blob/master/docs/loki/support-escalation.md#manual-operational-tasks has an example. Perhaps we should use that format.
* Add API delete curl examples * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> * Update docs/sources/api/_index.md Co-authored-by: Jennifer Villa <jvilla2013@gmail.com> Co-authored-by: Jennifer Villa <jvilla2013@gmail.com>
This PR updates API delete examples (documentation) in the same way that PR #6530 updated the API query example. Deletes only work on a single tenant, so the examples distinguish GEL API header from Loki headers.
Reviews: