trinodb / trino-gateway

https://trinodb.github.io/trino-gateway/
Apache License 2.0
122 stars 47 forks source link

Resource Group manager #347

Closed NipunTulsian closed 1 month ago

NipunTulsian commented 1 month ago

In the below code in the documentation how to get USER variable from http headers which X-trino-user, can someone guide on it

{ "rootGroups": [ { "name": "global", "softMemoryLimit": "80%", "hardConcurrencyLimit": 100, "maxQueued": 1000, "schedulingPolicy": "weighted", "jmxExport": true, "subGroups": [ { "name": "data_definition", "softMemoryLimit": "10%", "hardConcurrencyLimit": 5, "maxQueued": 100, "schedulingWeight": 1 }, { "name": "adhoc", "softMemoryLimit": "10%", "hardConcurrencyLimit": 50, "maxQueued": 1, "schedulingWeight": 10, "subGroups": [ { "name": "other", "softMemoryLimit": "10%", "hardConcurrencyLimit": 2, "maxQueued": 1, "schedulingWeight": 10, "schedulingPolicy": "weighted_fair", "subGroups": [ { "name": "${USER}", "softMemoryLimit": "10%", "hardConcurrencyLimit": 1, "maxQueued": 100 } ] }, { "name": "bi-${toolname}", "softMemoryLimit": "10%", "hardConcurrencyLimit": 10, "maxQueued": 100, "schedulingWeight": 10, "schedulingPolicy": "weightedfair", "subGroups": [ { "name": "${USER}", "softMemoryLimit": "10%", "hardConcurrencyLimit": 3, "maxQueued": 10 } ] } ] }, { "name": "pipeline", "softMemoryLimit": "80%", "hardConcurrencyLimit": 45, "maxQueued": 100, "schedulingWeight": 1, "jmxExport": true, "subGroups": [ { "name": "pipeline${USER}", "softMemoryLimit": "50%", "hardConcurrencyLimit": 5, "maxQueued": 100 } ] } ] }, { "name": "admin", "softMemoryLimit": "100%", "hardConcurrencyLimit": 50, "maxQueued": 100, "schedulingPolicy": "query_priority", "jmxExport": true } ], "selectors": [ { "user": "bob", "group": "admin" }, { "userGroup": "admin", "group": "admin" }, { "source": ".pipeline.", "queryType": "DATA_DEFINITION", "group": "global.datadefinition" }, { "source": ".pipeline.", "group": "global.pipeline.pipeline${USER}" }, { "source": "jdbc#(?.*)", "clientTags": ["hipri"], "group": "global.adhoc.bi-${toolname}.${USER}" }, { "group": "global.adhoc.other.${USER}" } ], "cpuQuotaPeriod": "1h" }

ebyhr commented 1 month ago

Please continue at community Slack: https://trino.io/slack.html

NipunTulsian commented 1 month ago

Not able to open the community link.

On Tue, 21 May, 2024, 09:32 Yuya Ebihara, @.***> wrote:

Please continue at community Slack: https://trino.io/slack.html

— Reply to this email directly, view it on GitHub https://github.com/trinodb/trino-gateway/issues/347#issuecomment-2121680533, or unsubscribe https://github.com/notifications/unsubscribe-auth/AYOWUXUQEKYZ3NEEWGY54HDZDLBN3AVCNFSM6AAAAABIAB5SOWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMRRGY4DANJTGM . You are receiving this because you authored the thread.Message ID: @.***>

ebyhr commented 1 month ago

The link is updated. Please retry.

NipunTulsian commented 1 month ago

I have posted couple of times on slack but no one replied , can you please help me with the issue

On Tue, 21 May, 2024, 10:31 Yuya Ebihara, @.***> wrote:

The link is updated. Please retry.

— Reply to this email directly, view it on GitHub https://github.com/trinodb/trino-gateway/issues/347#issuecomment-2121743872, or unsubscribe https://github.com/notifications/unsubscribe-auth/AYOWUXSPCA3ZA5BURAAF3ELZDLIJDAVCNFSM6AAAAABIAB5SOWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMRRG42DGOBXGI . You are receiving this because you authored the thread.Message ID: @.***>