Skip to content

[native] Adds a native session property provider#23045

Merged
tdcmeehan merged 7 commits intoprestodb:masterfrom
pdabre12:system-session-properties
Oct 28, 2024
Merged

[native] Adds a native session property provider#23045
tdcmeehan merged 7 commits intoprestodb:masterfrom
pdabre12:system-session-properties

Conversation

@pdabre12
Copy link
Contributor

@pdabre12 pdabre12 commented Jun 20, 2024

Description

Adds a native session property manager.

Motivation and Context

To resolve #23001

Impact

With this change, we can now retrieve session properties which are only supported by both the coordinator and the execution engine.

Test Plan

Tests are included.

Contributor checklist

  • Please make sure your submission complies with our development, formatting, commit message, and attribution guidelines.
  • PR description addresses the issue accurately and concisely. If the change is non-trivial, a GitHub Issue is referenced.
  • Documented new properties (with its default value), SQL syntax, functions, or other functionality.
  • If release notes are required, they follow the release notes guidelines.
  • Adequate tests were added if applicable.
  • CI passed.

Release Notes

Please follow release notes guidelines and fill in the release notes below.

Release Notes

Please follow release notes guidelines and fill in the release notes below.

== RELEASE NOTES ==

Coordinator Plugin Changes
* Add native system session property provider. :pr:`23045`

cc: @tdcmeehan @abevk2023 @Joe-Abraham

@pdabre12 pdabre12 changed the title System session properties [WIP] System session properties Jun 20, 2024
@tdcmeehan
Copy link
Contributor

We'll need to spend some time consolidating these commits. It would be great to think about the following commits:

  1. A commit which introduces the necessary SPI. This includes the definition of the SessionPropertyMetadata.
  2. A commit which integrates that SPI with the Presto runtime
  3. An implmenentation of this plugin for the sidecar
  4. An implementation of this plugin with the C++-specific worker properties, and with a config toggle to enable/disable

@pdabre12 pdabre12 force-pushed the system-session-properties branch from 35ed111 to fa2ac66 Compare August 27, 2024 23:58
@pdabre12 pdabre12 force-pushed the system-session-properties branch from 708018a to 90ec7bd Compare September 4, 2024 21:58
@tdcmeehan tdcmeehan self-assigned this Sep 5, 2024
@pdabre12 pdabre12 force-pushed the system-session-properties branch from 6d2f109 to 41da0f3 Compare September 5, 2024 18:24
@pdabre12 pdabre12 changed the title [WIP] System session properties [native] Adds a native system property provider Sep 5, 2024
@pdabre12 pdabre12 marked this pull request as ready for review September 5, 2024 19:28
@pdabre12 pdabre12 requested a review from presto-oss September 5, 2024 19:28
@rschlussel rschlussel self-requested a review September 5, 2024 20:38
Copy link
Contributor

@tdcmeehan tdcmeehan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

@tdcmeehan tdcmeehan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

@tdcmeehan tdcmeehan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Introduce session properties SPI

Copy link
Contributor

@tdcmeehan tdcmeehan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

@tdcmeehan tdcmeehan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

@tdcmeehan tdcmeehan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Open API docs ✅

@pdabre12 pdabre12 force-pushed the system-session-properties branch 3 times, most recently from 4317618 to ca4bb3b Compare September 17, 2024 22:51
@pdabre12 pdabre12 force-pushed the system-session-properties branch from ca4bb3b to 7695324 Compare September 30, 2024 22:20
@pdabre12 pdabre12 force-pushed the system-session-properties branch from 74432de to 4eb5cf4 Compare October 22, 2024 23:07
@pdabre12
Copy link
Contributor Author

@tdcmeehan @rschlussel Addressed the comments, please take a look. Also added a CI job for running native-sidecar tests.

@pdabre12 pdabre12 requested a review from tdcmeehan October 22, 2024 23:23
BryanCutler added a commit to BryanCutler/presto that referenced this pull request Oct 25, 2024
This adds an endpoint to the native Presto server that will convert
a Presto plan fragment to Velox. If the conversion is successful,
the server will send an ok response. If it fails, the server will
send an error response with a 422 status code as unprocessable.
The error message will contain an ExecutionFailureInfo struct
with error type, code and message.

See also prestodb#23045
RFC: https://github.com/prestodb/rfcs/blob/main/RFC-0008-plan-checker.md
BryanCutler added a commit to BryanCutler/presto that referenced this pull request Oct 25, 2024
This adds an endpoint to the native Presto server that will convert
a Presto plan fragment to Velox. If the conversion is successful,
the server will send an ok response. If it fails, the server will
send an error response with a 422 status code as unprocessable.
The error message will contain an ExecutionFailureInfo struct
with error type, code and message.

See also prestodb#23045
RFC: https://github.com/prestodb/rfcs/blob/main/RFC-0008-plan-checker.md
BryanCutler added a commit to BryanCutler/presto that referenced this pull request Oct 25, 2024
This adds an endpoint to the native Presto server that will convert
a Presto plan fragment to Velox. If the conversion is successful,
the server will send an ok response. If it fails, the server will
send an error response with a 422 status code as unprocessable.
The error message will contain an ExecutionFailureInfo struct
with error type, code and message.

See also prestodb#23045
RFC: https://github.com/prestodb/rfcs/blob/main/RFC-0008-plan-checker.md
tdcmeehan
tdcmeehan previously approved these changes Oct 25, 2024
rschlussel
rschlussel previously approved these changes Oct 28, 2024
pdabre12 and others added 7 commits October 28, 2024 08:13
Co-authored-by: Tim Meehan <tdm@fb.com>
Co-authored-by: Joe Abraham <joe.abraham@ibm.com>
Co-authored-by: Joe Abraham <joe.abraham@ibm.com>
Co-authored-by: Abe Varghese Kodiyan <abe.varghese@ibm.com>
Co-authored-by: Joe Abraham <joe.abraham@ibm.com>
Co-authored-by: Deepthy Davis <deepthy.davis@ibm.com>
@pdabre12 pdabre12 dismissed stale reviews from rschlussel and tdcmeehan via c1e34ed October 28, 2024 15:17
@pdabre12 pdabre12 force-pushed the system-session-properties branch from 4eb5cf4 to c1e34ed Compare October 28, 2024 15:17
@tdcmeehan tdcmeehan merged commit 5ed9da1 into prestodb:master Oct 28, 2024
BryanCutler added a commit to BryanCutler/presto that referenced this pull request Oct 29, 2024
This adds an endpoint to the native Presto server that will convert
a Presto plan fragment to Velox. If the conversion is successful,
the server will send an ok response. If it fails, the server will
send an error response with a 422 status code as unprocessable.
The error message will contain an ExecutionFailureInfo struct
with error type, code and message.

See also prestodb#23045
RFC: https://github.com/prestodb/rfcs/blob/main/RFC-0008-plan-checker.md
BryanCutler added a commit to BryanCutler/presto that referenced this pull request Oct 29, 2024
This adds an endpoint to the native Presto server that will convert
a Presto plan fragment to Velox. If the conversion is successful,
the server will send an ok response. If it fails, the server will
send an error response with a 422 status code as unprocessable.
The error message will contain an ExecutionFailureInfo struct
with error type, code and message.

See also prestodb#23045
RFC: https://github.com/prestodb/rfcs/blob/main/RFC-0008-plan-checker.md
@jaystarshot jaystarshot mentioned this pull request Nov 1, 2024
25 tasks
@jaystarshot
Copy link
Member

@pdabre12 @tdcmeehan Does this change warrant a release note?

@tdcmeehan
Copy link
Contributor

@jaystarshot it's in the above PR, but maybe the tool had trouble parsing it.

@jaystarshot
Copy link
Member

got it, I don't think Coordinator Plugin Changes is a topic yet. Is this change for some sidecar or for general presto c++ coordinator?

@tdcmeehan
Copy link
Contributor

Let's put it under general C++ changes

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.

Allow C++-defined system session properties

5 participants