diff --git a/Microsoft.Azure.Cosmos.Samples/Tools/Benchmark/BenchmarkConfig.cs b/Microsoft.Azure.Cosmos.Samples/Tools/Benchmark/BenchmarkConfig.cs index a0c5173c5e..dc287c8a4d 100644 --- a/Microsoft.Azure.Cosmos.Samples/Tools/Benchmark/BenchmarkConfig.cs +++ b/Microsoft.Azure.Cosmos.Samples/Tools/Benchmark/BenchmarkConfig.cs @@ -98,9 +98,6 @@ public class BenchmarkConfig [Option(Required = false, HelpText = "Disable core SDK logging")] public bool DisableCoreSdkLogging { get; set; } - [Option(Required = false, HelpText = "Enable Open Telemetry")] - public bool EnableOpenTelemetry { get; set; } - [Option(Required = false, HelpText = "Enable Client Telemetry")] public bool EnableTelemetry { get; set; } @@ -196,11 +193,6 @@ internal Microsoft.Azure.Cosmos.CosmosClient CreateCosmosClient(string accountKe MaxTcpConnectionsPerEndpoint = this.MaxTcpConnectionsPerEndpoint }; - if (this.EnableOpenTelemetry) - { - clientOptions.EnableOpenTelemetry = true; - } - if (this.EnableTelemetry) { Environment.SetEnvironmentVariable( diff --git a/Microsoft.Azure.Cosmos/src/CosmosClientOptions.cs b/Microsoft.Azure.Cosmos/src/CosmosClientOptions.cs index 1f492e9ba5..d0a46450ce 100644 --- a/Microsoft.Azure.Cosmos/src/CosmosClientOptions.cs +++ b/Microsoft.Azure.Cosmos/src/CosmosClientOptions.cs @@ -15,6 +15,7 @@ namespace Microsoft.Azure.Cosmos using Microsoft.Azure.Documents; using Microsoft.Azure.Documents.Client; using Newtonsoft.Json; + using Telemetry; /// /// Defines all the configurable options that the CosmosClient requires. @@ -925,13 +926,15 @@ public override bool CanConvert(Type objectType) } /// - /// Enable OpenTelemetry and start emiting activities for each operations + /// Distributed Tracing Options. /// -#if PREVIEW - public -#else - internal -#endif - bool EnableOpenTelemetry { get; set; } + internal DistributedTracingOptions DistributedTracingOptions { get; set; } + + /// + /// Gets or sets value indicating whether distributed tracing activities () are going to be created for the SDK methods calls and HTTP calls. + /// By default true for Preview package + /// + internal bool EnableDistributedTracing { get; set; } + } } \ No newline at end of file diff --git a/Microsoft.Azure.Cosmos/src/Fluent/CosmosClientBuilder.cs b/Microsoft.Azure.Cosmos/src/Fluent/CosmosClientBuilder.cs index da5ce80e43..4621e13557 100644 --- a/Microsoft.Azure.Cosmos/src/Fluent/CosmosClientBuilder.cs +++ b/Microsoft.Azure.Cosmos/src/Fluent/CosmosClientBuilder.cs @@ -10,12 +10,12 @@ namespace Microsoft.Azure.Cosmos.Fluent using System.Net.Http; using System.Threading; using System.Threading.Tasks; - using Azure; using global::Azure; using global::Azure.Core; using Microsoft.Azure.Cosmos.Core.Trace; using Microsoft.Azure.Documents; using Microsoft.Azure.Documents.Client; + using Telemetry; /// /// This is a Builder class that creates a cosmos client @@ -409,7 +409,7 @@ public CosmosClientBuilder WithConnectionModeDirect(TimeSpan? idleTcpConnectionT return this; } - + /// /// This can be used to weaken the database account consistency level for read operations. /// If this is not set the database account consistency level will be used for all requests. @@ -420,20 +420,18 @@ public CosmosClientBuilder WithConsistencyLevel(Cosmos.ConsistencyLevel consiste { this.clientOptions.ConsistencyLevel = consistencyLevel; return this; + } /// - /// Enable OpenTelemetry and start emiting activities for each operations + /// If Open Telemetry listener is subscribed for Azure.Cosmos namespace, There are you can leverage to control it.

///
+ /// Tracing Options /// The current . -#if PREVIEW - public -#else - internal -#endif - CosmosClientBuilder EnableOpenTelemetry() - { - this.clientOptions.EnableOpenTelemetry = true; + internal CosmosClientBuilder WithDistributingTracing(DistributedTracingOptions options) + { + this.clientOptions.DistributedTracingOptions = options; + return this; } diff --git a/Microsoft.Azure.Cosmos/src/RequestOptions/RequestOptions.cs b/Microsoft.Azure.Cosmos/src/RequestOptions/RequestOptions.cs index 9169c13f80..5387a0fbac 100644 --- a/Microsoft.Azure.Cosmos/src/RequestOptions/RequestOptions.cs +++ b/Microsoft.Azure.Cosmos/src/RequestOptions/RequestOptions.cs @@ -7,6 +7,7 @@ namespace Microsoft.Azure.Cosmos using System; using System.Collections.Generic; using Microsoft.Azure.Documents; + using Telemetry; /// /// The default cosmos request options @@ -41,6 +42,11 @@ public class RequestOptions /// public Action AddRequestHeaders { get; set; } + /// + /// Set Request Level Distributed Tracing Options. + /// + internal DistributedTracingOptions DistributedTracingOptions { get; set; } + /// /// Gets or sets the boolean to use effective partition key routing in the cosmos db request. /// diff --git a/Microsoft.Azure.Cosmos/src/Resource/ClientContextCore.cs b/Microsoft.Azure.Cosmos/src/Resource/ClientContextCore.cs index f4b655da32..a15c7ec64b 100644 --- a/Microsoft.Azure.Cosmos/src/Resource/ClientContextCore.cs +++ b/Microsoft.Azure.Cosmos/src/Resource/ClientContextCore.cs @@ -17,8 +17,6 @@ namespace Microsoft.Azure.Cosmos using Microsoft.Azure.Cosmos.Resource.CosmosExceptions; using Microsoft.Azure.Cosmos.Routing; using Microsoft.Azure.Cosmos.Telemetry; - using Microsoft.Azure.Cosmos.Telemetry.Diagnostics; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; using Microsoft.Azure.Cosmos.Tracing; using Microsoft.Azure.Documents; @@ -266,7 +264,8 @@ private async Task OperationHelperWithRootTraceAsync( trace, task, openTelemetry, - operationName); + operationName, + requestOptions); } } @@ -295,7 +294,8 @@ private Task OperationHelperWithRootTraceWithSynchronizationContextAsyn trace, task, openTelemetry, - operationName); + operationName, + requestOptions); } }); } @@ -471,22 +471,24 @@ private async Task RunWithDiagnosticsHelperAsync( ITrace trace, Func> task, Func openTelemetry, - string operationName) + string operationName, + RequestOptions requestOptions) { using (OpenTelemetryCoreRecorder recorder = OpenTelemetryRecorderFactory.CreateRecorder( operationName: operationName, - isFeatureEnabled: this.clientOptions.EnableOpenTelemetry)) + requestOptions: requestOptions, + clientContext: this.isDisposed ? null : this)) using (new ActivityScope(Guid.NewGuid())) { try { + // Record Operation Name + recorder.Record(OpenTelemetryAttributeKeys.DbOperation, operationName); + TResult result = await task(trace).ConfigureAwait(false); if (openTelemetry != null && recorder.IsEnabled) { - // Record client and other information - recorder.Record(operationName, this); - // Record request response information OpenTelemetryAttributes response = openTelemetry(result); recorder.Record(response); diff --git a/Microsoft.Azure.Cosmos/src/Resource/CosmosClientContext.cs b/Microsoft.Azure.Cosmos/src/Resource/CosmosClientContext.cs index c2845822aa..1090ee3807 100644 --- a/Microsoft.Azure.Cosmos/src/Resource/CosmosClientContext.cs +++ b/Microsoft.Azure.Cosmos/src/Resource/CosmosClientContext.cs @@ -9,9 +9,9 @@ namespace Microsoft.Azure.Cosmos using System.Threading; using System.Threading.Tasks; using Microsoft.Azure.Cosmos.Handlers; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; using Microsoft.Azure.Cosmos.Tracing; using Microsoft.Azure.Documents; + using Telemetry; /// /// This class is used to get access to different client level operations without directly referencing the client object. diff --git a/Microsoft.Azure.Cosmos/src/Resource/Database/DatabaseInlineCore.cs b/Microsoft.Azure.Cosmos/src/Resource/Database/DatabaseInlineCore.cs index 80724a2859..182bc612f0 100644 --- a/Microsoft.Azure.Cosmos/src/Resource/Database/DatabaseInlineCore.cs +++ b/Microsoft.Azure.Cosmos/src/Resource/Database/DatabaseInlineCore.cs @@ -30,7 +30,7 @@ public override Task CreateContainerAsync( nameof(CreateContainerAsync), requestOptions, (trace) => base.CreateContainerAsync(containerProperties, throughput, requestOptions, trace, cancellationToken), - (response) => new OpenTelemetryResponse(response)); + (response) => new OpenTelemetryResponse(response, this.Id)); } public override Task CreateContainerAsync(string id, @@ -43,7 +43,7 @@ public override Task CreateContainerAsync(string id, nameof(CreateContainerAsync), requestOptions, (trace) => base.CreateContainerAsync(id, partitionKeyPath, throughput, requestOptions, trace, cancellationToken), - (response) => new OpenTelemetryResponse(response)); + (response) => new OpenTelemetryResponse(response, this.Id)); } public override Task CreateContainerIfNotExistsAsync( @@ -56,7 +56,7 @@ public override Task CreateContainerIfNotExistsAsync( nameof(CreateContainerIfNotExistsAsync), requestOptions, (trace) => base.CreateContainerIfNotExistsAsync(containerProperties, throughput, requestOptions, trace, cancellationToken), - (response) => new OpenTelemetryResponse(response)); + (response) => new OpenTelemetryResponse(response, this.Id)); } public override Task CreateContainerIfNotExistsAsync( @@ -70,7 +70,7 @@ public override Task CreateContainerIfNotExistsAsync( nameof(CreateContainerIfNotExistsAsync), requestOptions, (trace) => base.CreateContainerIfNotExistsAsync(id, partitionKeyPath, throughput, requestOptions, trace, cancellationToken), - (response) => new OpenTelemetryResponse(response)); + (response) => new OpenTelemetryResponse(response, this.Id)); } public override Task CreateContainerStreamAsync( diff --git a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/DistributedTracingOptions.cs b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/DistributedTracingOptions.cs new file mode 100644 index 0000000000..faa6462ff9 --- /dev/null +++ b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/DistributedTracingOptions.cs @@ -0,0 +1,33 @@ +// ------------------------------------------------------------ +// Copyright (c) Microsoft Corporation. All rights reserved. +// ------------------------------------------------------------ + +namespace Microsoft.Azure.Cosmos +{ + using System; + using System.Runtime.CompilerServices; + + /// + /// Open Telemetry Configuration + /// It needs to be public once AppInsight is ready + /// + internal sealed class DistributedTracingOptions + { + /// + /// Default Latency threshold for other than query Operation + /// + internal static readonly TimeSpan DefaultCrudLatencyThreshold = TimeSpan.FromMilliseconds(100); + + /// + /// Default Latency threshold for QUERY operation + /// + internal static readonly TimeSpan DefaultQueryTimeoutThreshold = TimeSpan.FromMilliseconds(500); + + /// + /// Latency Threshold to generate () with Request diagnostics in distributing Tracing.

+ /// If it is not set then by default it will generate () for query operation which are taking more than 500 ms and non-query operations taking more than 100 ms. + ///
+ public TimeSpan? DiagnosticsLatencyThreshold { get; set; } + + } +} diff --git a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/Filters/DiagnosticsFilterHelper.cs b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/Filters/DiagnosticsFilterHelper.cs index d0f48255ba..bbe389c210 100644 --- a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/Filters/DiagnosticsFilterHelper.cs +++ b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/Filters/DiagnosticsFilterHelper.cs @@ -5,23 +5,32 @@ namespace Microsoft.Azure.Cosmos.Telemetry.Diagnostics { using System; - using System.Net; + using Documents; internal static class DiagnosticsFilterHelper { - private static readonly TimeSpan latencyThresholdInMs = TimeSpan.FromMilliseconds(250); - /// /// Allow only when either of below is True

- /// 1) Latency is not more than 100 ms

+ /// 1) Latency is not more than 100/250 (query) ms

/// 3) HTTP status code is not Success

///
/// true or false - public static bool IsAllowed( - TimeSpan latency, - HttpStatusCode statuscode) + public static bool IsTracingNeeded( + DistributedTracingOptions config, + OpenTelemetryAttributes response) { - return latency > DiagnosticsFilterHelper.latencyThresholdInMs || !statuscode.IsSuccess(); + TimeSpan latencyThreshold; + + if (config?.DiagnosticsLatencyThreshold != null) + { + latencyThreshold = config.DiagnosticsLatencyThreshold.Value; + } + else + { + latencyThreshold = response.OperationType == OperationType.Query ? DistributedTracingOptions.DefaultQueryTimeoutThreshold : DistributedTracingOptions.DefaultCrudLatencyThreshold; + } + + return response.Diagnostics.GetClientElapsedTime() > latencyThreshold || !response.StatusCode.IsSuccess(); } } } diff --git a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributeKeys.cs b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributeKeys.cs index 92e34ff46a..5ba29b76a3 100644 --- a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributeKeys.cs +++ b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributeKeys.cs @@ -2,7 +2,7 @@ // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------ -namespace Microsoft.Azure.Cosmos.Telemetry.Diagnostics +namespace Microsoft.Azure.Cosmos.Telemetry { internal sealed class OpenTelemetryAttributeKeys { diff --git a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributes.cs b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributes.cs index b133f0b8bf..759505695e 100644 --- a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributes.cs +++ b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributes.cs @@ -2,19 +2,29 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // ------------------------------------------------------------ -namespace Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry +namespace Microsoft.Azure.Cosmos.Telemetry { using System.Net; + using Microsoft.Azure.Documents; internal class OpenTelemetryAttributes { - internal const string NotAvailable = "NA"; - + internal const string NotAvailable = "information not available"; + + /// + /// For testing purpose only, to make initialization of this class easy + /// + internal OpenTelemetryAttributes() + { + } + internal OpenTelemetryAttributes(RequestMessage requestMessage) { this.RequestContentLength = requestMessage?.Headers?.ContentLength ?? OpenTelemetryAttributes.NotAvailable; this.ContainerName = requestMessage?.ContainerId ?? OpenTelemetryAttributes.NotAvailable; this.DatabaseName = requestMessage?.DatabaseId ?? OpenTelemetryAttributes.NotAvailable; + + this.OperationType = requestMessage?.OperationType ?? OperationType.Invalid; } /// @@ -56,5 +66,10 @@ internal OpenTelemetryAttributes(RequestMessage requestMessage) /// ItemCount /// internal CosmosDiagnostics Diagnostics { get; set; } + + /// + /// OperationType + /// + internal OperationType OperationType { get; set; } } } diff --git a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryCoreRecorder.cs b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryCoreRecorder.cs index cdd696e7ea..ae43dd5e64 100644 --- a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryCoreRecorder.cs +++ b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryCoreRecorder.cs @@ -2,21 +2,22 @@ // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------ -namespace Microsoft.Azure.Cosmos.Telemetry.Diagnostics +namespace Microsoft.Azure.Cosmos.Telemetry { using System; using System.Collections.Generic; - using System.Text; + using Diagnostics; using global::Azure.Core.Pipeline; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; internal struct OpenTelemetryCoreRecorder : IDisposable { private const string CosmosDb = "cosmosdb"; private readonly DiagnosticScope scope; + private readonly DistributedTracingOptions config; + private string accountHostWithCloudInfo = null; - internal static IDictionary> oTelCompatibleExceptions = new Dictionary>() + internal static IDictionary> OTelCompatibleExceptions = new Dictionary>() { { typeof(CosmosNullReferenceException), (exception, scope) => CosmosNullReferenceException.RecordOtelAttributes((CosmosNullReferenceException)exception, scope)}, { typeof(CosmosObjectDisposedException), (exception, scope) => CosmosObjectDisposedException.RecordOtelAttributes((CosmosObjectDisposedException)exception, scope)}, @@ -25,13 +26,16 @@ internal struct OpenTelemetryCoreRecorder : IDisposable { typeof(ChangeFeedProcessorUserException), (exception, scope) => ChangeFeedProcessorUserException.RecordOtelAttributes((ChangeFeedProcessorUserException)exception, scope)} }; - public OpenTelemetryCoreRecorder(DiagnosticScope scope) + public OpenTelemetryCoreRecorder(DiagnosticScope scope, CosmosClientContext clientContext, DistributedTracingOptions config) { this.scope = scope; + this.config = config; - if (this.scope.IsEnabled) + if (this.IsEnabled) { this.scope.Start(); + + this.Record(clientContext); } } @@ -39,28 +43,31 @@ public OpenTelemetryCoreRecorder(DiagnosticScope scope) public void Record(string key, string value) { - this.scope.AddAttribute(key, value); + if (this.IsEnabled) + { + this.scope.AddAttribute(key, value); + } } /// /// System Level and Client level attributes /// - /// /// - public void Record(string operationName, CosmosClientContext clientContext) + public void Record(CosmosClientContext clientContext) { - // Other information - this.scope.AddAttribute(OpenTelemetryAttributeKeys.DbSystemName, OpenTelemetryCoreRecorder.CosmosDb); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.DbOperation, operationName); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.MachineId, VmMetadataApiHandler.GetMachineId()); - - string netPeerName = clientContext.DocumentClient?.accountServiceConfiguration?.AccountProperties?.AccountNameWithCloudInformation; - this.scope.AddAttribute(OpenTelemetryAttributeKeys.NetPeerName, netPeerName); - - // Client Information - this.scope.AddAttribute(OpenTelemetryAttributeKeys.ClientId, clientContext.Client.Id); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.UserAgent, clientContext.UserAgent); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.ConnectionMode, clientContext.ClientOptions.ConnectionMode); + if (this.IsEnabled) + { + // Other information + this.scope.AddAttribute(OpenTelemetryAttributeKeys.DbSystemName, OpenTelemetryCoreRecorder.CosmosDb); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.MachineId, VmMetadataApiHandler.GetMachineId()); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.NetPeerName, this.GetHostWithCloudInformation(clientContext.Client?.Endpoint?.Host)); + + // Client Information + this.scope.AddAttribute(OpenTelemetryAttributeKeys.ClientId, clientContext?.Client?.Id ?? OpenTelemetryAttributes.NotAvailable); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.UserAgent, clientContext.UserAgent ?? OpenTelemetryAttributes.NotAvailable); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.ConnectionMode, + clientContext.ClientOptions.ConnectionMode); + } } /// @@ -69,21 +76,34 @@ public void Record(string operationName, CosmosClientContext clientContext) /// public void Record(OpenTelemetryAttributes response) { - this.scope.AddAttribute(OpenTelemetryAttributeKeys.DbName, response.DatabaseName); - - this.scope.AddAttribute(OpenTelemetryAttributeKeys.ContainerName, response.ContainerName); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.RequestContentLength, response.RequestContentLength); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.ResponseContentLength, response.ResponseContentLength); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.StatusCode, response.StatusCode); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.RequestCharge, response.RequestCharge); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.ItemCount, response.ItemCount); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.Region, ClientTelemetryHelper.GetContactedRegions(response.Diagnostics)); - - if (this.IsEnabled && DiagnosticsFilterHelper.IsAllowed( - latency: response.Diagnostics.GetClientElapsedTime(), - statuscode: response.StatusCode)) + if (this.IsEnabled) { - this.scope.AddAttribute(OpenTelemetryAttributeKeys.RequestDiagnostics, response.Diagnostics); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.DbName, response.DatabaseName); + + this.scope.AddAttribute(OpenTelemetryAttributeKeys.ContainerName, response.ContainerName); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.RequestContentLength, response.RequestContentLength); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.ResponseContentLength, + response.ResponseContentLength); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.StatusCode, response.StatusCode); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.RequestCharge, response.RequestCharge); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.ItemCount, response.ItemCount); + + if (response.Diagnostics != null) + { + this.scope.AddAttribute(OpenTelemetryAttributeKeys.Region, ClientTelemetryHelper.GetContactedRegions(response.Diagnostics)); + + if (this.IsEnabled && DiagnosticsFilterHelper.IsTracingNeeded( + config: this.config, + response: response)) + { + this.scope.AddAttribute(OpenTelemetryAttributeKeys.RequestDiagnostics, response.Diagnostics); + } + } + else + { + this.scope.AddAttribute(OpenTelemetryAttributeKeys.Region, OpenTelemetryAttributes.NotAvailable); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.RequestDiagnostics, OpenTelemetryAttributes.NotAvailable); + } } } @@ -94,16 +114,19 @@ public void Record(OpenTelemetryAttributes response) /// public void MarkFailed(Exception exception) { - this.scope.AddAttribute(OpenTelemetryAttributeKeys.ExceptionStacktrace, exception.StackTrace); - this.scope.AddAttribute(OpenTelemetryAttributeKeys.ExceptionType, exception.GetType()); - - // If Exception is not registered with open Telemetry - if (!OpenTelemetryCoreRecorder.IsExceptionRegistered(exception, this.scope)) + if (this.IsEnabled) { - this.scope.AddAttribute(OpenTelemetryAttributeKeys.ExceptionMessage, exception.Message); - } + this.scope.AddAttribute(OpenTelemetryAttributeKeys.ExceptionStacktrace, exception.StackTrace); + this.scope.AddAttribute(OpenTelemetryAttributeKeys.ExceptionType, exception.GetType()); + + // If Exception is not registered with open Telemetry + if (!OpenTelemetryCoreRecorder.IsExceptionRegistered(exception, this.scope)) + { + this.scope.AddAttribute(OpenTelemetryAttributeKeys.ExceptionMessage, exception.Message); + } - this.scope.Failed(exception); + this.scope.Failed(exception); + } } /// @@ -114,7 +137,7 @@ public void MarkFailed(Exception exception) /// tru/false internal static bool IsExceptionRegistered(Exception exception, DiagnosticScope scope) { - foreach (KeyValuePair> registeredExceptionHandlers in OpenTelemetryCoreRecorder.oTelCompatibleExceptions) + foreach (KeyValuePair> registeredExceptionHandlers in OpenTelemetryCoreRecorder.OTelCompatibleExceptions) { Type exceptionType = exception.GetType(); if (registeredExceptionHandlers.Key.IsAssignableFrom(exceptionType)) @@ -135,5 +158,20 @@ public void Dispose() this.scope.Dispose(); } } + + /// + /// Host Name with Cloud Information + /// + /// + /// hostname(cloudInfo) + private string GetHostWithCloudInformation(string hostName) + { + string accountHostWithCloudInfoSnapshot = this.accountHostWithCloudInfo; + if (!string.IsNullOrEmpty(accountHostWithCloudInfoSnapshot)) + { + return accountHostWithCloudInfoSnapshot; + } + return this.accountHostWithCloudInfo = $"{hostName}({VmMetadataApiHandler.GetCloudInformation()})"; + } } } diff --git a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryRecorderFactory.cs b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryRecorderFactory.cs index 54da6ab1cf..f72954045b 100644 --- a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryRecorderFactory.cs +++ b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryRecorderFactory.cs @@ -2,7 +2,7 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // ------------------------------------------------------------ -namespace Microsoft.Azure.Cosmos.Telemetry.Diagnostics +namespace Microsoft.Azure.Cosmos.Telemetry { using global::Azure.Core.Pipeline; @@ -10,20 +10,25 @@ internal static class OpenTelemetryRecorderFactory { private static DiagnosticScopeFactory ScopeFactory { get; set; } - public static OpenTelemetryCoreRecorder CreateRecorder(string operationName, bool isFeatureEnabled) + public static OpenTelemetryCoreRecorder CreateRecorder(string operationName, + RequestOptions requestOptions, + CosmosClientContext clientContext) { - if (isFeatureEnabled) + if (clientContext is { ClientOptions.EnableDistributedTracing: true }) { ScopeFactory = new DiagnosticScopeFactory(clientNamespace: OpenTelemetryAttributeKeys.DiagnosticNamespace, - resourceProviderNamespace: OpenTelemetryAttributeKeys.ResourceProviderNamespace, - isActivityEnabled: true); + resourceProviderNamespace: OpenTelemetryAttributeKeys.ResourceProviderNamespace, + isActivityEnabled: true); DiagnosticScope scope = OpenTelemetryRecorderFactory .ScopeFactory .CreateScope($"{OpenTelemetryAttributeKeys.OperationPrefix}.{operationName}"); if (scope.IsEnabled) { - return new OpenTelemetryCoreRecorder(scope); + return new OpenTelemetryCoreRecorder( + scope: scope, + clientContext: clientContext, + config: requestOptions?.DistributedTracingOptions ?? clientContext.ClientOptions?.DistributedTracingOptions); } } diff --git a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryResponse.cs b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryResponse.cs index 8f8c95c49d..b00ff52f2c 100644 --- a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryResponse.cs +++ b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryResponse.cs @@ -4,9 +4,8 @@ namespace Microsoft.Azure.Cosmos { - using System; using System.IO; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; + using Telemetry; internal sealed class OpenTelemetryResponse : OpenTelemetryAttributes { @@ -17,11 +16,11 @@ internal OpenTelemetryResponse(ResponseMessage responseMessage) this.RequestCharge = responseMessage.Headers?.RequestCharge; this.ResponseContentLength = OpenTelemetryResponse.GetPayloadSize(responseMessage); this.Diagnostics = responseMessage.Diagnostics; - this.ItemCount = responseMessage.Headers?.ItemCount; + this.ItemCount = responseMessage.Headers?.ItemCount ?? OpenTelemetryAttributes.NotAvailable; } /// - /// No request message in TransactionalBatchresponse + /// No request message in TransactionalBatchResponse /// /// internal OpenTelemetryResponse(TransactionalBatchResponse responseMessage) @@ -31,7 +30,7 @@ internal OpenTelemetryResponse(TransactionalBatchResponse responseMessage) this.StatusCode = responseMessage.StatusCode; this.RequestCharge = responseMessage.Headers?.RequestCharge; this.Diagnostics = responseMessage.Diagnostics; - this.ItemCount = responseMessage.Headers?.ItemCount; + this.ItemCount = responseMessage.Headers?.ItemCount ?? OpenTelemetryAttributes.NotAvailable; } private static string GetPayloadSize(ResponseMessage response) diff --git a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryResponse{T}.cs b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryResponse{T}.cs index 06899c0d10..2ebe8dbce1 100644 --- a/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryResponse{T}.cs +++ b/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryResponse{T}.cs @@ -4,7 +4,7 @@ namespace Microsoft.Azure.Cosmos { - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; + using Telemetry; internal sealed class OpenTelemetryResponse : OpenTelemetryAttributes { @@ -15,7 +15,7 @@ internal OpenTelemetryResponse(Response responseMessage) this.RequestCharge = responseMessage.Headers?.RequestCharge; this.ResponseContentLength = responseMessage?.Headers?.ContentLength ?? OpenTelemetryAttributes.NotAvailable; this.Diagnostics = responseMessage.Diagnostics; - this.ItemCount = responseMessage.Headers?.ItemCount; + this.ItemCount = responseMessage.Headers?.ItemCount ?? OpenTelemetryAttributes.NotAvailable; } internal OpenTelemetryResponse(FeedResponse responseMessage) @@ -25,7 +25,41 @@ internal OpenTelemetryResponse(FeedResponse responseMessage) this.RequestCharge = responseMessage.Headers?.RequestCharge; this.ResponseContentLength = responseMessage?.Headers?.ContentLength ?? OpenTelemetryAttributes.NotAvailable; this.Diagnostics = responseMessage.Diagnostics; - this.ItemCount = responseMessage.Headers?.ItemCount; + this.ItemCount = responseMessage.Headers?.ItemCount ?? OpenTelemetryAttributes.NotAvailable; + } + + internal OpenTelemetryResponse(Response responseMessage) + : base(responseMessage.RequestMessage) + { + this.StatusCode = responseMessage.StatusCode; + this.RequestCharge = responseMessage.Headers?.RequestCharge; + this.ResponseContentLength = responseMessage?.Headers?.ContentLength ?? OpenTelemetryAttributes.NotAvailable; + this.Diagnostics = responseMessage.Diagnostics; + this.ItemCount = responseMessage.Headers?.ItemCount ?? OpenTelemetryAttributes.NotAvailable; + this.DatabaseName = responseMessage.Resource?.Id ?? OpenTelemetryAttributes.NotAvailable; + } + + internal OpenTelemetryResponse(Response responseMessage) + : base(responseMessage.RequestMessage) + { + this.StatusCode = responseMessage.StatusCode; + this.RequestCharge = responseMessage.Headers?.RequestCharge; + this.ResponseContentLength = responseMessage?.Headers?.ContentLength ?? OpenTelemetryAttributes.NotAvailable; + this.Diagnostics = responseMessage.Diagnostics; + this.ItemCount = responseMessage.Headers?.ItemCount ?? OpenTelemetryAttributes.NotAvailable; + this.ContainerName = responseMessage.Resource?.Id ?? OpenTelemetryAttributes.NotAvailable; + } + + internal OpenTelemetryResponse(Response responseMessage, string databaseName) + : base(responseMessage.RequestMessage) + { + this.StatusCode = responseMessage.StatusCode; + this.RequestCharge = responseMessage.Headers?.RequestCharge; + this.ResponseContentLength = responseMessage?.Headers?.ContentLength ?? OpenTelemetryAttributes.NotAvailable; + this.Diagnostics = responseMessage.Diagnostics; + this.ItemCount = responseMessage.Headers?.ItemCount ?? OpenTelemetryAttributes.NotAvailable; + this.DatabaseName = databaseName ?? OpenTelemetryAttributes.NotAvailable; + this.ContainerName = responseMessage.Resource?.Id ?? OpenTelemetryAttributes.NotAvailable; } } } diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.BatchOperationsAsync.xml b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.BatchOperationsAsync.xml index 2bcb9b6ea1..260d93e370 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.BatchOperationsAsync.xml +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.BatchOperationsAsync.xml @@ -150,7 +150,7 @@ } ] }]]> - Cosmos.ExecuteAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.ExecuteAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.BulkOperationsAsync.xml b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.BulkOperationsAsync.xml index fd6cf8f1e7..c65c4c7579 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.BulkOperationsAsync.xml +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.BulkOperationsAsync.xml @@ -4,7 +4,7 @@ Bulk Operation builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -172,7 +172,7 @@ Bulk Operation builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -340,7 +340,7 @@ Bulk Operation builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -508,7 +508,7 @@ Bulk Operation builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -676,7 +676,7 @@ Bulk Operation builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -844,7 +844,7 @@ Bulk Operation builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -1012,7 +1012,7 @@ Bulk Operation builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -1180,7 +1180,7 @@ Bulk Operation builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -1348,7 +1348,7 @@ Bulk Operation builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -1516,7 +1516,7 @@ Bulk Operation builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -1683,21 +1683,6 @@ Bulk Operation With Throttle - builder.WithThrottlingRetryOptions(TimeSpan.FromSeconds(5), 3) - .WithBulkExecution(true) - .WithTransportClientHandlerFactory(transportClient => new TransportClientWrapper( - transportClient, - (uri, resourceOperation, request) => TransportClientHelper.ReturnThrottledStoreResponseOnItemOperation( - uri, - resourceOperation, - request, - exceptionActivityId, - errorMessage))) - ); ItemRequestOptions requestOptions = new ItemRequestOptions(); Container containerWithThrottleException = throttleClient.GetContainer( @@ -2542,7 +2527,18 @@ } ] }]]> - + Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationexception.stacktraceexception.typedb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.regions_contactedexception.message + \ No newline at end of file diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ChangeFeedAsync.xml b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ChangeFeedAsync.xml index ec6428e656..33fc22c5e8 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ChangeFeedAsync.xml +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ChangeFeedAsync.xml @@ -1201,11 +1201,11 @@ } ] }]]> - Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -1972,11 +1972,11 @@ } ] }]]> - Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -2716,11 +2716,11 @@ } ] }]]> - Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Change Feed Iterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -3488,11 +3488,11 @@ } ] }]]> - Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -3817,9 +3817,9 @@ } ] }]]> - Cosmos.ReadAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Change Feed Estimator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.ReadAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Change Feed Estimator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.MiscellanousAsync.xml b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.MiscellanousAsync.xml index f1e5c8f671..3706f6be32 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.MiscellanousAsync.xml +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.MiscellanousAsync.xml @@ -3,12 +3,8 @@ Custom Handler - builder.AddCustomHandlers(requestHandler)); - - DatabaseResponse databaseResponse = await cosmosClient.CreateDatabaseAsync(Guid.NewGuid().ToString()); + + DatabaseResponse databaseResponse = await miscCosmosClient.CreateDatabaseAsync(Guid.NewGuid().ToString()); EndToEndTraceWriterBaselineTests.AssertCustomHandlerTime( databaseResponse.Diagnostics.ToString(), requestHandler.FullHandlerName, @@ -130,7 +126,9 @@ } ] }]]> - + Cosmos.CreateDatabaseAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.DeleteAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + @@ -241,8 +239,8 @@ } ] }]]> - Cosmos.CreateDatabaseAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.DeleteAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.CreateDatabaseAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.DeleteAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.PointOperationsExceptionsAsync.xml b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.PointOperationsExceptionsAsync.xml index a0fd4dc343..bedfbd3025 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.PointOperationsExceptionsAsync.xml +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.PointOperationsExceptionsAsync.xml @@ -181,18 +181,6 @@ - builder.WithThrottlingRetryOptions(TimeSpan.FromSeconds(5), 5) - .WithTransportClientHandlerFactory(transportClient => new TransportClientWrapper( - transportClient, - (uri, resourceOperation, request) => TransportClientHelper.ReturnThrottledStoreResponseOnItemOperation( - uri, - resourceOperation, - request, - exceptionActivityId, - errorMessage))) - ); ItemRequestOptions requestOptions = new ItemRequestOptions(); Container containerWithThrottleException = throttleClient.GetContainer( @@ -231,55 +219,165 @@ │ [Client Side Request Stats] │ Redacted To Not Change The Baselines From Run To Run │ ) - ├── Microsoft.Azure.Cosmos.Handlers.RequestInvokerHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ └── Microsoft.Azure.Cosmos.Handlers.DiagnosticsHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ ( - │ │ [System Info] - │ │ Redacted To Not Change The Baselines From Run To Run - │ │ ) - │ └── Microsoft.Azure.Cosmos.Handlers.RetryHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds - │ │ ( - │ │ [Client Side Request Stats] - │ │ Redacted To Not Change The Baselines From Run To Run - │ │ ) - │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds - │ │ ( - │ │ [Client Side Request Stats] - │ │ Redacted To Not Change The Baselines From Run To Run - │ │ ) - │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds - │ │ ( - │ │ [Client Side Request Stats] - │ │ Redacted To Not Change The Baselines From Run To Run - │ │ ) - │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds - │ │ ( - │ │ [Client Side Request Stats] - │ │ Redacted To Not Change The Baselines From Run To Run - │ │ ) - │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds - │ │ ( - │ │ [Client Side Request Stats] - │ │ Redacted To Not Change The Baselines From Run To Run - │ │ ) - │ └── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds - │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds - │ ( - │ [Client Side Request Stats] - │ Redacted To Not Change The Baselines From Run To Run - │ ) + ├── Get Collection Cache(00000000-0000-0000-0000-000000000000) Routing-Component 12:00:00:000 0.00 milliseconds + ├── Batch Dispatch Async(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ ├── Using Wait(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ ├── Microsoft.Azure.Cosmos.Handlers.RequestInvokerHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Cosmos.Handlers.DiagnosticsHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [System Info] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ └── Microsoft.Azure.Cosmos.Handlers.RetryHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ └── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ ( + │ │ [Client Side Request Stats] + │ │ Redacted To Not Change The Baselines From Run To Run + │ │ ) + │ └── Create Trace(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + ├── Batch Retry Async(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ └── Get Collection Cache(00000000-0000-0000-0000-000000000000) Routing-Component 12:00:00:000 0.00 milliseconds + ├── Batch Dispatch Async(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ ├── Using Wait(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ ├── Microsoft.Azure.Cosmos.Handlers.RequestInvokerHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Cosmos.Handlers.DiagnosticsHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [System Info] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ └── Microsoft.Azure.Cosmos.Handlers.RetryHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ └── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ ( + │ │ [Client Side Request Stats] + │ │ Redacted To Not Change The Baselines From Run To Run + │ │ ) + │ └── Create Trace(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + ├── Batch Retry Async(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ └── Get Collection Cache(00000000-0000-0000-0000-000000000000) Routing-Component 12:00:00:000 0.00 milliseconds + ├── Batch Dispatch Async(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ ├── Using Wait(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ ├── Microsoft.Azure.Cosmos.Handlers.RequestInvokerHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Cosmos.Handlers.DiagnosticsHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [System Info] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ └── Microsoft.Azure.Cosmos.Handlers.RetryHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ └── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ ( + │ │ [Client Side Request Stats] + │ │ Redacted To Not Change The Baselines From Run To Run + │ │ ) + │ └── Create Trace(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + ├── Batch Retry Async(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ └── Get Collection Cache(00000000-0000-0000-0000-000000000000) Routing-Component 12:00:00:000 0.00 milliseconds + ├── Batch Dispatch Async(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ ├── Using Wait(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds + │ ├── Microsoft.Azure.Cosmos.Handlers.RequestInvokerHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Cosmos.Handlers.DiagnosticsHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [System Info] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ └── Microsoft.Azure.Cosmos.Handlers.RetryHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ ├── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ │ ( + │ │ │ [Client Side Request Stats] + │ │ │ Redacted To Not Change The Baselines From Run To Run + │ │ │ ) + │ │ └── Microsoft.Azure.Cosmos.Handlers.RouterHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Cosmos.Handlers.TransportHandler(00000000-0000-0000-0000-000000000000) RequestHandler-Component 12:00:00:000 0.00 milliseconds + │ │ └── Microsoft.Azure.Documents.ServerStoreModel Transport Request(00000000-0000-0000-0000-000000000000) Transport-Component 12:00:00:000 0.00 milliseconds + │ │ ( + │ │ [Client Side Request Stats] + │ │ Redacted To Not Change The Baselines From Run To Run + │ │ ) + │ └── Create Trace(00000000-0000-0000-0000-000000000000) Batch-Component 12:00:00:000 0.00 milliseconds └── Get Collection Cache(00000000-0000-0000-0000-000000000000) Routing-Component 12:00:00:000 0.00 milliseconds ]]> - + Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationexception.stacktraceexception.typedb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.regions_contactedexception.message + diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.QueryAsync.xml b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.QueryAsync.xml index f96aad9b20..6df994ddc6 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.QueryAsync.xml +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.QueryAsync.xml @@ -709,10 +709,10 @@ } ] }]]> - Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -1454,10 +1454,10 @@ } ] }]]> - Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -2172,10 +2172,10 @@ } ] }]]> - Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -2918,10 +2918,10 @@ } ] }]]> - Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -3743,10 +3743,10 @@ } ] }]]> - Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -4472,10 +4472,10 @@ } ] }]]> - Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -5229,10 +5229,10 @@ } ] }]]> - Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ReadFeedAsync.xml b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ReadFeedAsync.xml index 942aea529f..5c216708e9 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ReadFeedAsync.xml +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ReadFeedAsync.xml @@ -671,10 +671,10 @@ } ] }]]> - Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -1378,10 +1378,10 @@ } ] }]]> - Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -2058,10 +2058,10 @@ } ] }]]> - Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.FeedIterator Read Next Asynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -2766,10 +2766,10 @@ } ] }]]> - Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.Typed FeedIterator ReadNextAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ReadManyAsync.xml b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ReadManyAsync.xml index 537ad2d469..cba8c804ca 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ReadManyAsync.xml +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.ReadManyAsync.xml @@ -681,12 +681,12 @@ } ] }]]> - Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted -Cosmos.ReadManyItemsStreamAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted +Cosmos.ReadManyItemsStreamAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -1390,7 +1390,7 @@ } ] }]]> - Cosmos.ReadManyItemsAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.ReadManyItemsAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.StreamPointOperationsAsync.xml b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.StreamPointOperationsAsync.xml index 577f41b00f..d66946bd38 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.StreamPointOperationsAsync.xml +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.StreamPointOperationsAsync.xml @@ -102,7 +102,7 @@ } ] }]]> - Cosmos.CreateItemStreamAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.CreateItemStreamAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -203,7 +203,7 @@ } ] }]]> - Cosmos.ReadItemStreamAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.ReadItemStreamAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -312,7 +312,7 @@ } ] }]]> - Cosmos.ReplaceItemStreamAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.ReplaceItemStreamAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -416,7 +416,7 @@ } ] }]]> - Cosmos.DeleteItemStreamAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.DeleteItemStreamAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.TypedPointOperationsAsync.xml b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.TypedPointOperationsAsync.xml index 8aa1022b1b..8cfc4dce1a 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.TypedPointOperationsAsync.xml +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/BaselineTest/TestBaseline/EndToEndTraceWriterBaselineTests.TypedPointOperationsAsync.xml @@ -130,7 +130,7 @@ } ] }]]> - Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.CreateItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -238,7 +238,7 @@ } ] }]]> - Cosmos.ReadItemAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.ReadItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -361,7 +361,7 @@ } ] }]]> - Cosmos.ReplaceItemAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.ReplaceItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted @@ -471,7 +471,7 @@ } ] }]]> - Cosmos.DeleteItemAsynckindaz.namespacedb.systemdb.operationdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted + Cosmos.DeleteItemAsynckindaz.namespacedb.systemdb.cosmosdb.machine_idnet.peer.namedb.cosmosdb.client_iddb.cosmosdb.user_agentdb.cosmosdb.connection_modedb.operationdb.namedb.cosmosdb.containerdb.cosmosdb.request_content_length_bytesdb.cosmosdb.response_content_length_bytesdb.cosmosdb.status_codedb.cosmosdb.request_chargedb.cosmosdb.item_countdb.cosmosdb.regions_contacted diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Tracing/EndToEndTraceWriterBaselineTests.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Tracing/EndToEndTraceWriterBaselineTests.cs index 8f0c7f98ae..3094a69238 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Tracing/EndToEndTraceWriterBaselineTests.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Tracing/EndToEndTraceWriterBaselineTests.cs @@ -19,6 +19,7 @@ using Microsoft.Azure.Cosmos.Tracing; using Microsoft.VisualStudio.TestTools.UnitTesting; using Newtonsoft.Json.Linq; + using Telemetry; using static Microsoft.Azure.Cosmos.SDK.EmulatorTests.TransportClientHelper; [VisualStudio.TestTools.UnitTesting.TestClass] @@ -26,19 +27,71 @@ public sealed class EndToEndTraceWriterBaselineTests : BaselineTests { public static CosmosClient client; + public static CosmosClient bulkClient; + public static CosmosClient throttleClient; + public static CosmosClient miscCosmosClient; + public static Database database; public static Container container; private static OpenTelemetryListener testListener; + private static readonly TimeSpan delayTime = TimeSpan.FromSeconds(2); + private static readonly RequestHandler requestHandler = new RequestHandlerSleepHelper(delayTime); [ClassInitialize()] public static async Task ClassInitAsync(TestContext context) { testListener = new OpenTelemetryListener("Azure.Cosmos"); + string errorMessage = "Mock throttle exception" + Guid.NewGuid().ToString(); + Guid exceptionActivityId = Guid.NewGuid(); + client = Microsoft.Azure.Cosmos.SDK.EmulatorTests.TestCommon.CreateCosmosClient( - useGateway: false, - isOpenTelemetryFeatureEnabled: true); + useGateway: false); + bulkClient = TestCommon.CreateCosmosClient(builder => builder + .WithBulkExecution(true)); + // Set a small retry count to reduce test time + throttleClient = TestCommon.CreateCosmosClient(builder => + builder.WithThrottlingRetryOptions(TimeSpan.FromSeconds(5), 3) + .WithBulkExecution(true) + .WithTransportClientHandlerFactory(transportClient => new TransportClientWrapper( + transportClient, + (uri, resourceOperation, request) => TransportClientHelper.ReturnThrottledStoreResponseOnItemOperation( + uri, + resourceOperation, + request, + exceptionActivityId, + errorMessage)))); + miscCosmosClient = TestCommon.CreateCosmosClient(builder => + builder + .AddCustomHandlers(requestHandler)); + +#if !PREVIEW + client.ClientOptions.EnableDistributedTracing = true; + bulkClient.ClientOptions.EnableDistributedTracing = true; + throttleClient.ClientOptions.EnableDistributedTracing = true; + miscCosmosClient.ClientOptions.EnableDistributedTracing = true; + +#endif + client.ClientOptions.DistributedTracingOptions = new DistributedTracingOptions() + { + DiagnosticsLatencyThreshold = TimeSpan.FromMilliseconds(1) + }; + + bulkClient.ClientOptions.DistributedTracingOptions = new DistributedTracingOptions() + { + DiagnosticsLatencyThreshold = TimeSpan.FromMilliseconds(1) + }; + + throttleClient.ClientOptions.DistributedTracingOptions = new DistributedTracingOptions() + { + DiagnosticsLatencyThreshold = TimeSpan.FromMilliseconds(1) + }; + + miscCosmosClient.ClientOptions.DistributedTracingOptions = new DistributedTracingOptions() + { + DiagnosticsLatencyThreshold = TimeSpan.FromMilliseconds(1) + }; EndToEndTraceWriterBaselineTests.database = await client.CreateDatabaseAsync( Guid.NewGuid().ToString(), @@ -70,6 +123,8 @@ public static async Task ClassCleanupAsync() { await EndToEndTraceWriterBaselineTests.database.DeleteStreamAsync(); } + + testListener?.Dispose(); } [TestMethod] @@ -936,18 +991,6 @@ public async Task PointOperationsExceptionsAsync() startLineNumber = GetLineNumber(); string errorMessage = "Mock throttle exception" + Guid.NewGuid().ToString(); Guid exceptionActivityId = Guid.NewGuid(); - // Set a small retry count to reduce test time - CosmosClient throttleClient = TestCommon.CreateCosmosClient(builder => - builder.WithThrottlingRetryOptions(TimeSpan.FromSeconds(5), 5) - .WithTransportClientHandlerFactory(transportClient => new TransportClientWrapper( - transportClient, - (uri, resourceOperation, request) => TransportClientHelper.ReturnThrottledStoreResponseOnItemOperation( - uri, - resourceOperation, - request, - exceptionActivityId, - errorMessage))) - ); ItemRequestOptions requestOptions = new ItemRequestOptions(); Container containerWithThrottleException = throttleClient.GetContainer( @@ -1171,7 +1214,7 @@ public async Task BulkOperationsAsync() { startLineNumber = GetLineNumber(); string pkValue = "DiagnosticBulkTestPk"; - CosmosClient bulkClient = TestCommon.CreateCosmosClient(builder => builder.WithBulkExecution(true)); + Container bulkContainer = bulkClient.GetContainer(database.Id, container.Id); List>> createItemsTasks = new List>>(); @@ -1215,21 +1258,6 @@ public async Task BulkOperationsAsync() //---------------------------------------------------------------- { startLineNumber = GetLineNumber(); - string errorMessage = "Mock throttle exception" + Guid.NewGuid().ToString(); - Guid exceptionActivityId = Guid.NewGuid(); - // Set a small retry count to reduce test time - CosmosClient throttleClient = TestCommon.CreateCosmosClient(builder => - builder.WithThrottlingRetryOptions(TimeSpan.FromSeconds(5), 3) - .WithBulkExecution(true) - .WithTransportClientHandlerFactory(transportClient => new TransportClientWrapper( - transportClient, - (uri, resourceOperation, request) => TransportClientHelper.ReturnThrottledStoreResponseOnItemOperation( - uri, - resourceOperation, - request, - exceptionActivityId, - errorMessage))) - ); ItemRequestOptions requestOptions = new ItemRequestOptions(); Container containerWithThrottleException = throttleClient.GetContainer( @@ -1273,12 +1301,8 @@ public async Task MiscellanousAsync() //---------------------------------------------------------------- { startLineNumber = GetLineNumber(); - TimeSpan delayTime = TimeSpan.FromSeconds(2); - RequestHandler requestHandler = new RequestHandlerSleepHelper(delayTime); - CosmosClient cosmosClient = TestCommon.CreateCosmosClient(builder => - builder.AddCustomHandlers(requestHandler)); - - DatabaseResponse databaseResponse = await cosmosClient.CreateDatabaseAsync(Guid.NewGuid().ToString()); + + DatabaseResponse databaseResponse = await miscCosmosClient.CreateDatabaseAsync(Guid.NewGuid().ToString()); EndToEndTraceWriterBaselineTests.AssertCustomHandlerTime( databaseResponse.Diagnostics.ToString(), requestHandler.FullHandlerName, diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Tracing/OpenTelemetryListener.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Tracing/OpenTelemetryListener.cs index c18457acfb..425d963656 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Tracing/OpenTelemetryListener.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Tracing/OpenTelemetryListener.cs @@ -11,8 +11,8 @@ namespace Microsoft.Azure.Cosmos.Tests using System.Reflection; using System.Text; using System.Threading; - using Microsoft.Azure.Cosmos.Telemetry.Diagnostics; - using Microsoft.VisualStudio.TestTools.UnitTesting; + using Telemetry; + using VisualStudio.TestTools.UnitTesting; public class OpenTelemetryListener : IObserver>, IObserver, IDisposable { diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Utils/TestCommon.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Utils/TestCommon.cs index 06dd543641..e85f9c565c 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Utils/TestCommon.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.EmulatorTests/Utils/TestCommon.cs @@ -126,8 +126,7 @@ internal static CosmosClient CreateCosmosClient( internal static CosmosClient CreateCosmosClient( bool useGateway, - Action customizeClientBuilder = null, - bool isOpenTelemetryFeatureEnabled = false) + Action customizeClientBuilder = null) { CosmosClientBuilder cosmosClientBuilder = GetDefaultConfiguration(); @@ -137,12 +136,7 @@ internal static CosmosClient CreateCosmosClient( { cosmosClientBuilder.WithConnectionModeGateway(); } - - if (isOpenTelemetryFeatureEnabled) - { - cosmosClientBuilder.EnableOpenTelemetry(); - } - + return cosmosClientBuilder.Build(); } diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncBatcherTests.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncBatcherTests.cs index 7754692307..28913390ec 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncBatcherTests.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncBatcherTests.cs @@ -12,7 +12,7 @@ namespace Microsoft.Azure.Cosmos.Tests using System.Threading; using System.Threading.Tasks; using Microsoft.Azure.Cosmos.Routing; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; + using Microsoft.Azure.Cosmos.Telemetry; using Microsoft.Azure.Cosmos.Tracing; using Microsoft.Azure.Documents; using Microsoft.VisualStudio.TestTools.UnitTesting; diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncContainerExecutorTests.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncContainerExecutorTests.cs index 7749aedb27..a51ff0ef3a 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncContainerExecutorTests.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncContainerExecutorTests.cs @@ -13,7 +13,7 @@ namespace Microsoft.Azure.Cosmos.Tests using System.Threading; using System.Threading.Tasks; using Microsoft.Azure.Cosmos.Routing; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; + using Microsoft.Azure.Cosmos.Telemetry; using Microsoft.Azure.Cosmos.Tracing; using Microsoft.Azure.Cosmos.Tracing.TraceData; using Microsoft.Azure.Documents; diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncStreamerTests.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncStreamerTests.cs index e0a90bda75..9e72ada29b 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncStreamerTests.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Batch/BatchAsyncStreamerTests.cs @@ -10,7 +10,7 @@ namespace Microsoft.Azure.Cosmos.Tests using System.Net; using System.Threading; using System.Threading.Tasks; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; + using Microsoft.Azure.Cosmos.Telemetry; using Microsoft.Azure.Cosmos.Tracing; using Microsoft.Azure.Documents; using Microsoft.VisualStudio.TestTools.UnitTesting; diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/ChangeFeed/ChangeFeedEstimatorIteratorTests.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/ChangeFeed/ChangeFeedEstimatorIteratorTests.cs index 1cd2731542..bf33fe06a5 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/ChangeFeed/ChangeFeedEstimatorIteratorTests.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/ChangeFeed/ChangeFeedEstimatorIteratorTests.cs @@ -11,7 +11,7 @@ namespace Microsoft.Azure.Cosmos.ChangeFeed.Tests using System.Threading; using System.Threading.Tasks; using Microsoft.Azure.Cosmos.ChangeFeed.LeaseManagement; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; + using Microsoft.Azure.Cosmos.Telemetry; using Microsoft.Azure.Cosmos.Tests; using Microsoft.Azure.Cosmos.Tracing; using Microsoft.VisualStudio.TestTools.UnitTesting; diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/ChangeFeed/ChangeFeedPartitionKeyResultSetIteratorCoreTests.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/ChangeFeed/ChangeFeedPartitionKeyResultSetIteratorCoreTests.cs index c3d9763ff5..42de6190f4 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/ChangeFeed/ChangeFeedPartitionKeyResultSetIteratorCoreTests.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/ChangeFeed/ChangeFeedPartitionKeyResultSetIteratorCoreTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.Azure.Cosmos.ChangeFeed.Tests using System.Threading; using System.Threading.Tasks; using Microsoft.Azure.Cosmos.ChangeFeed.LeaseManagement; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; + using Microsoft.Azure.Cosmos.Telemetry; using Microsoft.Azure.Cosmos.Tests; using Microsoft.Azure.Cosmos.Tracing; using Microsoft.VisualStudio.TestTools.UnitTesting; diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Contracts/DotNetPreviewSDKAPI.json b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Contracts/DotNetPreviewSDKAPI.json index 1b7027630a..07d725e2c5 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Contracts/DotNetPreviewSDKAPI.json +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Contracts/DotNetPreviewSDKAPI.json @@ -304,31 +304,6 @@ }, "NestedTypes": {} }, - "Microsoft.Azure.Cosmos.CosmosClientOptions;System.Object;IsAbstract:False;IsSealed:False;IsInterface:False;IsEnum:False;IsClass:True;IsValueType:False;IsNested:False;IsGenericType:False;IsSerializable:False": { - "Subclasses": {}, - "Members": { - "Boolean EnableOpenTelemetry": { - "Type": "Property", - "Attributes": [], - "MethodInfo": "Boolean EnableOpenTelemetry;CanRead:True;CanWrite:True;Boolean get_EnableOpenTelemetry();IsAbstract:False;IsStatic:False;IsVirtual:False;IsGenericMethod:False;IsConstructor:False;IsFinal:False;Void set_EnableOpenTelemetry(Boolean);IsAbstract:False;IsStatic:False;IsVirtual:False;IsGenericMethod:False;IsConstructor:False;IsFinal:False;" - }, - "Boolean get_EnableOpenTelemetry()[System.Runtime.CompilerServices.CompilerGeneratedAttribute()]": { - "Type": "Method", - "Attributes": [ - "CompilerGeneratedAttribute" - ], - "MethodInfo": "Boolean get_EnableOpenTelemetry();IsAbstract:False;IsStatic:False;IsVirtual:False;IsGenericMethod:False;IsConstructor:False;IsFinal:False;" - }, - "Void set_EnableOpenTelemetry(Boolean)[System.Runtime.CompilerServices.CompilerGeneratedAttribute()]": { - "Type": "Method", - "Attributes": [ - "CompilerGeneratedAttribute" - ], - "MethodInfo": "Void set_EnableOpenTelemetry(Boolean);IsAbstract:False;IsStatic:False;IsVirtual:False;IsGenericMethod:False;IsConstructor:False;IsFinal:False;" - } - }, - "NestedTypes": {} - }, "Microsoft.Azure.Cosmos.Fluent.ChangeFeedPolicyDefinition;System.Object;IsAbstract:False;IsSealed:False;IsInterface:False;IsEnum:False;IsClass:True;IsValueType:False;IsNested:False;IsGenericType:False;IsSerializable:False": { "Subclasses": {}, "Members": { @@ -351,17 +326,6 @@ }, "NestedTypes": {} }, - "Microsoft.Azure.Cosmos.Fluent.CosmosClientBuilder;System.Object;IsAbstract:False;IsSealed:False;IsInterface:False;IsEnum:False;IsClass:True;IsValueType:False;IsNested:False;IsGenericType:False;IsSerializable:False": { - "Subclasses": {}, - "Members": { - "Microsoft.Azure.Cosmos.Fluent.CosmosClientBuilder EnableOpenTelemetry()": { - "Type": "Method", - "Attributes": [], - "MethodInfo": "Microsoft.Azure.Cosmos.Fluent.CosmosClientBuilder EnableOpenTelemetry();IsAbstract:False;IsStatic:False;IsVirtual:False;IsGenericMethod:False;IsConstructor:False;IsFinal:False;" - } - }, - "NestedTypes": {} - }, "Microsoft.Azure.Cosmos.Linq.CosmosLinqExtensions;System.Object;IsAbstract:True;IsSealed:True;IsInterface:False;IsEnum:False;IsClass:True;IsValueType:False;IsNested:False;IsGenericType:False;IsSerializable:False": { "Subclasses": {}, "Members": { diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/CosmosClientOptionsUnitTests.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/CosmosClientOptionsUnitTests.cs index f9676f6627..cf2a2083ce 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/CosmosClientOptionsUnitTests.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/CosmosClientOptionsUnitTests.cs @@ -7,11 +7,10 @@ namespace Microsoft.Azure.Cosmos.Tests using System; using System.Collections; using System.Collections.Generic; - using System.IO; using System.Linq; using System.Net; using System.Net.Http; - using System.Reflection; + using Cosmos.Telemetry; using global::Azure.Core; using Microsoft.Azure.Cosmos.Fluent; using Microsoft.Azure.Documents; @@ -57,7 +56,7 @@ public void VerifyCosmosConfigurationPropertiesGetUpdated() CosmosClientBuilder cosmosClientBuilder = new CosmosClientBuilder( accountEndpoint: endpoint, authKeyOrResourceToken: key); - + CosmosClient cosmosClient = cosmosClientBuilder.Build(new MockDocumentClient()); CosmosClientOptions clientOptions = cosmosClient.ClientOptions; @@ -146,7 +145,7 @@ public void VerifyCosmosConfigurationPropertiesGetUpdated() Assert.AreEqual((int)maxRetryWaitTime.TotalSeconds, policy.RetryOptions.MaxRetryWaitTimeInSeconds); Assert.AreEqual((Documents.ConsistencyLevel)consistencyLevel, clientOptions.GetDocumentsConsistencyLevel()); Assert.IsTrue(policy.EnablePartitionLevelFailover); - + IReadOnlyList preferredLocations = new List() { Regions.AustraliaCentral, Regions.AustraliaCentral2 }; //Verify Direct Mode settings cosmosClientBuilder = new CosmosClientBuilder( @@ -159,7 +158,11 @@ public void VerifyCosmosConfigurationPropertiesGetUpdated() maxTcpConnectionsPerEndpoint, portReuseMode, enableTcpConnectionEndpointRediscovery) - .WithApplicationPreferredRegions(preferredLocations); + .WithApplicationPreferredRegions(preferredLocations) + .WithDistributingTracing(new DistributedTracingOptions + { + DiagnosticsLatencyThreshold = TimeSpan.FromMilliseconds(100) + }); cosmosClient = cosmosClientBuilder.Build(new MockDocumentClient()); clientOptions = cosmosClient.ClientOptions; @@ -171,6 +174,8 @@ public void VerifyCosmosConfigurationPropertiesGetUpdated() Assert.AreEqual(portReuseMode, clientOptions.PortReuseMode); Assert.IsTrue(clientOptions.EnableTcpConnectionEndpointRediscovery); CollectionAssert.AreEqual(preferredLocations.ToArray(), clientOptions.ApplicationPreferredRegions.ToArray()); + Assert.AreEqual(TimeSpan.FromMilliseconds(100), clientOptions.DistributedTracingOptions.DiagnosticsLatencyThreshold); + Assert.IsFalse(clientOptions.EnableDistributedTracing); //Verify GetConnectionPolicy returns the correct values policy = clientOptions.GetConnectionPolicy(clientId: 0); diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/CosmosItemUnitTests.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/CosmosItemUnitTests.cs index 4eb2be4067..589ad47efc 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/CosmosItemUnitTests.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/CosmosItemUnitTests.cs @@ -10,7 +10,7 @@ namespace Microsoft.Azure.Cosmos.Tests using System.Net; using System.Threading; using System.Threading.Tasks; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; + using Microsoft.Azure.Cosmos.Telemetry; using Microsoft.Azure.Cosmos.Tracing; using Microsoft.Azure.Documents; using Microsoft.VisualStudio.TestTools.UnitTesting; diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/FeedRange/ChangeFeedIteratorCoreTests.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/FeedRange/ChangeFeedIteratorCoreTests.cs index 7f5db38a83..9024759fbd 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/FeedRange/ChangeFeedIteratorCoreTests.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/FeedRange/ChangeFeedIteratorCoreTests.cs @@ -15,7 +15,7 @@ namespace Microsoft.Azure.Cosmos.Tests.FeedRange using Microsoft.Azure.Cosmos.Pagination; using Microsoft.Azure.Cosmos.Query.Core.Monads; using Microsoft.Azure.Cosmos.Resource.CosmosExceptions; - using Microsoft.Azure.Cosmos.Telemetry.OpenTelemetry; + using Microsoft.Azure.Cosmos.Telemetry; using Microsoft.Azure.Cosmos.Tests.Pagination; using Microsoft.Azure.Cosmos.Tracing; using Microsoft.Azure.Documents; diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Telemetry/DiagnosticsFilterHelperTest.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Telemetry/DiagnosticsFilterHelperTest.cs new file mode 100644 index 0000000000..b86883c451 --- /dev/null +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Telemetry/DiagnosticsFilterHelperTest.cs @@ -0,0 +1,85 @@ +//------------------------------------------------------------ +// Copyright (c) Microsoft Corporation. All rights reserved. +//------------------------------------------------------------ + +namespace Microsoft.Azure.Cosmos.Tests.Telemetry +{ + using System; + using System.Collections.Generic; + using System.Linq; + using System.Net; + using System.Text; + using System.Threading.Tasks; + using Cosmos.Telemetry; + using Cosmos.Telemetry.Diagnostics; + using Cosmos.Tracing; + using Diagnostics; + using Documents; + using VisualStudio.TestTools.UnitTesting; + + + [TestClass] + public class DiagnosticsFilterHelperTest + { + private Trace rootTrace; + [TestInitialize] + public void Initialize() + { + using (this.rootTrace = Trace.GetRootTrace(name: "RootTrace")) + { + Task.Delay(1).Wait(); + } + } + + [TestMethod] + public void CheckReturnFalseOnSuccessAndLowerLatencyThanConfiguredConfig() + { + Assert.IsTrue(this.rootTrace.Duration > TimeSpan.Zero); + + DistributedTracingOptions distributedTracingOptions = new DistributedTracingOptions + { + DiagnosticsLatencyThreshold = TimeSpan.FromMilliseconds(20) + }; + + OpenTelemetryAttributes response = new OpenTelemetryAttributes + { + StatusCode = HttpStatusCode.Accepted, + Diagnostics = new CosmosTraceDiagnostics(this.rootTrace) + }; + + Assert.IsFalse( + DiagnosticsFilterHelper + .IsTracingNeeded(distributedTracingOptions, response), + $" Response time is {response.Diagnostics.GetClientElapsedTime().Milliseconds}ms " + + $"and Configured threshold value is {distributedTracingOptions.DiagnosticsLatencyThreshold.Value.Milliseconds}ms " + + $"and Is response Success : {response.StatusCode.IsSuccess()}" ); + } + + [TestMethod] + public void CheckReturnTrueOnFailedStatusCode() + { + Assert.IsTrue(this.rootTrace.Duration > TimeSpan.Zero); + + + DistributedTracingOptions distributedTracingOptions = new DistributedTracingOptions + { + DiagnosticsLatencyThreshold = TimeSpan.FromMilliseconds(20) + }; + + OpenTelemetryAttributes response = new OpenTelemetryAttributes + { + StatusCode = HttpStatusCode.BadRequest, + Diagnostics = new CosmosTraceDiagnostics(this.rootTrace) + }; + + Assert.IsTrue( + DiagnosticsFilterHelper + .IsTracingNeeded(distributedTracingOptions, response), + $" Response time is {response.Diagnostics.GetClientElapsedTime().Milliseconds}ms " + + $"and Configured threshold value is {distributedTracingOptions.DiagnosticsLatencyThreshold.Value.Milliseconds}ms " + + $"and Is response Success : {response.StatusCode.IsSuccess()}"); + + } + + } +} diff --git a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Telemetry/OpenTelemetryRecorderTests.cs b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Telemetry/OpenTelemetryRecorderTests.cs index 718f9572d9..2095999f6c 100644 --- a/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Telemetry/OpenTelemetryRecorderTests.cs +++ b/Microsoft.Azure.Cosmos/tests/Microsoft.Azure.Cosmos.Tests/Telemetry/OpenTelemetryRecorderTests.cs @@ -8,10 +8,8 @@ namespace Microsoft.Azure.Cosmos.Tests.Telemetry using System.Collections.Generic; using System.Linq; using System.Reflection; - using Microsoft.Azure.Cosmos.Core.Trace; + using Cosmos.Telemetry; using Microsoft.Azure.Cosmos.Diagnostics; - using Microsoft.Azure.Cosmos.Telemetry.Diagnostics; - using Microsoft.Azure.Cosmos.Tests.Contracts; using Microsoft.Azure.Cosmos.Tracing; using Microsoft.VisualStudio.TestTools.UnitTesting; @@ -41,7 +39,7 @@ public void CheckExceptionsCompatibility() foreach(Type className in actualClasses) { - Assert.IsTrue(OpenTelemetryCoreRecorder.oTelCompatibleExceptions.Keys.Contains(className), $"{className.Name} is not added in {typeof(OpenTelemetryCoreRecorder).Name} Class oTelCompatibleExceptions dictionary"); + Assert.IsTrue(OpenTelemetryCoreRecorder.OTelCompatibleExceptions.Keys.Contains(className), $"{className.Name} is not added in {typeof(OpenTelemetryCoreRecorder).Name} Class OTelCompatibleExceptions dictionary"); } }