Example #1
0
 /// <summary>
 /// Transmit all internal buffers to the end-point and dispose channel.
 /// </summary>
 /// <param name="token">Cancellation token</param>
 /// <returns></returns>
 public async Task DisposeAndTransmitAsync(CancellationToken token)
 {
     base.DisposeManagedResources();
     if (appInsightsChannel != null)
     {
         try
         {
             await appInsightsClient.FlushAndTransmitAsync(token).ConfigureAwait(false);
         }
         catch (FileNotFoundException)
         {
         }
         DisposeChannel();
     }
 }