Support tracking queries for complex JSON queries#36430
Merged
roji merged 1 commit intodotnet:mainfrom Jul 24, 2025
Merged
Conversation
This was referenced Jul 24, 2025
AndriySvyryd
approved these changes
Jul 24, 2025
d32525b to
8894fe4
Compare
Member
|
[like] Art Leonard reacted to your message:
…________________________________
From: Shay Rojansky ***@***.***>
Sent: Thursday, July 24, 2025 7:17:00 PM
To: dotnet/efcore ***@***.***>
Cc: Art Leonard ***@***.***>; Mention ***@***.***>
Subject: [dotnet/efcore] Support change tracking for complex JSON queries (PR #36430)
In the query shaper, we have two general paths around fixup:
* For tracking queries, the change tracker is responsible for fixup
* For non-tracking queries, we generate extra code into the shaper to do the fixup
This PR applies the non-tracking approach to complex types: since they aren't tracked separately like (owned) entities, we need to connect all complex types to their entity root.
Did some smoke testing as well with basic scenarios, everything seems to be working well.
Part of #36296<#36296>
/cc @artl93<https://github.com/artl93>
________________________________
You can view, comment on, or merge this pull request online at:
#36430
Commit Summary
* d32525b<d32525b> Support change tracking for complex JSON queries
File Changes
(5 files<https://github.com/dotnet/efcore/pull/36430/files>)
* M src/EFCore.Relational/Query/RelationalShapedQueryCompilingExpressionVisitor.ShaperProcessingExpressionVisitor.ClientMethods.cs<https://github.com/dotnet/efcore/pull/36430/files#diff-4fa317afb99b3361b9036366c92e04e91ea8c39e59cc73e57325d5cb56a822c8> (8)
* M src/EFCore.Relational/Query/RelationalShapedQueryCompilingExpressionVisitor.ShaperProcessingExpressionVisitor.cs<https://github.com/dotnet/efcore/pull/36430/files#diff-8a758d9b46935fb879ab55730abf8114f2ef437cb343f216112297a8444f8bcc> (30)
* M test/EFCore.Specification.Tests/Query/Relationships/ComplexProperties/ComplexPropertiesCollectionTestBase.cs<https://github.com/dotnet/efcore/pull/36430/files#diff-93902655175d35a9c5567035c7d926fb7e56a5e46ae6a5acabd291fd5fec3571> (15)
* M test/EFCore.Specification.Tests/Query/Relationships/ComplexProperties/ComplexPropertiesMiscellaneousTestBase.cs<https://github.com/dotnet/efcore/pull/36430/files#diff-e5632d067f3b21bb8af8f43d653c828b25f763e07d2d052a7242a2afe50dedc2> (13)
* M test/EFCore.Specification.Tests/Query/Relationships/ComplexProperties/ComplexPropertiesProjectionTestBase.cs<https://github.com/dotnet/efcore/pull/36430/files#diff-6385408029741115f5dc487f5b719ec89336430c98ae12c53fb35ff73b249dda> (13)
Patch Links:
* https://github.com/dotnet/efcore/pull/36430.patch
* https://github.com/dotnet/efcore/pull/36430.diff
—
Reply to this email directly, view it on GitHub<#36430>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ACLGGM7DSPUMVDAXHK4YVLT3KEWKZAVCNFSM6AAAAACCJVNZEKVHI2DSMVQWIX3LMV43ASLTON2WKOZTGI3DAOBZGUYTQNQ>.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
16 tasks
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
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.
In the query shaper, we have two general paths around fixup:
This PR applies the non-tracking approach to complex types: since they aren't tracked separately like (owned) entities, we need to connect all complex types to their entity root.
Did some smoke testing as well with basic scenarios, everything seems to be working well.
Part of #36296
/cc @artl93