-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Search before asking
- I searched in the issues and found nothing similar.
Paimon version
1.3.1
Compute Engine
Spark / Flink
Minimal reproduce step
-
First create a test table with write-only explicitly set as true to disable the compactions
spark.sql("CREATE` TABLE paimon.test_db.test_table (id BIGINT NOT NULL, value STRING NOT NULL) TBLPROPERTIES ('changelog-producer' = 'lookup', 'primary-key' = 'id', 'write-only' = 'true')") -
Insert some data into the test table.
spark.sql("INSERT INTO paimon.test_db.test_table (id, value) VALUES (1, 'one')") -
Changelog files aren't generated.
>>> spark.sql("SELECT * from paimon.test_db.test_table").show(truncate=False) +---+-----+ |id |value| +---+-----+ |1 |one | +---+-----+ >>> spark.sql("SELECT * from paimon_incremental_query('paimon.test_db.test_table', 0, 1)").show(truncate=False) +---+-----+ |id |value| +---+-----+ +---+-----+ -
Querying the snapshot table, I can confirm compaction is not triggered.
>>> spark.sql("SELECT snapshot_id, commit_kind from paimon.test_db.`test_table$snapshots`").show(truncate=False) +-----------+-----------+ |snapshot_id|commit_kind| +-----------+-----------+ |1 |APPEND | +-----------+-----------+
What doesn't meet your expectations?
The documentation mentions that changelog files will be generated before committing written data, however that's not the case and this happens on compaction.
This is also evident from the source code as well.
Anything else?
No response
Are you willing to submit a PR?
- I'm willing to submit a PR!
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working