-
Notifications
You must be signed in to change notification settings - Fork 317
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
feat: prometheus remote write and read #346
Conversation
84536ea
to
f028cd2
Compare
When the table does not exist, such as
|
Codecov Report
@@ Coverage Diff @@
## develop #346 +/- ##
===========================================
+ Coverage 84.28% 84.33% +0.05%
===========================================
Files 350 365 +15
Lines 32109 33970 +1861
===========================================
+ Hits 27063 28649 +1586
- Misses 5046 5321 +275
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
It's still under development, not ready for review, but thanks for your CR @yuanbohan |
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.
An exciting feature 🥳
* feat: scaffold for prometheus protocol handler * feat: impl remote write and read for prometheus * chore: make label matchers working in remote reading * chore: case senstive regexp matching for labers and tweak restful api * test: prometheus test * test: adds test for prometheus handler and http server * fix: typo in comment * refactor: move snappy_compress and snappy_decompress * fix: by code review * fix: collect_timeseries_ids * fix: timestamp and value column's value may be null
Intro
Related to #313 .
It's ready for review.
Main changes:
samples
response. The stream protocol is designed for prometheus itself (communication between prometheus instances), it's not enabled and useful for third-parties remote storage.Todo:
How to test
prometheus.yml
:Enable
read_recent
to test remote reading../prometheus --config.file=prometheus.yml --log.level=debug
.Then frontend will receive the remote write reqeusts and create many tables automatically in datanode.data
folder in prometheus, and restart it, it will read historical data from greptimedb.