Skip to content

Commit

Permalink
compilation charges
Browse files Browse the repository at this point in the history
  • Loading branch information
sourabh1007 committed Sep 1, 2023
1 parent fb3ae09 commit 2dd1c05
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ internal Microsoft.Azure.Cosmos.CosmosClient CreateCosmosClient(string accountKe
MaxTcpConnectionsPerEndpoint = this.MaxTcpConnectionsPerEndpoint,
CosmosClientTelemetryOptions = new Microsoft.Azure.Cosmos.CosmosClientTelemetryOptions()
{
EnableSendingMetricsToService = this.EnableTelemetry,
EnableSendingMetricsToService = this.EnableClientTelemetry,
DisableDistributedTracing = !this.EnableDistributedTracing
}
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,10 @@ public virtual void TestInitialize()
};

this.cosmosClientBuilder = this.GetBuilder()
.WithTelemetryEnabled()
.WithClientTelemetryOptions(new CosmosClientTelemetryOptions()
{
EnableSendingMetricsToService = true
})
.WithApplicationPreferredRegions(ClientTelemetryTestsBase.preferredRegionList);
}

Expand Down Expand Up @@ -666,7 +669,10 @@ public virtual async Task CreateItemWithSubStatusCodeTest(ConnectionMode mode)

// Replacing originally initialized cosmos Builder with this one with new handler
this.cosmosClientBuilder = this.cosmosClientBuilder
.WithTelemetryEnabled()
.WithClientTelemetryOptions(new CosmosClientTelemetryOptions()
{
EnableSendingMetricsToService = true
})
.WithHttpClientFactory(() => new HttpClient(httpHandler));

Container container = await this.CreateClientAndContainer(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,10 @@ public void VerifySynchronizationContextDoesNotLock(bool withClientTelemetry)
{
using (CosmosClient client = TestCommon.CreateCosmosClient(
customizeClientBuilder: (builder) => builder
.WithTelemetryEnabled()
.WithClientTelemetryOptions(new CosmosClientTelemetryOptions ()
{
EnableSendingMetricsToService = withClientTelemetry
})
.WithHttpClientFactory(() => new HttpClient(httpHandler))))
{
Cosmos.Database database = client.CreateDatabaseAsync(databaseId).GetAwaiter().GetResult();
Expand Down

0 comments on commit 2dd1c05

Please sign in to comment.