-
-
Notifications
You must be signed in to change notification settings - Fork 8.6k
[dotnet] [bidi] Use shared json context for core modules #16689
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
[dotnet] [bidi] Use shared json context for core modules #16689
Conversation
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
||||||||||||||||||||||||
PR Code Suggestions ✨Explore these optional code suggestions:
|
|||||||||||||||
|
Root types (with nested types) defined are not trimmable by design. Using small contexts per modules are more friendly with AOT trimming. |
User description
💥 What does this PR do?
There is no reason to create new json context per module.
💡 Additional Considerations
Using one big shared json context is better for us:
🔄 Types of changes
PR Type
Enhancement
Description
Consolidate module-specific JSON serializer contexts into single shared context
Improves performance through JSON serialization caching
Resolves cross-referencing issues between modules
Simplifies module initialization by removing per-module context creation
Diagram Walkthrough
File Walkthrough
4 files
Initialize shared JSON context at BiDi levelUpdate Module base class to use shared contextCreate unified JSON serializer context for all modulesUpdate Initialize method signature for shared context10 files
Remove module-specific context, use shared contextRemove module-specific context, use shared contextRemove module-specific context, use shared contextRemove module-specific context, use shared contextRemove module-specific context, use shared contextRemove module-specific context, use shared contextRemove module-specific context, use shared contextRemove module-specific context, use shared contextRemove module-specific context, use shared contextRemove module-specific context, use shared context