Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initializes PartiQL's Engine #1283

Merged
merged 5 commits into from
Dec 7, 2023
Merged

Initializes PartiQL's Engine #1283

merged 5 commits into from
Dec 7, 2023

Conversation

johnedquinn
Copy link
Member

@johnedquinn johnedquinn commented Dec 7, 2023

Relevant Issues

  • None

Description

  • Here's a quick glimpse of what I'd personally like to see for evaluation.
  • Almost all details of the engine are intentionally internal. There's only a single file of public APIs.

Other Information

  • Updated Unreleased Section in CHANGELOG: [YES/NO]

    • No.
  • Any backward-incompatible changes? NO

    • No.
  • Any new external dependencies? NO

    • No
  • Do your changes comply with the Contributing Guidelines
    and Code Style Guidelines? [YES/NO]

License Information

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Copy link

github-actions bot commented Dec 7, 2023

Conformance comparison report

Base (f8f6b2a) b25438c +/-
% Passing 92.33% 92.33% 0.00%
✅ Passing 5372 5372 0
❌ Failing 446 446 0
🔶 Ignored 0 0 0
Total Tests 5818 5818 0

Number passing in both: 5372

Number failing in both: 446

Number passing in Base (f8f6b2a) but now fail: 0

Number failing in Base (f8f6b2a) but now pass: 0

@codecov-commenter
Copy link

codecov-commenter commented Dec 7, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

❗ No coverage uploaded for pull request base (partiql-eval@4ac1b3d). Click here to learn what that means.

Additional details and impacted files
@@               Coverage Diff               @@
##             partiql-eval    #1283   +/-   ##
===============================================
  Coverage                ?   49.46%           
  Complexity              ?     1047           
===============================================
  Files                   ?      166           
  Lines                   ?    13391           
  Branches                ?     2500           
===============================================
  Hits                    ?     6624           
  Misses                  ?     6103           
  Partials                ?      664           
Flag Coverage Δ
CLI 13.43% <0.00%> (?)
EXAMPLES 80.28% <0.00%> (?)
LANG 54.65% <0.00%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Comment on lines 8 to 13
@OptIn(PartiQLValueExperimental::class)
override fun execute(plan: PartiQLPlan): PartiQLEngine.Result {
val expression = PlanToPhysical.convert(plan)
val value = expression.evaluate(Record(emptyList()))
return PartiQLEngine.Result.Success(value)
}
Copy link
Contributor

Choose a reason for hiding this comment

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

What customers might like is "prepare" and "execute" methods. This would enable re-use of a compiled expression which customers have asked for

Copy link
Member Author

Choose a reason for hiding this comment

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

ACK -- in my opinion, once we determine what we should expose, prepare will be a very nice addition. For now, I've kept all compilation/execution internal.

Comment on lines 13 to 15
interface Relation : PhysicalNode {
fun evaluate(): Iterator<Record>
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Record on the Iterator .. it's a reference anyways .. nice and simple.

@johnedquinn johnedquinn changed the base branch from main to partiql-evaluator December 7, 2023 18:14
@johnedquinn johnedquinn changed the title [EXPERIMENT] Initializes PartiQL's Engine Initializes PartiQL's Engine Dec 7, 2023
@johnedquinn johnedquinn marked this pull request as ready for review December 7, 2023 18:56
@johnedquinn johnedquinn requested a review from rchowell December 7, 2023 18:56
@johnedquinn johnedquinn changed the base branch from partiql-evaluator to partiql-eval December 7, 2023 19:29
@rchowell rchowell merged commit 941a760 into partiql-eval Dec 7, 2023
@rchowell rchowell deleted the partiql-engine branch December 7, 2023 21:42
rchowell pushed a commit that referenced this pull request Dec 8, 2023
alancai98 pushed a commit that referenced this pull request Dec 12, 2023
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.

3 participants