-
Notifications
You must be signed in to change notification settings - Fork 147
Fix NullReferenceException in Rabbit. #7083
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
@@ -80,6 +80,10 @@ internal static CallTargetState OnMethodBegin<TTarget, TBasicProperties, TActivi | |||
basicProperties = CachedBasicPropertiesHelper<TReturn>.CreateHeaders(state.State!); | |||
} | |||
} | |||
else | |||
{ | |||
basicProperties = returnValue; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we could/should also change the definition of basicProperties
above to this?
TReturn basicProperties;
Alternatively, we could remove the else and change the definition to
TReturn basicProperties = returnValue;
But I think the else
is probably clearer
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
Execution-Time Benchmarks Report ⏱️Execution-time results for samples comparing the following branches/commits: Execution-time benchmarks measure the whole time it takes to execute a program. And are intended to measure the one-off costs. Cases where the execution time results for the PR are worse than latest master results are shown in red. The following thresholds were used for comparing the execution times:
Note that these results are based on a single point-in-time result for each branch. For full results, see the dashboard. Graphs show the p99 interval based on the mean and StdDev of the test run, as well as the mean value of the run (shown as a diamond below the graph). gantt
title Execution time (ms) FakeDbCommand (.NET Framework 4.8)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (7083) - mean (68ms) : 65, 70
. : milestone, 68,
master - mean (67ms) : 65, 70
. : milestone, 67,
section CallTarget+Inlining+NGEN
This PR (7083) - mean (1,009ms) : 985, 1033
. : milestone, 1009,
master - mean (1,004ms) : 983, 1024
. : milestone, 1004,
gantt
title Execution time (ms) FakeDbCommand (.NET Core 3.1)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (7083) - mean (102ms) : 100, 104
. : milestone, 102,
master - mean (102ms) : 100, 105
. : milestone, 102,
section CallTarget+Inlining+NGEN
This PR (7083) - mean (697ms) : 679, 715
. : milestone, 697,
master - mean (696ms) : 680, 713
. : milestone, 696,
gantt
title Execution time (ms) FakeDbCommand (.NET 6)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (7083) - mean (89ms) : 86, 92
. : milestone, 89,
master - mean (89ms) : 87, 91
. : milestone, 89,
section CallTarget+Inlining+NGEN
This PR (7083) - mean (658ms) : 634, 682
. : milestone, 658,
master - mean (660ms) : 630, 690
. : milestone, 660,
gantt
title Execution time (ms) HttpMessageHandler (.NET Framework 4.8)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (7083) - mean (190ms) : 186, 195
. : milestone, 190,
master - mean (190ms) : 186, 194
. : milestone, 190,
section CallTarget+Inlining+NGEN
This PR (7083) - mean (1,113ms) : 1089, 1137
. : milestone, 1113,
master - mean (1,114ms) : 1085, 1142
. : milestone, 1114,
gantt
title Execution time (ms) HttpMessageHandler (.NET Core 3.1)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (7083) - mean (270ms) : 266, 275
. : milestone, 270,
master - mean (269ms) : 266, 272
. : milestone, 269,
section CallTarget+Inlining+NGEN
This PR (7083) - mean (886ms) : 855, 916
. : milestone, 886,
master - mean (884ms) : 851, 917
. : milestone, 884,
gantt
title Execution time (ms) HttpMessageHandler (.NET 6)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (7083) - mean (263ms) : 260, 266
. : milestone, 263,
master - mean (261ms) : 258, 265
. : milestone, 261,
section CallTarget+Inlining+NGEN
This PR (7083) - mean (876ms) : 839, 912
. : milestone, 876,
master - mean (873ms) : 836, 911
. : milestone, 873,
|
Datadog ReportAll test runs ✅ 2 Total Test Services: 0 Failed, 2 Passed Test Services
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice thanks!
Thanks! |
Summary of changes
We are getting the following NullReferenceException.
We can reproduce the issue with the following code:
Reason for change
Implementation details
Test coverage
Other details