Skip to content

Add Presto platform with engine-only integration tests#773

Open
JunWang222 wants to merge 4 commits into
apache:mainfrom
JunWang222:presto-engine-platform-only-test
Open

Add Presto platform with engine-only integration tests#773
JunWang222 wants to merge 4 commits into
apache:mainfrom
JunWang222:presto-engine-platform-only-test

Conversation

@JunWang222

Copy link
Copy Markdown

Summary

This PR adds the Wayang Presto platform implementation and engine-only integration tests.

What is included

  • Adds wayang-presto platform module.
  • Adds Presto mappings/operators for:
    • TableSource
    • Filter
    • Projection
    • Join
    • GlobalReduce
    • ReduceBy
    • Sort
    • TableSink
  • Adds end-to-end PrestoOperatorsIT coverage for each operator.
  • Adds JavaPlanBuilder integration tests that simulate user-facing API usage.
  • Keeps the integration tests engine-only by registering only Presto.plugin().
  • Uses self-contained in-memory Presto fixtures created by the test setup, without requiring external datasets.

Validation

  • Rebased on latest apache/wayang:main.
  • Presto operator tests are designed to run against the local Presto setup and skip when Presto is unavailable.

JunWang222 and others added 2 commits June 28, 2026 21:08
Implement Presto (PrestoDB) as a Wayang platform module extending
JdbcPlatformTemplate, same pattern as wayang-trino.
Run the whole Wayang plan, including the terminal sink, inside Presto:
register only Presto.plugin(), end every PrestoOperatorsIT test in a
TableSink that compiles to CREATE TABLE ... AS SELECT, and assert results
via plain JDBC after execute() returns.

- jdbc-template JdbcExecutor.executeSinkStage: use selectStartTask for
  multi-source joins and collect global-reduce/reduce-by/sort into the
  composed CREATE TABLE AS SELECT (ported from wayang-trino-only-test).
- api-scala-java DataQuantaBuilder: add withSqlUdf/withSqlUdfs on the
  reduce/join/sort builders so JavaPlanBuilder tests can push SQL down.
- PrestoOperatorsIT: 13 engine-only tests (8 operator-level + 5
  JavaPlanBuilder); join Tuple2->Record handled by a test-only flatten
  mapping to PrestoProjectionOperator.
- improvement.md: document the engine-only shape.

Verified against live PrestoDB (memory connector): Tests run: 13,
Failures: 0, Errors: 0, Skipped: 0; 13 CREATE TABLE AS SELECT executed
in Presto.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@mspruc

mspruc commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Thank you for your contribution, looks good! left some comments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants