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

Process json key-values without reflection #538

Merged
merged 34 commits into from
Apr 29, 2024

Conversation

amerjusupovic
Copy link
Member

No description provided.

@amerjusupovic
Copy link
Member Author

One thing to call out, we can disable reflection-based serialization in our unit tests like I added in this PR, but I don't think we can fully test if an application is compatible with AOT without a sample project that has the <PublishAot>true</PublishAot> MSBuild property. I could add that to an existing project or create a new one solely for that purpose. I've tested it locally as AOT and the current examples worked.

@amerjusupovic amerjusupovic marked this pull request as draft April 2, 2024 20:48
@amerjusupovic amerjusupovic marked this pull request as ready for review April 2, 2024 21:17
@avanigupta
Copy link
Member

This also looks like a good candidate for migrating to Utf8JsonReader:

eventGridEventData = JsonDocument.Parse(eventGridEvent.Data.ToString()).RootElement;

@amerjusupovic amerjusupovic merged commit 7e4389b into main Apr 29, 2024
2 checks passed
@amerjusupovic amerjusupovic deleted the ajusupovic/replace-jsonserializer branch April 29, 2024 22:26
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.

System.InvalidOperationException: Reflection-based serialization has been disabled for this application
3 participants