[BUG] Analytics routing does not resolve aliases and wildcard index expressions
Los mantenedores suelen responder en 1 día
@KarstenSchnitter ya está trabajando en esto.
Desde el 29/10/2026.
- #5917 de @KarstenSchnitter — abierto
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 25/100
Línea de trabajo
Start with RestUnifiedQueryAction.isAnalyticsIndex() and trace how SQL and PPL source expressions are extracted and routed. The issue names no test files, so locate the routing tests and run the relevant SQL and PPL suites. Done means aliases, wildcards, comma-separated sources, and data streams resolve to the intended engine while preserving missing-target behavior, system and REST-source handling, and authorization; the linked open PR indicates work is already underway.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
What is the bug?
RestUnifiedQueryAction.isAnalyticsIndex() determines whether SQL and PPL queries should use the analytics engine by looking up the extracted source as a concrete index name.
Aliases, wildcard expressions, and some multi-index expressions are not concrete index names. Although they may resolve exclusively to composite/Parquet-backed indices, the lookup fails and the query silently falls back to the legacy execution path.
This is particularly visible when columnar storage is enabled per index rather than through the cluster-wide cluster.pluggable.dataformat=composite setting.
SQL PR #5683 documents the same routing gap. It uses the cluster-wide setting in its security test cluster to force all queries through the analytics engine, but does not resolve index expressions for per-index routing.
How can one reproduce the bug?
Run OpenSearch with the SQL plugin and sandbox analytics/composite plugins enabled. Do not set the cluster-wide composite data-format setting.
Create a per-index columnar index and alias:
PUT parquet-logs-000001
{
"settings": {
"index.pluggable.dataformat.enabled": true,
"index.pluggable.dataformat": "composite",
"index.composite.primary_data_format": "parquet",
"index.composite.secondary_data_formats": ["lucene"]
},
"mappings": {
"properties": {
"service": {
"type": "keyword",
"index": false
}
}
},
"aliases": {
"parquet-logs": {
"is_write_index": true
}
}
}
Index and refresh a document:
POST parquet-logs/_doc
{
"service": "checkout"
}
POST parquet-logs/_refresh
Run equivalent profiled PPL queries:
POST /_plugins/_ppl
{
"query": "source = parquet-logs-000001 | fields service",
"profile": true
}
POST /_plugins/_ppl
{
"query": "source = parquet-logs | fields service",
"profile": true
}
POST /_plugins/_ppl
{
"query": "source = parquet-logs-* | fields service",
"profile": true
}
The concrete-index query is routed to the analytics engine. The alias and wildcard queries fall back to the legacy path because the source expression is passed to a direct metadata lookup without first being resolved.
Depending on the mapping and query, the fallback can produce an error, omit columnar field values, or return a response whose profile shows that the legacy engine handled the query.
The same problem applies to SQL table expressions.
What is the expected behavior?
Routing should resolve aliases, wildcard expressions, comma-separated sources, and data streams to concrete indices before selecting an execution engine.
Suggested semantics:
- A non-empty resolution containing only compatible composite indices uses the analytics engine.
- A resolution containing only ordinary Lucene indices uses the normal SQL/PPL path.
- Missing and empty expressions retain the normal request path and error behavior.
- Mixed Lucene/composite targets must not be silently or partially routed. The desired behavior—normal fallback versus an explicit unsupported-target error—should be agreed upon.
- System catalog and REST-source queries must retain their existing handling.
- Security authorization must remain enforced for every resolved target.
What is your host/environment?
- OpenSearch/SQL: current
maintargeting OpenSearch 3.10 - Analytics engine and composite/Parquet sandbox plugins enabled
- Columnar storage enabled per index
Additional context
Origin: opensearch-project/technical-steering#146
Related SQL PR: #5683
A possible implementation is to inject IndexNameExpressionResolver, resolve every extracted expression against the current cluster state, reject empty resolutions, and require every resolved index to have:
index.pluggable.dataformat.enabled = true
index.pluggable.dataformat = composite
Tests should cover:
- Concrete index
- Single- and multi-index aliases
- Wildcards resolving entirely to columnar indices
- Comma-separated columnar sources
- Data streams
- Empty wildcard expansions
- Missing indices
- Ordinary Lucene targets
- Mixed Lucene and columnar targets
- PPL and SQL query paths
- Lenguaje dominante
- Java
- Estrellas
- 175
- Forks
- 236
- Merge medio
- 2 d 19 h
- PR fusionados (30 d)
- 40
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de opensearch-project/sql
-
[BUG] PromQL queries fail with InvalidTypeIdException when metric has a label named "type"Posiblemente ocupada @nagendramohan la tomó hace 89 días. Abiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
opensearch-project/sql#5684 · 4 comentarios ·
Los mantenedores suelen responder en 1 día
-
[DOC] Calcite settings documentation missing examplesPosiblemente ocupada @AzazelSensei la tomó hace 46 días. Abiertodocumentation PPL
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
opensearch-project/sql#4806 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug untriaged
Dificultad 2/5 1-3 horas Aptitud para principiantes 48/100
opensearch-project/sql#5928 ·
Los mantenedores suelen responder en 1 día
-
[Testing] Test downstream plugins that load SQL classes (alerting, skills)Posiblemente ocupada @ahkcs la tomó hace 4 días. Abiertoinfrastructure testing
Dificultad 5/5 Más de una semana Aptitud para principiantes 18/100
opensearch-project/sql#5925 · 1 comentario · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
bug PPL
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
opensearch-project/sql#5904 ·
Los mantenedores suelen responder en 1 día
Todos los issues de opensearch-project/sql
Issues similares
-
hermes-queue
Dificultad 1/5 Menos de una hora Aptitud para principiantes 72/100
chrisalunlloyd2-sudo/mindpalace#349 ·
Los mantenedores suelen responder en 1 día
-
Retry-After parser accepts invalid delay-seconds valuesPosiblemente ocupada @Dhruvraj-Rana la tomó hoy. AbiertoBug
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
open-telemetry/opentelemetry-java#9018 ·
Los mantenedores suelen responder en 2 días
-
bug priority: medium Review effort [1-5]: 2 status: needs-triage type: bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
carlos-emr/carlos#5818 ·
Los mantenedores suelen responder en 1 día
-
bug good first issue help wanted tooling
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
appmonster007/kmip-adapter#100 ·
-
[Documentation]: Remove non-existent CHANGELOG reference from StateBackendProperties JavadocAbiertoaccepted good first issue java
Dificultad 1/5 Menos de una hora Aptitud para principiantes 88/100
Los mantenedores suelen responder en 1 día