-
Notifications
You must be signed in to change notification settings - Fork 1.1k
fix: eager source row fetching logic #2071
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
Merged
Abacn
merged 1 commit into
GoogleCloudPlatform:main
from
fbiville:neo4j/group_by_synthetic_fields
Jan 7, 2025
Merged
fix: eager source row fetching logic #2071
Abacn
merged 1 commit into
GoogleCloudPlatform:main
from
fbiville:neo4j/group_by_synthetic_fields
Jan 7, 2025
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
eb82917 to
67df9a2
Compare
venikkin
approved these changes
Jan 7, 2025
Contributor
venikkin
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
67df9a2 to
4aa7a3f
Compare
This is an old bug which could only surface with the more recent addition of custom Cypher queries. The template tries to pre-fetch source data. It does it for text sources, since they do not support SQL pushdown, so their data is required for post-processing anyway. Before this commit, the template also pre-fetched data when none of the source's targets defined source transformations. This is overly restrictive and actually wrong. Custom query targets cannot define source transformations. If they share a source with a node/rel targets that define custom source transformations, then the template would crash with a NPE. This is now fixed. Source data is pre-fetched as long as there is at least one of its target that does not define any transformation. The commit also adds another small optimization: if the source does not match any active targets, the source processing is skipped completely. Before that, the data could be pre-fetched, incurring unnecessary data movement.
4aa7a3f to
1b6a2c5
Compare
venikkin
approved these changes
Jan 7, 2025
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2071 +/- ##
=========================================
Coverage 46.57% 46.57%
- Complexity 3957 3959 +2
=========================================
Files 869 869
Lines 51600 51599 -1
Branches 5404 5403 -1
=========================================
+ Hits 24031 24033 +2
+ Misses 25849 25847 -2
+ Partials 1720 1719 -1
|
Abacn
approved these changes
Jan 7, 2025
taherkl
added a commit
to ollionorg/DataflowTemplates-fork
that referenced
this pull request
Jan 8, 2025
fix: eager source row fetching logic (GoogleCloudPlatform#2071)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.