[FEATURE] _routing suppport
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 25/100
Research direction
Start with feature #1805, which the issue says added parsing of _routing in SQL queries, and find where that value is currently consumed when the query is sent to OpenSearch. The open question is how strict the query shape must be before routing applies, which the maintainers have not decided. Done means a query with _routing reaches only the matching shards, shown by a test, and the design choice is agreed in the thread first.
Written by the indexing model from the issue text.
Description
Is your feature request related to a problem?
Feature #1805 added support for including _routing in a query, but omitted a significant piece of that functionality, namely actually routing the request to only those specific shards. The sql plugin is incredibly useful, but being unable to use shard routing makes it perform rather poorly on our cluster. Each tenant has specific shards, and running the sql queries across the entire cluster instead of the tenant specific shards adds lots of unnecessary time to the queries.
What solution would you like?
When _routing is included in a sql query, route the opensearch query to the appropriate shards instead of the entire cluster. I'm fine with very strict query structure (e.g. requiring this expression to be the first in the WHERE clause or something like that)
What alternatives have you considered?
We are probably going to end up with using an alias per tenant in our cluster because using the sql query with the alias seems to do the routing correctly. however, that adds a lot of extra maintenance burden (an alias per tenant), and we are unsure how that will scale as the number of tenants grows.
Do you have any additional context?
Nope
- Dominant language
- Java
- Stars
- 176
- Forks
- 237
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 34
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from opensearch-project/sql
-
bug untriaged
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
opensearch-project/sql#5990 ·
Maintainers usually reply within 1 day
-
bug untriaged
Difficulty 1/5 Under an hour Newbie friendliness 85/100
opensearch-project/sql#5983 ·
Maintainers usually reply within 1 day
-
[BUG] PromQL queries fail with InvalidTypeIdException when metric has a label named "type"Possibly taken @nagendramohan claimed this 107 days ago. Openbug
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
opensearch-project/sql#5684 · 4 comments ·
Maintainers usually reply within 1 day
-
[DOC] Calcite settings documentation missing examplesPossibly taken @AzazelSensei claimed this 64 days ago. Opendocumentation PPL
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
opensearch-project/sql#4806 · 1 comment ·
Maintainers usually reply within 1 day
-
calcite enhancement Meta performance PPL untriaged
Difficulty 5/5 Over a week Newbie friendliness 8/100
opensearch-project/sql#5991 ·
Maintainers usually reply within 1 day
All issues in opensearch-project/sql
Similar issues
-
chore
Difficulty 1/5 1-3 hours Newbie friendliness 88/100
lugassawan/swe-workbench#841 ·
-
needs-triage
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
EndlessPixel-Studio/FakePlayer-CE#155 ·
Maintainers usually reply within 1 day
-
Document the isv:HDFGroup Linux package repositories and signing keyPossibly taken @brtnfld claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
checkstyle/checkstyle#23174 ·
Maintainers usually reply within 1 day