From 9e0da339839ea4f11ac25860ec46fe42f41cacbd Mon Sep 17 00:00:00 2001 From: Claudiu Guiman Date: Mon, 14 May 2018 09:42:07 -0700 Subject: [PATCH 1/3] Add netstandard2.0 target for ServerTelemetryChannel and remove Newtonsoft.Json dependency (#800) --- Common.props | 7 ++- .../netstandard2.0/PublicAPI.Shipped.txt | 59 +++++++++++++++++++ .../netstandard2.0/PublicAPI.Unshipped.txt | 39 ++++++++++++ .../ApplicationFolderProvider.cs | 4 +- .../Implementation/BackendResponse.cs | 4 +- .../Implementation/BackoffLogicManager.cs | 20 +++++-- .../Implementation/TelemetryBuffer.cs | 2 +- .../TelemetryChannelEventSource.cs | 2 +- .../Implementation/WebApplicationLifecycle.cs | 2 +- .../ServerTelemetryChannel.cs | 4 +- .../TelemetryChannel.csproj | 20 ++++++- 11 files changed, 144 insertions(+), 19 deletions(-) create mode 100644 PublicAPI/Microsoft.AI.ServerTelemetryChannel.dll/netstandard2.0/PublicAPI.Shipped.txt create mode 100644 PublicAPI/Microsoft.AI.ServerTelemetryChannel.dll/netstandard2.0/PublicAPI.Unshipped.txt diff --git a/Common.props b/Common.props index cc4a49956d..30d946a42d 100644 --- a/Common.props +++ b/Common.props @@ -21,11 +21,14 @@ $([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildProjectDirectory), 'ApplicationInsightsSDKRules.ruleset'))\ApplicationInsightsSDKRules.ruleset + + true + true + + pdbonly true - true - true true $(DefineConstants);TRACE diff --git a/PublicAPI/Microsoft.AI.ServerTelemetryChannel.dll/netstandard2.0/PublicAPI.Shipped.txt b/PublicAPI/Microsoft.AI.ServerTelemetryChannel.dll/netstandard2.0/PublicAPI.Shipped.txt new file mode 100644 index 0000000000..7e7bf0a310 --- /dev/null +++ b/PublicAPI/Microsoft.AI.ServerTelemetryChannel.dll/netstandard2.0/PublicAPI.Shipped.txt @@ -0,0 +1,59 @@ +Microsoft.ApplicationInsights.Extensibility.TelemetryProcessorChainBuilderExtensions +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.AdaptiveSamplingTelemetryProcessor(Microsoft.ApplicationInsights.Extensibility.ITelemetryProcessor next) -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.AdaptiveSamplingTelemetryProcessor(Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings settings, Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.AdaptiveSamplingPercentageEvaluatedCallback callback, Microsoft.ApplicationInsights.Extensibility.ITelemetryProcessor next) -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.Dispose() -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.EvaluationInterval.get -> System.TimeSpan +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.EvaluationInterval.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.ExcludedTypes.get -> string +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.ExcludedTypes.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.IncludedTypes.get -> string +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.IncludedTypes.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.InitialSamplingPercentage.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.InitialSamplingPercentage.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.MaxSamplingPercentage.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.MaxSamplingPercentage.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.MaxTelemetryItemsPerSecond.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.MaxTelemetryItemsPerSecond.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.MinSamplingPercentage.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.MinSamplingPercentage.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.MovingAverageRatio.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.MovingAverageRatio.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.Process(Microsoft.ApplicationInsights.Channel.ITelemetry item) -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.SamplingPercentageDecreaseTimeout.get -> System.TimeSpan +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.SamplingPercentageDecreaseTimeout.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.SamplingPercentageIncreaseTimeout.get -> System.TimeSpan +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.SamplingPercentageIncreaseTimeout.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.AdaptiveSamplingPercentageEvaluatedCallback +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.EvaluationInterval.get -> System.TimeSpan +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.EvaluationInterval.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.InitialSamplingPercentage.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.InitialSamplingPercentage.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.MaxSamplingPercentage.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.MaxSamplingPercentage.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.MaxTelemetryItemsPerSecond.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.MaxTelemetryItemsPerSecond.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.MinSamplingPercentage.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.MinSamplingPercentage.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.MovingAverageRatio.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.MovingAverageRatio.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.SamplingPercentageDecreaseTimeout.get -> System.TimeSpan +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.SamplingPercentageDecreaseTimeout.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.SamplingPercentageEstimatorSettings() -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.SamplingPercentageIncreaseTimeout.get -> System.TimeSpan +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings.SamplingPercentageIncreaseTimeout.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.SamplingTelemetryProcessor +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.SamplingTelemetryProcessor.ExcludedTypes.get -> string +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.SamplingTelemetryProcessor.ExcludedTypes.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.SamplingTelemetryProcessor.IncludedTypes.get -> string +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.SamplingTelemetryProcessor.IncludedTypes.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.SamplingTelemetryProcessor.Process(Microsoft.ApplicationInsights.Channel.ITelemetry item) -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.SamplingTelemetryProcessor.SamplingPercentage.get -> double +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.SamplingTelemetryProcessor.SamplingPercentage.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.SamplingTelemetryProcessor.SamplingTelemetryProcessor(Microsoft.ApplicationInsights.Extensibility.ITelemetryProcessor next) -> void +static Microsoft.ApplicationInsights.Extensibility.TelemetryProcessorChainBuilderExtensions.UseAdaptiveSampling(this Microsoft.ApplicationInsights.Extensibility.Implementation.TelemetryProcessorChainBuilder builder, Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.SamplingPercentageEstimatorSettings settings, Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.AdaptiveSamplingPercentageEvaluatedCallback callback, string excludedTypes = null, string includedTypes = null) -> Microsoft.ApplicationInsights.Extensibility.Implementation.TelemetryProcessorChainBuilder +static Microsoft.ApplicationInsights.Extensibility.TelemetryProcessorChainBuilderExtensions.UseAdaptiveSampling(this Microsoft.ApplicationInsights.Extensibility.Implementation.TelemetryProcessorChainBuilder builder, double maxTelemetryItemsPerSecond, string excludedTypes = null, string includedTypes = null) -> Microsoft.ApplicationInsights.Extensibility.Implementation.TelemetryProcessorChainBuilder +static Microsoft.ApplicationInsights.Extensibility.TelemetryProcessorChainBuilderExtensions.UseAdaptiveSampling(this Microsoft.ApplicationInsights.Extensibility.Implementation.TelemetryProcessorChainBuilder builder, string excludedTypes = null, string includedTypes = null) -> Microsoft.ApplicationInsights.Extensibility.Implementation.TelemetryProcessorChainBuilder +static Microsoft.ApplicationInsights.Extensibility.TelemetryProcessorChainBuilderExtensions.UseSampling(this Microsoft.ApplicationInsights.Extensibility.Implementation.TelemetryProcessorChainBuilder builder, double samplingPercentage, string excludedTypes = null, string includedTypes = null) -> Microsoft.ApplicationInsights.Extensibility.Implementation.TelemetryProcessorChainBuilder +virtual Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.AdaptiveSamplingTelemetryProcessor.Dispose(bool disposing) -> void \ No newline at end of file diff --git a/PublicAPI/Microsoft.AI.ServerTelemetryChannel.dll/netstandard2.0/PublicAPI.Unshipped.txt b/PublicAPI/Microsoft.AI.ServerTelemetryChannel.dll/netstandard2.0/PublicAPI.Unshipped.txt new file mode 100644 index 0000000000..bf9bf9ea8c --- /dev/null +++ b/PublicAPI/Microsoft.AI.ServerTelemetryChannel.dll/netstandard2.0/PublicAPI.Unshipped.txt @@ -0,0 +1,39 @@ +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.ApplicationStoppingEventArgs +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.ApplicationStoppingEventArgs.ApplicationStoppingEventArgs(System.Func, System.Threading.Tasks.Task> asyncMethodRunner) -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.ApplicationStoppingEventArgs.Run(System.Func asyncMethod) -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.IApplicationLifecycle +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.IApplicationLifecycle.Started -> System.Action +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation.IApplicationLifecycle.Stopping -> System.EventHandler +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.DefaultBackoffEnabledReportingInterval.get -> System.TimeSpan +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.DefaultBackoffEnabledReportingInterval.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.DeveloperMode.get -> bool? +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.DeveloperMode.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.Dispose() -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.EnableLocalThrottling.get -> bool +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.EnableLocalThrottling.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.EndpointAddress.get -> string +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.EndpointAddress.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.Flush() -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.Initialize(Microsoft.ApplicationInsights.Extensibility.TelemetryConfiguration configuration) -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.LocalThrottleLimit.get -> int +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.LocalThrottleLimit.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.LocalThrottleWindow.get -> int +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.LocalThrottleWindow.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxBacklogSize.get -> int +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxBacklogSize.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxTelemetryBufferCapacity.get -> int +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxTelemetryBufferCapacity.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxTelemetryBufferDelay.get -> System.TimeSpan +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxTelemetryBufferDelay.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxTransmissionBufferCapacity.get -> int +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxTransmissionBufferCapacity.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxTransmissionSenderCapacity.get -> int +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxTransmissionSenderCapacity.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxTransmissionStorageCapacity.get -> long +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.MaxTransmissionStorageCapacity.set -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.Send(Microsoft.ApplicationInsights.Channel.ITelemetry item) -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.ServerTelemetryChannel() -> void +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.StorageFolder.get -> string +Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.ServerTelemetryChannel.StorageFolder.set -> void +Microsoft.ApplicationInsights.WindowsServer.Channel.Implementation.SamplingPercentageEstimatorSettings \ No newline at end of file diff --git a/src/ServerTelemetryChannel/Implementation/ApplicationFolderProvider.cs b/src/ServerTelemetryChannel/Implementation/ApplicationFolderProvider.cs index b485b297a8..539927a0ae 100644 --- a/src/ServerTelemetryChannel/Implementation/ApplicationFolderProvider.cs +++ b/src/ServerTelemetryChannel/Implementation/ApplicationFolderProvider.cs @@ -134,7 +134,7 @@ private static string GetSHA256Hash(string input) private static SHA256 CreateSHA256() { -#if NETSTANDARD1_3 +#if NETSTANDARD return SHA256.Create(); #else return new SHA256CryptoServiceProvider(); @@ -208,7 +208,7 @@ private DirectoryInfo CreateTelemetrySubdirectory(DirectoryInfo root) { string baseDirectory = string.Empty; -#if !NETSTANDARD1_3 +#if !NETSTANDARD baseDirectory = AppDomain.CurrentDomain.BaseDirectory; #else baseDirectory = AppContext.BaseDirectory; diff --git a/src/ServerTelemetryChannel/Implementation/BackendResponse.cs b/src/ServerTelemetryChannel/Implementation/BackendResponse.cs index 74825439e7..5470dd76b1 100644 --- a/src/ServerTelemetryChannel/Implementation/BackendResponse.cs +++ b/src/ServerTelemetryChannel/Implementation/BackendResponse.cs @@ -5,10 +5,10 @@ [DataContract] internal class BackendResponse { - [DataMember(Name = "itemsReceived")] + [DataMember(Name = "itemsReceived", IsRequired=true)] public int ItemsReceived { get; set; } - [DataMember(Name = "itemsAccepted")] + [DataMember(Name = "itemsAccepted", IsRequired = true)] public int ItemsAccepted { get; set; } [DataMember(Name = "errors")] diff --git a/src/ServerTelemetryChannel/Implementation/BackoffLogicManager.cs b/src/ServerTelemetryChannel/Implementation/BackoffLogicManager.cs index b44c2500a9..117643ca66 100644 --- a/src/ServerTelemetryChannel/Implementation/BackoffLogicManager.cs +++ b/src/ServerTelemetryChannel/Implementation/BackoffLogicManager.cs @@ -1,10 +1,13 @@ namespace Microsoft.ApplicationInsights.Channel.Implementation { using System; + using System.Runtime.Serialization; #if NETSTANDARD1_3 using Newtonsoft.Json; #else - using System.Web.Script.Serialization; + using System.IO; + using System.Runtime.Serialization.Json; + using System.Text; #endif using Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation; @@ -17,8 +20,8 @@ internal class BackoffLogicManager private static readonly Random Random = new Random(); -#if !NETSTANDARD1_3 - private static readonly JavaScriptSerializer Serializer = new JavaScriptSerializer(); +#if !NETSTANDARD1_3 + private static readonly DataContractJsonSerializer Serializer = new DataContractJsonSerializer(typeof(BackendResponse)); #endif private readonly object lockConsecutiveErrors = new object(); @@ -77,7 +80,10 @@ public BackendResponse GetBackendResponse(string responseContent) #if NETSTANDARD1_3 backendResponse = JsonConvert.DeserializeObject(responseContent); #else - backendResponse = Serializer.Deserialize(responseContent); + using (MemoryStream ms = new MemoryStream(Encoding.Unicode.GetBytes(responseContent))) + { + backendResponse = Serializer.ReadObject(ms) as BackendResponse; + } #endif } } @@ -91,6 +97,11 @@ public BackendResponse GetBackendResponse(string responseContent) TelemetryChannelEventSource.Log.BreezeResponseWasNotParsedWarning(exp.Message, responseContent); backendResponse = null; } + catch (SerializationException exp) + { + TelemetryChannelEventSource.Log.BreezeResponseWasNotParsedWarning(exp.Message, responseContent); + backendResponse = null; + } #if NETSTANDARD1_3 catch (JsonReaderException exp) { @@ -103,7 +114,6 @@ public BackendResponse GetBackendResponse(string responseContent) backendResponse = null; } #endif - return backendResponse; } diff --git a/src/ServerTelemetryChannel/Implementation/TelemetryBuffer.cs b/src/ServerTelemetryChannel/Implementation/TelemetryBuffer.cs index 51d65c3d29..bc2d84977b 100644 --- a/src/ServerTelemetryChannel/Implementation/TelemetryBuffer.cs +++ b/src/ServerTelemetryChannel/Implementation/TelemetryBuffer.cs @@ -32,7 +32,7 @@ public TelemetryBuffer(TelemetrySerializer serializer, IApplicationLifecycle app throw new ArgumentNullException("serializer"); } -#if !NETSTANDARD1_3 +#if !NETSTANDARD // We don't have implementation for IApplicationLifecycle for .NET Core if (applicationLifecycle == null) { diff --git a/src/ServerTelemetryChannel/Implementation/TelemetryChannelEventSource.cs b/src/ServerTelemetryChannel/Implementation/TelemetryChannelEventSource.cs index 47c536cd91..21d6cce580 100644 --- a/src/ServerTelemetryChannel/Implementation/TelemetryChannelEventSource.cs +++ b/src/ServerTelemetryChannel/Implementation/TelemetryChannelEventSource.cs @@ -499,7 +499,7 @@ private string GetApplicationName() string name; try { -#if !NETSTANDARD1_3 +#if !NETSTANDARD name = AppDomain.CurrentDomain.FriendlyName; #else name = string.Empty; diff --git a/src/ServerTelemetryChannel/Implementation/WebApplicationLifecycle.cs b/src/ServerTelemetryChannel/Implementation/WebApplicationLifecycle.cs index 783f460f14..754dceeddc 100644 --- a/src/ServerTelemetryChannel/Implementation/WebApplicationLifecycle.cs +++ b/src/ServerTelemetryChannel/Implementation/WebApplicationLifecycle.cs @@ -1,4 +1,4 @@ -#if !NETSTANDARD1_3 +#if !NETSTANDARD namespace Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation { using System; diff --git a/src/ServerTelemetryChannel/ServerTelemetryChannel.cs b/src/ServerTelemetryChannel/ServerTelemetryChannel.cs index fdfda5b528..b413c479a7 100644 --- a/src/ServerTelemetryChannel/ServerTelemetryChannel.cs +++ b/src/ServerTelemetryChannel/ServerTelemetryChannel.cs @@ -26,7 +26,7 @@ public sealed class ServerTelemetryChannel : ITelemetryChannel, ITelemetryModule /// /// Initializes a new instance of the class. /// -#if !NETSTANDARD1_3 +#if !NETSTANDARD public ServerTelemetryChannel() : this(new Network(), new WebApplicationLifecycle()) #else // TODO: IApplicationLifecycle implemenation for netcore need to be written instead of null here. @@ -39,7 +39,7 @@ internal ServerTelemetryChannel(INetwork network, IApplicationLifecycle applicat { var policies = new TransmissionPolicy[] { -#if !NETSTANDARD1_3 +#if !NETSTANDARD // We don't have implementation for IApplicationLifecycle for .NET Core new ApplicationLifecycleTransmissionPolicy(applicationLifecycle), #endif diff --git a/src/ServerTelemetryChannel/TelemetryChannel.csproj b/src/ServerTelemetryChannel/TelemetryChannel.csproj index 5c02759a95..eb3b265d4e 100644 --- a/src/ServerTelemetryChannel/TelemetryChannel.csproj +++ b/src/ServerTelemetryChannel/TelemetryChannel.csproj @@ -11,8 +11,8 @@ false false - net45;netstandard1.3 - netstandard1.3 + net45;netstandard1.3;netstandard2.0 + netstandard1.3;netstandard2.0 True @@ -41,9 +41,20 @@ TRACE;DEBUG;NETCORE;NETSTANDARD1_3 + TRACE;DEBUG;NETCORE;NETSTANDARD2_0 TRACE;DEBUG;NET45 + + $(DefineConstants);NETSTANDARD + $(DefineConstants);NETSTANDARD + + + + True + True + + All @@ -87,7 +98,7 @@ - + @@ -97,6 +108,9 @@ + + + From 731c5d3206dc071d286d52ece2cfcbdc7fccaef1 Mon Sep 17 00:00:00 2001 From: Claudiu Guiman Date: Mon, 14 May 2018 14:28:43 -0700 Subject: [PATCH 2/3] Add TelemetryChannel tests for netcoreapp2.0 --- .vsts/linux-build.yml | 14 ++++- Microsoft.ApplicationInsights.sln | 23 ++++++++ .../ApplicationInsightsTypes.csproj | 4 +- ...ApplicationInsights.Shared.Tests.projitems | 6 ++- ...licationInsights.netcoreapp11.Tests.csproj | 1 + ...TelemetryChannel.netcoreapp11.Tests.csproj | 1 + ...TelemetryChannel.netcoreapp20.Tests.csproj | 52 +++++++++++++++++++ .../Implementation/BackoffLogicManagerTest.cs | 2 +- .../Implementation/FileSystemTest.cs | 2 +- .../Implementation/PlatformFileTest.cs | 2 +- .../Implementation/PlatformFolderTest.cs | 2 +- .../Implementation/TelemetryBufferTest.cs | 2 +- .../ServerTelemetryChannelTest.cs | 2 +- .../Shared.Tests/Shared.Tests.projitems | 8 ++- Test/TestFramework/Shared/EventSourceTest.cs | 2 +- .../Properties/AssemblyInfo.cs | 1 + src/ServerTelemetryChannel/AssemblyInfo.cs | 1 + 17 files changed, 112 insertions(+), 13 deletions(-) create mode 100644 Test/ServerTelemetryChannel.Test/NetCore20.Tests/TelemetryChannel.netcoreapp20.Tests.csproj diff --git a/.vsts/linux-build.yml b/.vsts/linux-build.yml index 3c36010d41..da01572659 100644 --- a/.vsts/linux-build.yml +++ b/.vsts/linux-build.yml @@ -3,7 +3,7 @@ queue: steps: - task: DotNetCoreInstaller@0 inputs: - version: "1.1.5" + version: "2.0.3" - task: DotNetCoreCLI@1 inputs: @@ -19,7 +19,17 @@ steps: - task: DotNetCoreCLI@1 inputs: command: "test" - projects: "Test/**/*netcore*.csproj" + projects: "Test/**/*netcoreapp20*.csproj" + arguments: "--configuration Release --filter TestCategory!=WindowsOnly" + +- task: DotNetCoreInstaller@0 + inputs: + version: "1.1.5" + +- task: DotNetCoreCLI@1 + inputs: + command: "test" + projects: "Test/**/*netcoreapp11*.csproj" arguments: "--configuration Release --filter TestCategory!=WindowsOnly" - task: PublishTestResults@2 diff --git a/Microsoft.ApplicationInsights.sln b/Microsoft.ApplicationInsights.sln index 20165180fc..7eea38ca81 100644 --- a/Microsoft.ApplicationInsights.sln +++ b/Microsoft.ApplicationInsights.sln @@ -59,6 +59,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.ApplicationInsigh EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TelemetryChannel.netcoreapp11.Tests", "Test\ServerTelemetryChannel.Test\NetCore.Tests\TelemetryChannel.netcoreapp11.Tests.csproj", "{3D0DEB59-1297-44F6-9D0C-D075E98A85F8}" EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TelemetryChannel.netcoreapp20.Tests", "Test\ServerTelemetryChannel.Test\NetCore20.Tests\TelemetryChannel.netcoreapp20.Tests.csproj", "{14FA551E-886A-4D1B-B716-567EB4954C8E}" +EndProject Global GlobalSection(SharedMSBuildProjectFiles) = preSolution Test\Microsoft.ApplicationInsights.Test\Shared\Microsoft.ApplicationInsights.Shared.Tests.projitems*{0927e682-4a56-45b6-8125-94fa066b2f57}*SharedItemsImports = 4 @@ -284,6 +286,26 @@ Global {3D0DEB59-1297-44F6-9D0C-D075E98A85F8}.Release|x64.Build.0 = Release|Any CPU {3D0DEB59-1297-44F6-9D0C-D075E98A85F8}.Release|x86.ActiveCfg = Release|Any CPU {3D0DEB59-1297-44F6-9D0C-D075E98A85F8}.Release|x86.Build.0 = Release|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Debug|Any CPU.Build.0 = Debug|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Debug|ARM.ActiveCfg = Debug|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Debug|ARM.Build.0 = Debug|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Debug|x64.ActiveCfg = Debug|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Debug|x64.Build.0 = Debug|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Debug|x86.ActiveCfg = Debug|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Debug|x86.Build.0 = Debug|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Release|Any CPU.ActiveCfg = Release|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Release|Any CPU.Build.0 = Release|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Release|ARM.ActiveCfg = Release|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Release|ARM.Build.0 = Release|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Release|Mixed Platforms.Build.0 = Release|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Release|x64.ActiveCfg = Release|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Release|x64.Build.0 = Release|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Release|x86.ActiveCfg = Release|Any CPU + {14FA551E-886A-4D1B-B716-567EB4954C8E}.Release|x86.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -302,6 +324,7 @@ Global {3273D899-D9B3-44FE-B3AB-578E18B2EF90} = {E7B0521E-DA4D-40EA-B55D-ADCBDA69027C} {178F87BF-CCCA-48DE-B171-4482E8CBD060} = {C2FEEDE5-8CAE-41A4-8932-42D284A86EA7} {3D0DEB59-1297-44F6-9D0C-D075E98A85F8} = {A61B048F-ECEA-4BED-A2ED-22834E7D4DFB} + {14FA551E-886A-4D1B-B716-567EB4954C8E} = {A61B048F-ECEA-4BED-A2ED-22834E7D4DFB} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {F70D4C7C-02FB-4EE9-875A-A2F95EC90EAC} diff --git a/Test/Microsoft.ApplicationInsights.Test/ApplicationInsightsTypes/ApplicationInsightsTypes.csproj b/Test/Microsoft.ApplicationInsights.Test/ApplicationInsightsTypes/ApplicationInsightsTypes.csproj index da041c5375..5f1778287c 100644 --- a/Test/Microsoft.ApplicationInsights.Test/ApplicationInsightsTypes/ApplicationInsightsTypes.csproj +++ b/Test/Microsoft.ApplicationInsights.Test/ApplicationInsightsTypes/ApplicationInsightsTypes.csproj @@ -10,8 +10,8 @@ false false - net45;netstandard1.3 - netstandard1.3 + net45;netstandard1.3;netstandard2.0 + netstandard1.3;netstandard2.0 {4B0BC3B7-C7FC-4333-9E28-5790D9153F07} ApplicationInsightsTypes diff --git a/Test/Microsoft.ApplicationInsights.Test/Shared/Microsoft.ApplicationInsights.Shared.Tests.projitems b/Test/Microsoft.ApplicationInsights.Test/Shared/Microsoft.ApplicationInsights.Shared.Tests.projitems index 9b2ad308f2..3f7179a47d 100644 --- a/Test/Microsoft.ApplicationInsights.Test/Shared/Microsoft.ApplicationInsights.Shared.Tests.projitems +++ b/Test/Microsoft.ApplicationInsights.Test/Shared/Microsoft.ApplicationInsights.Shared.Tests.projitems @@ -119,7 +119,11 @@ - + + True + True + + diff --git a/Test/Microsoft.ApplicationInsights.Test/netcoreapp11/Microsoft.ApplicationInsights.netcoreapp11.Tests.csproj b/Test/Microsoft.ApplicationInsights.Test/netcoreapp11/Microsoft.ApplicationInsights.netcoreapp11.Tests.csproj index a30f167501..50765a7f62 100644 --- a/Test/Microsoft.ApplicationInsights.Test/netcoreapp11/Microsoft.ApplicationInsights.netcoreapp11.Tests.csproj +++ b/Test/Microsoft.ApplicationInsights.Test/netcoreapp11/Microsoft.ApplicationInsights.netcoreapp11.Tests.csproj @@ -12,6 +12,7 @@ netcoreapp1.1 pdbonly true + $(DefineConstants);NETCOREAPP diff --git a/Test/ServerTelemetryChannel.Test/NetCore.Tests/TelemetryChannel.netcoreapp11.Tests.csproj b/Test/ServerTelemetryChannel.Test/NetCore.Tests/TelemetryChannel.netcoreapp11.Tests.csproj index 8848a85878..41ce7352c2 100644 --- a/Test/ServerTelemetryChannel.Test/NetCore.Tests/TelemetryChannel.netcoreapp11.Tests.csproj +++ b/Test/ServerTelemetryChannel.Test/NetCore.Tests/TelemetryChannel.netcoreapp11.Tests.csproj @@ -14,6 +14,7 @@ Microsoft.ApplicationInsights.TelemetryChannel.NetCore.Tests pdbonly true + $(DefineConstants);NETCOREAPP diff --git a/Test/ServerTelemetryChannel.Test/NetCore20.Tests/TelemetryChannel.netcoreapp20.Tests.csproj b/Test/ServerTelemetryChannel.Test/NetCore20.Tests/TelemetryChannel.netcoreapp20.Tests.csproj new file mode 100644 index 0000000000..204d457bd0 --- /dev/null +++ b/Test/ServerTelemetryChannel.Test/NetCore20.Tests/TelemetryChannel.netcoreapp20.Tests.csproj @@ -0,0 +1,52 @@ + + + + + {14FA551E-886A-4D1B-B716-567EB4954C8E} + false + false + false + false + false + false + false + false + netcoreapp2.0 + Microsoft.ApplicationInsights.TelemetryChannel.NetCore20.Tests + pdbonly + true + $(DefineConstants);NETCOREAPP + + + + + + + + + + + + + + + + + + + + + + All + + + + + + + + + + + + diff --git a/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/BackoffLogicManagerTest.cs b/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/BackoffLogicManagerTest.cs index afb70761c1..6224161e90 100644 --- a/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/BackoffLogicManagerTest.cs +++ b/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/BackoffLogicManagerTest.cs @@ -103,7 +103,7 @@ public void FirstErrorDelayIsSameAsSlotDelay() [TestMethod] public void UpperBoundOfDelayIsMaxDelay() { -#if !NETCOREAPP1_1 +#if !NETCOREAPP var manager = new BackoffLogicManager(TimeSpan.Zero, TimeSpan.Zero); PrivateObject wrapper = new PrivateObject(manager); diff --git a/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/FileSystemTest.cs b/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/FileSystemTest.cs index e6df125f1f..834daa327f 100644 --- a/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/FileSystemTest.cs +++ b/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/FileSystemTest.cs @@ -1,6 +1,6 @@ namespace Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation { -#if !NETCOREAPP1_1 +#if !NETCOREAPP using System; using System.IO; using System.Linq; diff --git a/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/PlatformFileTest.cs b/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/PlatformFileTest.cs index a9b4a755af..79db965c1c 100644 --- a/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/PlatformFileTest.cs +++ b/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/PlatformFileTest.cs @@ -1,6 +1,6 @@ namespace Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation { -#if !NETCOREAPP1_1 +#if !NETCOREAPP using System; using System.IO; using System.Security.AccessControl; diff --git a/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/PlatformFolderTest.cs b/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/PlatformFolderTest.cs index f5a4324809..4d852c36c2 100644 --- a/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/PlatformFolderTest.cs +++ b/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/PlatformFolderTest.cs @@ -1,6 +1,6 @@ namespace Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel.Implementation { -#if !NETCOREAPP1_1 +#if !NETCOREAPP using System; using System.Collections.Generic; using System.IO; diff --git a/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/TelemetryBufferTest.cs b/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/TelemetryBufferTest.cs index fe78fb1347..0d85fd654f 100644 --- a/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/TelemetryBufferTest.cs +++ b/Test/ServerTelemetryChannel.Test/Shared.Tests/Implementation/TelemetryBufferTest.cs @@ -32,7 +32,7 @@ public void ConstructorThrowsArgumentNullExceptionWhenSerializerIsNull() AssertEx.Throws(() => new TelemetryBuffer(null, new StubApplicationLifecycle())); } -#if !NETCOREAPP1_1 +#if !NETCOREAPP [TestMethod] public void ConstructorThrowsArgumentNullExceptionWhenApplicationLifecycleIsNull() { diff --git a/Test/ServerTelemetryChannel.Test/Shared.Tests/ServerTelemetryChannelTest.cs b/Test/ServerTelemetryChannel.Test/Shared.Tests/ServerTelemetryChannelTest.cs index c085b2c8b4..18d7d21b40 100644 --- a/Test/ServerTelemetryChannel.Test/Shared.Tests/ServerTelemetryChannelTest.cs +++ b/Test/ServerTelemetryChannel.Test/Shared.Tests/ServerTelemetryChannelTest.cs @@ -412,7 +412,7 @@ public void SendWillBeMarkedAsInternalOperation() bool wasCalled = false; var channel = new ServerTelemetryChannel(); channel.TelemetrySerializer = new TelemetrySerializerStub(channel.Transmitter) { WasCalled = (called) => { wasCalled = called; } }; - #if NETCOREAPP1_1 +#if NETCOREAPP channel.TelemetryBuffer = new TelemetryChannel.Implementation.TelemetryBuffer(channel.TelemetrySerializer, null); #else channel.TelemetryBuffer = new TelemetryChannel.Implementation.TelemetryBuffer(channel.TelemetrySerializer, new WebApplicationLifecycle()); diff --git a/Test/ServerTelemetryChannel.Test/Shared.Tests/Shared.Tests.projitems b/Test/ServerTelemetryChannel.Test/Shared.Tests/Shared.Tests.projitems index 589f5d7fd5..bd4a771e36 100644 --- a/Test/ServerTelemetryChannel.Test/Shared.Tests/Shared.Tests.projitems +++ b/Test/ServerTelemetryChannel.Test/Shared.Tests/Shared.Tests.projitems @@ -56,7 +56,13 @@ + - + + True + True + + + \ No newline at end of file diff --git a/Test/TestFramework/Shared/EventSourceTest.cs b/Test/TestFramework/Shared/EventSourceTest.cs index 8922516e36..cdc17be513 100644 --- a/Test/TestFramework/Shared/EventSourceTest.cs +++ b/Test/TestFramework/Shared/EventSourceTest.cs @@ -93,7 +93,7 @@ private static void VerifyEventMessage(MethodInfo eventMethod, EventWrittenEvent private static void VerifyEventApplicationName(MethodInfo eventMethod, EventWrittenEventArgs actualEvent) { -#if !NETSTANDARD1_3 && !NETCOREAPP1_1 +#if !NETCOREAPP string expectedApplicationName = AppDomain.CurrentDomain.FriendlyName; #else string expectedApplicationName = ""; diff --git a/src/Microsoft.ApplicationInsights/Properties/AssemblyInfo.cs b/src/Microsoft.ApplicationInsights/Properties/AssemblyInfo.cs index 9516c711aa..dc9ad46d76 100644 --- a/src/Microsoft.ApplicationInsights/Properties/AssemblyInfo.cs +++ b/src/Microsoft.ApplicationInsights/Properties/AssemblyInfo.cs @@ -11,6 +11,7 @@ [assembly: InternalsVisibleTo("Microsoft.ApplicationInsights.TelemetryChannel.Net45.Tests" + AssemblyInfo.PublicKey)] [assembly: InternalsVisibleTo("Microsoft.ApplicationInsights.TelemetryChannel.NetCore.Tests" + AssemblyInfo.PublicKey)] +[assembly: InternalsVisibleTo("Microsoft.ApplicationInsights.TelemetryChannel.NetCore20.Tests" + AssemblyInfo.PublicKey)] // Assembly dynamically generated by Moq in unit tests [assembly: InternalsVisibleTo("DynamicProxyGenAssembly2" + AssemblyInfo.MoqPublicKey)] diff --git a/src/ServerTelemetryChannel/AssemblyInfo.cs b/src/ServerTelemetryChannel/AssemblyInfo.cs index 1fb76f3ac7..27f7ecffaf 100644 --- a/src/ServerTelemetryChannel/AssemblyInfo.cs +++ b/src/ServerTelemetryChannel/AssemblyInfo.cs @@ -10,6 +10,7 @@ [assembly: InternalsVisibleTo("Microsoft.ApplicationInsights.TelemetryChannel.Net45.Tests" + AssemblyInfo.PublicKey)] [assembly: InternalsVisibleTo("Microsoft.ApplicationInsights.TelemetryChannel.NetCore.Tests" + AssemblyInfo.PublicKey)] +[assembly: InternalsVisibleTo("Microsoft.ApplicationInsights.TelemetryChannel.NetCore20.Tests" + AssemblyInfo.PublicKey)] // Assembly dynamically generated by Moq in unit tests [assembly: InternalsVisibleTo("DynamicProxyGenAssembly2" + AssemblyInfo.MoqPublicKey)] From 606845fd7e0a579c753df02f706efd2e1ffb29f5 Mon Sep 17 00:00:00 2001 From: Claudiu Guiman Date: Tue, 15 May 2018 11:36:20 -0700 Subject: [PATCH 3/3] Update changelog --- CHANGELOG.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5a7764aefc..056f45b609 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,9 @@ This changelog will be used to generate documentation on [release notes page](ht - [Extend the Beta period for Metrics Pre-Aggregation features shipped in 2.6.0-beta3.](https://github.com/Microsoft/ApplicationInsights-dotnet/issues/785) - [New: Added TryGetOperationDetail to DependencyTelemetry to facilitate advanced ITelemetryInitializer scenarios. Allows ITelemetryInitializer implementations to specify fields that would otherwise not be sent automatically to the backend.] (https://github.com/Microsoft/ApplicationInsights-dotnet-server/issues/900) +## Version 2.6.2 +- [Add netstandard2.0 target for TelemetryChannel which doesn't have a dependency on Newtonsoft.Json ](https://github.com/Microsoft/ApplicationInsights-dotnet/issues/800) + ## Version 2.6.0 - [Fix: changed namespace SamplingPercentageEstimatorSettings](https://github.com/Microsoft/ApplicationInsights-dotnet/issues/727) - [Extend the Beta period for Metrics Pre-Aggregation features shipped in 2.6.0-beta3.](https://github.com/Microsoft/ApplicationInsights-dotnet/issues/785)