SigNoz / signoz

SigNoz is an open-source observability platform native to OpenTelemetry with logs, traces and metrics in a single application. An open-source alternative to DataDog, NewRelic, etc. 🔥 🖥. 👉 Open source Application Performance Monitoring (APM) & Observability tool
https://signoz.io
Other
19k stars 1.25k forks source link

Standardize ENV for query service #5266

Open shivanshuraj1333 opened 4 months ago

shivanshuraj1333 commented 4 months ago

Right now, there's no standard way to configure environment variables for query service, for helm installation, the below ENVs are populated but similarly to running locally the ENVs are not well defined, it should match with the docker counter part.

from a container

         env:
         - name: CLICKHOUSE_HOST
           value: my-release-clickhouse
         - name: CLICKHOUSE_PORT
           value: "9000"
         - name: CLICKHOUSE_HTTP_PORT
           value: "8123"
         - name: CLICKHOUSE_CLUSTER
           value: cluster
         - name: CLICKHOUSE_USER
           value: admin
         - name: CLICKHOUSE_PASSWORD
           value: 27ff0399-0d3a-4bd8-919d-17c2181e6fb9
         - name: CLICKHOUSE_SECURE
           value: "false"
         - name: STORAGE
           value: clickhouse
         - name: ClickHouseUrl
           value: tcp://my-release-clickhouse:9000/?username=admin&password=27ff0399-0d3a-4bd8-919d-17c2181e6fb9
         - name: ALERTMANAGER_API_PREFIX
           value: http://my-release-signoz-alertmanager:9093/api/

but the same is missing for locally running the query service and the parameters are hardcoded in strings eg https://github.com/SigNoz/signoz/blob/develop/pkg/query-service/app/server.go#L113 https://github.com/SigNoz/signoz/blob/develop/pkg/query-service/app/clickhouseReader/reader.go#L146

sudheerpailu1017 commented 4 months ago

@shivanshuraj1333 i would love to work on this

Naresh-kumar-Thodupunoori commented 3 months ago

@shivanshuraj1333 may i work on this

shivanshuraj1333 commented 3 months ago

@Naresh-kumar-Thodupunoori go ahead, it's an easy issue, just try to find all the env variables, and try to standardize them.

Naresh-kumar-Thodupunoori commented 3 months ago

@shivanshuraj1333 Can you assign me this

Naresh-kumar-Thodupunoori commented 2 months ago

Hey @shivanshuraj1333 Should I have to standardize for every folder in query-service?

slayer321 commented 2 months ago

Hey @shivanshuraj1333 ,I did like to work on this issue. Wanted to confirm for Standardization do we want to use knoaf library ?

shivanshuraj1333 commented 2 months ago

this one is relatively simple, just have all the ENV variables standardised at a place, right now they are scattered among files. for loading the env variables we can keep what we use today. No need of knoaf at the moment