Skip to content
This repository was archived by the owner on Jul 30, 2024. It is now read-only.

Commit 8d2b271

Browse files
authored
1 parent 549de3f commit 8d2b271

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/NuGet.Jobs.Common/JobRunner.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
using System.Linq;
99
using System.Net;
1010
using System.Threading.Tasks;
11+
using Microsoft.ApplicationInsights.Extensibility;
1112
using Microsoft.Extensions.Logging;
1213
using NuGet.Services.Logging;
1314

@@ -98,6 +99,9 @@ public static async Task Run(JobBase job, string[] commandLineArgs)
9899
{
99100
_logger.LogError("Job runner threw an exception: {Exception}", ex);
100101
}
102+
103+
Trace.Close();
104+
TelemetryConfiguration.Active.TelemetryChannel.Flush();
101105
}
102106

103107
private static ILoggerFactory ConfigureLogging(JobBase job)

0 commit comments

Comments
 (0)