mirror of
https://git.mirrors.martin98.com/https://github.com/SigNoz/signoz
synced 2025-10-10 00:46:32 +08:00

* Queryrange params tests * review suggestions, quantile, simple metric filter and some refactoring * Add value type support * Add supprot for re2 regex, refactor, update tests and other changes * chore: update govaluate dep to signoz/govaluate * chore: add name to grouping * chore: add support for NOOP * fix: make result format compatible with prom HTTP API * chore: update clickhouse server and update query builder to use new schema * chore: use metric_name in auto suggest APIs * chore: add reduce operator and new aggregate functions * chore: add support for not like op * chore: fix the dip at the end for incomplete time range * chore: rounddown the end to exclude the incomplete collection
Query Service
Query service is the interface between forntend and databases. It is written in Golang. It will have modules for all supported databases. Query service is responsible to:
- parse the request from Frontend
- create relevant Clickhouse queries (and all other supported database queries)
- parse response from databases and handle error if any
- clickhouse response in the format accepted by Frontend
Configuration
-
Open ./constants/constants.go
- Replace
const RELATIONAL_DATASOURCE_PATH = "/var/lib/signoz/signoz.db"
withconst RELATIONAL_DATASOURCE_PATH = "./signoz.db".
- Replace
-
Query Service needs below
env
variables to run:
ClickHouseUrl=tcp://localhost:9001
STORAGE=clickhouse
Build and Run locally
cd pkg/query-service
go build -o build/query-service main.go
ClickHouseUrl=tcp://localhost:9001 STORAGE=clickhouse build/query-service
Docker Images
The docker images of query-service is available at https://hub.docker.com/r/signoz/query-service