This project implements the PromQL lamguage on top of SQL databases in order to query them with a timeseries query language. This way, we can query already existing data in SQL databases as if they are stored in a timeseries database like Prometheus.
Tasks:
- Implement the PromQL grammar in LARK
- Implement fetching data from the SQL database using sqlalchemy
- Implement all nodes
- Implement config manager
First run the docker-compose file:
docker-compose up
Then push some data in the QuestDB database using
pip install -r requirements.txt
pip install -e .
promsql-cli.py
Then in the opened command prompt, enter the following:
promsql > telemetry[5m]
This will get all the telemety metric values since the last 5 minitues.
Right now, the only way to change the configs is changing the values in the promsql/constants.py
file.