[flink] DISTRIBUTED BY is silently ignored when creating tables and materialized tables
I maintainer di solito rispondono entro 1 giorno
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 25/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Ferma
- Stack tecnologico
- java
- Ambito
- data-engineering
Direzione di ricerca
Start in FlinkConversions#toFlussTable, which reads buckets only from the bucket.key and bucket.num options and never reads getDistribution(). Compare it with the Flink DynamicSinkUtils#validateBucketing guard, and check the per-version adapters for Flink 1.18 through 2.2. Done means DISTRIBUTED BY HASH(k) INTO n BUCKETS maps to key k and count n, while RANGE and conflicting options are rejected. Open pull request #4635 already targets this, so coordinate with it before starting.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Search before asking
- I searched in the issues and found nothing similar.
Fluss version
main (development)
Please describe the bug 🐞
The Fluss catalog ignores the DISTRIBUTED BY clause, so the table gets the default bucket count and bucket key. This also affects the 1.0.0 release.
CREATE TABLE orders (
id INT, region STRING, amt INT, PRIMARY KEY (id, region) NOT ENFORCED
) DISTRIBUTED BY HASH(id) INTO 4 BUCKETS;
| Declared | Created today |
|---|---|
DISTRIBUTED BY HASH(id) INTO 4 BUCKETS |
Bucket key id, region, server default bucket count |
DISTRIBUTED BY RANGE(id) INTO 4 BUCKETS |
Accepted, the clause is dropped |
DISTRIBUTED BY ... plus 'bucket.num' |
Accepted, the clause is dropped |
FlinkConversions#toFlussTable reads buckets only from the bucket.key and bucket.num options and never reads getDistribution(). Flink has a guard: DynamicSinkUtils#validateBucketing rejects distributed tables whose sink lacks SupportsBucketing. That guard never fires here, because the table read back from Fluss has no distribution.
This affects CREATE TABLE since Flink 1.20 (FLIP-376) and CREATE MATERIALIZED TABLE since Flink 2.2 (FLIP-542).
Solution
Map DISTRIBUTED BY HASH(k) INTO n BUCKETS to bucket key k and bucket count n. DISTRIBUTED INTO n BUCKETS sets only the count. Reject RANGE, and reject combining the clause with the bucket.key or bucket.num options. Flink 1.18 and 1.19 have no DISTRIBUTED BY, so their adapters return nothing. ALTER TABLE ... MODIFY DISTRIBUTION is out of scope. It keeps failing with the existing "Unsupported flink table change" error.
Are you willing to submit a PR?
- I'm willing to submit a PR!
- Lingua principale
- Java
- Stelle
- 2.2k
- Fork
- 656
- Merge medio
- 2g 21h
- PR unite (30g)
- 97
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Nessuna guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di apache/fluss
-
[lake/iceberg] Reserved write-mode properties can be set and reset through their `iceberg.` keyForse già presa @aphenix-r7 l’ha presa 6 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
apache/fluss#4658 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
[common] Decimal#hashCode is inconsistent with Decimal#equalsForse già presa @firasbouzazi l’ha presa 18 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
apache/fluss#4538 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
[security] PlainSaslServerProvider conflicts with Hadoop SASL provider causing authentication failureForse già presa @xinzhang-hello l’ha presa 24 giorni fa. Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
I maintainer di solito rispondono entro 1 giorno
-
[server] KV snapshot scheduling stops permanently after a transient snapshot-init failureForse già presa @zhang-arvin l’ha presa 24 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
apache/fluss#4489 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
[docs] Document advertised-resource and ACL principal ignore-case optionsForse già presa @EchoLee5 l’ha presa 36 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di apache/fluss
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 86/100
hiero-ledger/hiero-sdk-java#3010 ·
I maintainer di solito rispondono entro 1 giorno
-
Optimize consumer version heatmap aggregation to avoid repeated scansForse già presa @praykaria31 l’ha presa oggi. Apertatype/enhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
Apicurio/apicurio-registry#10662 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
a:false-positive
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
I maintainer di solito rispondono entro 1 giorno
-
status: waiting-for-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
spring-projects/spring-boot#52347 ·
I maintainer di solito rispondono entro 2 giorni
-
bug untriaged
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
opensearch-project/opensearch-migrations#3480 ·
I maintainer di solito rispondono entro 2 giorni