Skip to content

Merge upstream - #523

Merged
SergeiPavlov merged 104 commits into
master-servicetitanfrom
mergeUpstream
Sep 25, 2026
Merged

SergeiPavlov merged 104 commits into
master-servicetitanfrom
mergeUpstream

Conversation

@SergeiPavlov

@SergeiPavlov SergeiPavlov commented Sep 25, 2026 •

Copy link
Copy Markdown
Collaborator

Note

High Risk
Large upstream ORM merge that changes how sessions register operations, drops binary entity/operation serialization, and moves replay/serialization to the Operations extension—apps must register the extension and adopt JSON/DTO patterns.

Overview
This merge brings in DataObjects.NET 7.3.0-Beta-1 upstream work (version bump in Version.props to 7.3.37-servicetitan) centered on modularizing and modernizing change-tracking.

The Operations API is fully housed in Xtensive.Orm.Operations: concrete types, OperationRegistry/OperationFactory, capture/replay, and System.Text.Json support via AddOperationsConverters(). Binary/[Serializable] operation serialization is removed in favor of JSON converters for keys, fields, nested operations, and polymorphic Operation types. OperationLog.Replay now runs only IExecutableOperation instances and reaches persistence through DirectEntityAccessor / DirectEntitySetAccessor on OperationExecutionContext. A new Xtensive.Orm.Operations.Tests project exercises capture, ordering, replay, and JSON round-trip.

Aligned with the changelog, related extensions drop [Serializable] (e.g. localization entities/config), and release notes document broader 7.3 breaking themes: no default operation registration (faster entities), no binary serialization on Entity/EntitySet, and SerializableExpressions moved to its own extension.

Reviewed by Cursor Bugbot for commit 5c5fa42. Bugbot is set up for automated code reviews on this repo. Configure here.

Base constructor is marked as obsolete as well as ours, NET 10 removes
them completely
- No ISerializable based serialization
- Added support for serialization via DataContract and JsonSerializer
- Added tests and fixed some issues (some of fixes were ported from main branch)
- Delete test (the case is already covered in another test)
- Cloning via BinaryFormatter is marked as obsolete until in use
- Added Cloning via DataContractSerializer, DataContractJsonSerializer
  and JsonSerializer
- added domains of types to use them for DataContract-based serialization
- Xtensive.Orm contains only API basis and usage to create and register
  operations.
- All the real operations are outside main library, it made creation,
  modification, deletion of Entities faster when no registration needed,
  as well as EntitySet.Add/Remove/Clear operations
Before that, EntityFieldSet operation grabbed persistent object, which
exists in session context, so it is not good.
Now there is NestedOperations collection for all nested fields that persistent
structure suppose to change on Field change
and also some of tests of serialization
- Binary serialization is almost eliminated in .NET, there is no point of them
to be serializable
alex-kulakov and others added 24 commits September 1, 2026 16:23
- created base type with separated tests for each target type (get from CombinedTest)
- main tests were moved to new generic base type
- make converstion based testing, if there is a conversion test runs, otherwise ignored
- added DateOnly/TimeOnly conversion test
- info messages replaced to error messages in log in case of exceptions
- add category for tests
- use log only if it is enabled
- json converters that can serialize
- Extension to add the converters (domain required including)
# Conflicts:
#	ChangeLog/7.3.0-Beta-1-dev.txt
#	Extensions/Xtensive.Orm.Operations/Operations/EntitySetOperation.cs
#	Extensions/Xtensive.Orm.SerializableExpressions/Internals/SerializableExpressionToExpressionConverter.cs
#	Orm.sln
#	Orm/Xtensive.Orm.Tests.Core/Linq/SerializableExpressionsTest.cs
#	Orm/Xtensive.Orm.Tests.Core/Tuples/TupleDescriptorTest.cs
#	Orm/Xtensive.Orm.Tests.Framework/Internals/InstanceGeneratorBase.cs
#	Orm/Xtensive.Orm.Tests/Interfaces/KeyStructureConflictTest.cs
#	Orm/Xtensive.Orm.Tests/Interfaces/TypeIdModeConflictTest.cs
#	Orm/Xtensive.Orm.Tests/Interfaces/UnusedTypeRemovalTest.cs
#	Orm/Xtensive.Orm.Tests/Issues/Issue0262_StructureAssignment.cs
#	Orm/Xtensive.Orm.Tests/Issues/IssueJira0197_ExtendedErrorInformation.cs
#	Orm/Xtensive.Orm.Tests/Linq/CustomExpressionCompilers.cs
#	Orm/Xtensive.Orm/Arithmetic/ArithmeticBase.cs
#	Orm/Xtensive.Orm/Collections/Deque.cs
#	Orm/Xtensive.Orm/Collections/ExtensionCollection.cs
#	Orm/Xtensive.Orm/Collections/FixedList3.cs
#	Orm/Xtensive.Orm/Collections/Graphs/Edge.cs
#	Orm/Xtensive.Orm/Collections/TypeRegistration.cs
#	Orm/Xtensive.Orm/Collections/TypeRegistrationProcessorBase.cs
#	Orm/Xtensive.Orm/Collections/TypeRegistry.cs
#	Orm/Xtensive.Orm/Conversion/AdvancedConverterBase.cs
#	Orm/Xtensive.Orm/Conversion/Internals/ConvertingEnumerator.cs
#	Orm/Xtensive.Orm/Linq/Internals/ExpressionComparer.cs
#	Orm/Xtensive.Orm/Linq/SerializableExpressions/Internals/ExpressionToSerializableExpressionConverter.cs
#	Orm/Xtensive.Orm/Linq/SerializableExpressions/Internals/ReflectionExtensions.cs
#	Orm/Xtensive.Orm/Modelling/Actions/PropertyChangeAction.cs
#	Orm/Xtensive.Orm/Modelling/Actions/RemoveNodeAction.cs
#	Orm/Xtensive.Orm/Modelling/Comparison/Hints/CopyDataHint.cs
#	Orm/Xtensive.Orm/Modelling/Comparison/Hints/UpdateDataHint.cs
#	Orm/Xtensive.Orm/Modelling/NodeCollection.cs
#	Orm/Xtensive.Orm/Orm/Configuration/NameMappingCollection.cs
#	Orm/Xtensive.Orm/Orm/EntitySetBase.cs
#	Orm/Xtensive.Orm/Orm/Internals/EntitySetTypeState.cs
#	Orm/Xtensive.Orm/Orm/Internals/Prefetch/ReferencedEntityContainer.cs
#	Orm/Xtensive.Orm/Orm/Model/TypeDiscriminatorMap.cs
#	Orm/Xtensive.Orm/Orm/Operations/KeySetOperation.cs
#	Orm/Xtensive.Orm/Orm/Rse/AggregateColumn.cs
#	Orm/Xtensive.Orm/Orm/Rse/CalculatedColumn.cs
#	Orm/Xtensive.Orm/Orm/Rse/MappedColumn.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/AggregateProvider.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/AliasProvider.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/CalculateProvider.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/ExceptProvider.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/FilterProvider.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/IncludeProvider.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/IntersectProvider.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/JoinProvider.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/OrderProviderBase.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/PredicateJoinProvider.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Compilable/RawProvider.cs
#	Orm/Xtensive.Orm/Orm/Rse/Providers/Provider.cs
#	Orm/Xtensive.Orm/Orm/Rse/SystemColumn.cs
#	Orm/Xtensive.Orm/Orm/Serialization/SerializationContext.cs
#	Orm/Xtensive.Orm/Orm/Upgrade/Model/PrimaryIndexInfo.cs
#	Orm/Xtensive.Orm/Orm/Upgrade/Model/SecondaryIndexInfo.cs
#	Orm/Xtensive.Orm/Orm/Upgrade/Model/StorageFullTextIndexInfo.cs
#	Orm/Xtensive.Orm/Sorting/Node.cs
#	Orm/Xtensive.Orm/Sql/Ddl/SqlAlterSequence.cs
#	Orm/Xtensive.Orm/Sql/Dml/Expressions/SqlCase.cs
#	Orm/Xtensive.Orm/Sql/Dml/Expressions/SqlCursor.cs
#	Orm/Xtensive.Orm/Sql/Dml/Expressions/SqlDefaultValue.cs
#	Orm/Xtensive.Orm/Sql/Model/Sequence.cs
#	Orm/Xtensive.Orm/Tuples/Transform/CombineTransform.cs
#	Orm/Xtensive.Orm/Tuples/Transform/Internals/MapTransformTuple.cs
#	Orm/Xtensive.Orm/Tuples/Transform/Internals/MapTransformTuple1.cs
#	Orm/Xtensive.Orm/Tuples/Transform/Internals/MapTransformTuple3.cs
#	Orm/Xtensive.Orm/Tuples/Transform/Internals/ReadOnlyTransformTuple.cs
#	Orm/Xtensive.Orm/Tuples/Transform/MapTransform.cs
#	Orm/Xtensive.Orm/Tuples/Transform/ReadOnlyTransform.cs
#	Orm/Xtensive.Orm/Tuples/Transform/TransformedTuple.cs
#	Orm/Xtensive.Orm/Tuples/Transform/TransformedTuple{TTupleTransform}.cs
#	Orm/Xtensive.Orm/Tuples/Transform/TupleTransformBase.cs
#	Orm/Xtensive.Orm/Tuples/Transform/WrappingTransformTupleBase.cs
#	Orm/Xtensive.Orm/Tuples/TupleDescriptor.cs
new items + typo fixed
Remove obsolete serialization + other "side-dish" changes

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes using default effort and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 198e421. Configure here.

Assert.That(book22.NumberOfPages, Is.EqualTo(25));

var book23 = books.FirstOrDefault(b => b.Title == "Single way to eat banana");
Assert.That(book23, Is.Not.Null);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Replay test asserts wrong books

Medium Severity

The replay scenario removes the last author2 book (Single way to eat banana) and keeps 100 ways to not live, but the assertions expect the opposite. A correct replay fails this test, and author2.Books.Contains(book23) depends on that inverted existence check.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 198e421. Configure here.

@SergeiPavlov
SergeiPavlov merged commit 74a379c into master-servicetitan Sep 25, 2026
6 checks passed
@SergeiPavlov
SergeiPavlov deleted the mergeUpstream branch September 25, 2026 19:49
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