-
-
Notifications
You must be signed in to change notification settings - Fork 210
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
Extend Trimming to all Sentry packages #2780
Comments
Doesn't really need to be on all. We don't care about the mostly deprecated stuff (we can change that decision based on feedback later though). Likel Log4Net, EntityFramework, AspNet, etc |
I added another section in the issue sescription: "Not planned" and removed Log4Net and EntityFramework from PR2793. @bitsandfoxes is going to have a got at the |
@jamescrosswell does it make sense to track the progress in this issue's description (as a checklist with project names)? |
As far as I know, for all 4 remaining projects it's the same issue (ConfigureFromConfigurationOptions)... so you wouldn't want to work on these separately. At least that's the only issue you get from the compiler - it may be a different story at runtime. At runtime, I think we're likly to hit a few scenarios where additional Json Context needs to be supplied for the sourcegen serializers to be able to serialize everything for each integratino. We figured it'd be good to spread the knowledge a bit about how this stuff works, so @bitsandfoxes is digging into this... |
Closing in favour of #2822 (as there's quite a bit of context worth capturing and too much in the details of this PR already). |
In #2732 we added the
IsAotCompatible
property toSentry.csproj
.Not planned (legacy or .net framework stuff)
Low hanging fruit
Beyond Sentry.csproj many of the other projects can have this added as well with very little modification. We can leverage the same technique to mark these as AOT compatible in the respective csproj files:
Also, if they don't already, these projects will have to target
.net6.0
or later (sinceFrameworkSupportsAot
doesn't have any effect otherwise).ConfigureFromConfigurationOptions
Some of our integrations use
ConfigureFromConfigurationOptions<TOptions>
, which isn't compatible with Trimming and we need to use the new configuration binding source generator:This affects:
Sentry.Extensions.Logging
Sentry.Maui
Sentry.Azure.Functions.Worker
Sentry.AspNetCore
This needs some investigation.
Sentry.DiagnosticSource
We don't need to do anything for
Sentry.DiagnosticSource
as it's included in the Sentry core package for all versions of .NET that support AOT:sentry-dotnet/src/Sentry/Sentry.csproj
Lines 53 to 61 in 4080ac6
The text was updated successfully, but these errors were encountered: