minor clean up (#26)
This commit is contained in:
parent
57f23060e7
commit
68421615fe
|
|
@ -3,7 +3,7 @@
|
||||||
variables:
|
variables:
|
||||||
DotNetVersion: "2.2.101"
|
DotNetVersion: "2.2.101"
|
||||||
|
|
||||||
pr: [ 'master', 'develop' ]
|
pr: [ 'master' ]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
|
|
@ -21,7 +21,7 @@ jobs:
|
||||||
displayName: build solution (Release)
|
displayName: build solution (Release)
|
||||||
inputs:
|
inputs:
|
||||||
command: "build"
|
command: "build"
|
||||||
projects: "OpenTelemetry.proj"
|
projects: OpenTelemetry.sln
|
||||||
arguments: "--configuration Release"
|
arguments: "--configuration Release"
|
||||||
|
|
||||||
# consider switch to https://docs.microsoft.com/vsts/pipelines/tasks/test/vstest?view=vsts
|
# consider switch to https://docs.microsoft.com/vsts/pipelines/tasks/test/vstest?view=vsts
|
||||||
|
|
@ -47,7 +47,7 @@ jobs:
|
||||||
displayName: build
|
displayName: build
|
||||||
inputs:
|
inputs:
|
||||||
command: "build"
|
command: "build"
|
||||||
projects: "OpenTelemetry.proj"
|
projects: OpenTelemetry.sln
|
||||||
arguments: "--configuration Release"
|
arguments: "--configuration Release"
|
||||||
|
|
||||||
- task: DotNetCoreCLI@2
|
- task: DotNetCoreCLI@2
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,6 @@ trigger:
|
||||||
branches:
|
branches:
|
||||||
include:
|
include:
|
||||||
- master
|
- master
|
||||||
- develop
|
|
||||||
|
|
||||||
queue: Hosted VS2017
|
queue: Hosted VS2017
|
||||||
|
|
||||||
|
|
@ -22,7 +21,7 @@ steps:
|
||||||
displayName: pack solution with symbols (Release)
|
displayName: pack solution with symbols (Release)
|
||||||
inputs:
|
inputs:
|
||||||
command: "pack"
|
command: "pack"
|
||||||
projects: "OpenTelemetry.proj"
|
projects: OpenTelemetry.sln
|
||||||
configuration: 'Release'
|
configuration: 'Release'
|
||||||
packDirectory: '$(build.artifactStagingDirectory)'
|
packDirectory: '$(build.artifactStagingDirectory)'
|
||||||
buildProperties: "SymbolPackageFormat=snupkg"
|
buildProperties: "SymbolPackageFormat=snupkg"
|
||||||
|
|
|
||||||
34
CHANGELOG.md
34
CHANGELOG.md
|
|
@ -7,34 +7,6 @@ the release.
|
||||||
|
|
||||||
## Unreleased
|
## Unreleased
|
||||||
|
|
||||||
- API improvements - use C# native classes to measure time.
|
- Copy from
|
||||||
- OpenTelemetry.Collectors.AspNetCore: Allow to supply custom sampler based on request properties using custom code. For instance filter out telemetry from specific path.
|
[OpenCensus](http://github.com/census-instrumentation/opencensus-csharp) at
|
||||||
- OpenTelemetry.Collectors.Dependencies: Allow to supply custom sampler based on request properties using custom code. By default, filter out calls to Zipkin REST endpoint from the exporter.
|
commit #`0474607a16282252697f989113d68bdf71959070`.
|
||||||
|
|
||||||
## 0.1.0-alpha-42253
|
|
||||||
|
|
||||||
Release [01/18/2019](https://github.com/census-instrumentation/OpenTelemetry-csharp/releases/tag/0.1.0-alpha-42253).
|
|
||||||
|
|
||||||
- Application Insights exporter improvements - now understands http attributes
|
|
||||||
and process links, annotations and messages.
|
|
||||||
- ASP.NET Core collector now uses `http.route` for the span name.
|
|
||||||
- Initial implementation of Resource Specification.
|
|
||||||
- Plug in to collect Redis calls made using StackExchange.Redis package.
|
|
||||||
- Object of type `ISpanData` can be created using only Abstractions package.
|
|
||||||
- Number of minor APIs adjustments.
|
|
||||||
|
|
||||||
## 0.1.0-alpha-33381
|
|
||||||
|
|
||||||
Released
|
|
||||||
[12/18/2018](https://github.com/census-instrumentation/OpenTelemetry-csharp/releases/tag/0.1.0-alpha-33381).
|
|
||||||
|
|
||||||
- Collectors for ASP.NET Core and .NET Core HttpClient.
|
|
||||||
- Initial version of Ocagent exporter implemented.
|
|
||||||
- Initial version of StackDriver exporter implemented.
|
|
||||||
- Support double attributes according to the [spec
|
|
||||||
change](https://github.com/census-instrumentation/OpenTelemetry-specs/issues/172).
|
|
||||||
- Initial implementation of Prometheus exporter.
|
|
||||||
- Initial version of Application Insights exporter implemented.
|
|
||||||
- Zipkin exporter implemented.
|
|
||||||
- Initial version of SDK published. It is based on contribution from Pivotal
|
|
||||||
[from](https://github.com/SteeltoeOSS/Management/tree/dev/src/Steeltoe.Management.OpenTelemetry).
|
|
||||||
|
|
|
||||||
|
|
@ -7,20 +7,21 @@ Reporting bug is an important contribution. Please make sure to include:
|
||||||
- expected and actual behavior.
|
- expected and actual behavior.
|
||||||
- dotnet version that application is compiled on and running with (it may be
|
- dotnet version that application is compiled on and running with (it may be
|
||||||
different - for instance target framework was set to .NET 4.6 for
|
different - for instance target framework was set to .NET 4.6 for
|
||||||
compilaiton, but applicaiton is running on .NET 4.7.3).
|
compilation, but application is running on .NET 4.7.3).
|
||||||
- exception call stack and other artifacts.
|
- exception call stack and other artifacts.
|
||||||
- if possible - reporo application and steps to reproduce.
|
- if possible - repro application and steps to reproduce.
|
||||||
|
|
||||||
## How to contribute
|
## How to contribute
|
||||||
|
|
||||||
### Before started
|
### Before started
|
||||||
|
|
||||||
In order to protect both you and ourselves, you will need to sign the
|
Please read project contribution
|
||||||
[Contributor License Agreement](https://cla.developers.google.com/clas).
|
[guide](https://github.com/open-telemetry/community/blob/master/CONTRIBUTING.md)
|
||||||
|
for general practices for OpenTelemetry project.
|
||||||
|
|
||||||
### Build
|
### Build
|
||||||
|
|
||||||
You can use Visual Studio 2017 or VS code to contribute. Just open root folder
|
You can use Visual Studio 2017+ or VS code to contribute. Just open root folder
|
||||||
or `OpenTelemetry.sln` in your editor and follow normal development process.
|
or `OpenTelemetry.sln` in your editor and follow normal development process.
|
||||||
|
|
||||||
To build from command line you need `dotnet` version `2.0+`.
|
To build from command line you need `dotnet` version `2.0+`.
|
||||||
|
|
|
||||||
|
|
@ -1,19 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
||||||
<Import Project=".\build\Common.prod.props" />
|
|
||||||
|
|
||||||
<ItemGroup>
|
|
||||||
<Solution Include="OpenTelemetry.sln" />
|
|
||||||
</ItemGroup>
|
|
||||||
|
|
||||||
<!-- The only need for this file is to synchronize the PreReleaseVersion -->
|
|
||||||
|
|
||||||
<Target Name="Build">
|
|
||||||
<MSBuild Projects="@(Solution)" Targets="Restore;Build" ContinueOnError="ErrorAndStop" Properties="PreReleaseVersion=$(PreReleaseVersion)"/>
|
|
||||||
</Target>
|
|
||||||
|
|
||||||
<Target Name="Pack">
|
|
||||||
<MSBuild Projects="@(Solution)" Targets="Restore;Build;Pack" ContinueOnError="ErrorAndStop" Properties="PreReleaseVersion=$(PreReleaseVersion)"/>
|
|
||||||
</Target>
|
|
||||||
|
|
||||||
</Project>
|
|
||||||
45
README.md
45
README.md
|
|
@ -1,17 +1,19 @@
|
||||||
# OpenTelemetry .NET SDK - distributed tracing and stats collection framework
|
# OpenTelemetry .NET SDK - distributed tracing and stats collection framework
|
||||||
|
|
||||||
[![Gitter chat][gitter-image]][gitter-url]
|
.NET Channel: [![Gitter chat][dotnet-gitter-image]][dotnet-gitter-url]
|
||||||
[](https://OpenTelemetry.visualstudio.com/continuous-integration/_build/latest?definitionId=3)
|
|
||||||
|
Community Channel: [![Gitter chat][main-gitter-image]][main-gitter-url]
|
||||||
|
|
||||||
|
[](https://dev.azure.com/opentelemetry/pipelines/_build/latest?definitionId=1&branchName=master)
|
||||||
|
|
||||||
OpenTelemetry is a toolkit for collecting application performance and behavior
|
OpenTelemetry is a toolkit for collecting application performance and behavior
|
||||||
data. It currently includes 3 APIs: stats, tracing and tags.
|
data.
|
||||||
|
|
||||||
The library is in [Beta](#versioning) stage and APIs are expected to be mostly
|
The library is in [Alpha](#versioning) stage. The library is expected to move
|
||||||
stable. The library is expected to move to [GA](#versioning) stage after v1.0.0
|
to [GA](#versioning) stage after v1.0.0 major release.
|
||||||
major release.
|
|
||||||
|
|
||||||
Please join [gitter](https://gitter.im/census-instrumentation/Lobby) for help
|
Please join [gitter][dotnet-gitter-url] for help or feedback on this project.
|
||||||
or feedback on this project.
|
|
||||||
|
|
||||||
We encourage contributions. Use tags [up-for-grabs][up-for-grabs-issues] and
|
We encourage contributions. Use tags [up-for-grabs][up-for-grabs-issues] and
|
||||||
[good first issue][good-first-issues] to get started with the project. Follow
|
[good first issue][good-first-issues] to get started with the project. Follow
|
||||||
|
|
@ -57,6 +59,7 @@ Incoming requests of ASP.NET Core app can be automatically tracked.
|
||||||
[OpenTelemetry.Collector.AspNetCore][OpenTelemetry-collect-aspnetcore-nuget-url]
|
[OpenTelemetry.Collector.AspNetCore][OpenTelemetry-collect-aspnetcore-nuget-url]
|
||||||
|
|
||||||
2. Make sure `ITracer`, `ISampler`, and `IPropagationComponent` registered in DI.
|
2. Make sure `ITracer`, `ISampler`, and `IPropagationComponent` registered in DI.
|
||||||
|
|
||||||
``` csharp
|
``` csharp
|
||||||
services.AddSingleton<ITracer>(Tracing.Tracer);
|
services.AddSingleton<ITracer>(Tracing.Tracer);
|
||||||
services.AddSingleton<ISampler>(Samplers.AlwaysSample);
|
services.AddSingleton<ISampler>(Samplers.AlwaysSample);
|
||||||
|
|
@ -64,6 +67,7 @@ Incoming requests of ASP.NET Core app can be automatically tracked.
|
||||||
```
|
```
|
||||||
|
|
||||||
3. Configure data collection singletons in ConfigureServices method:
|
3. Configure data collection singletons in ConfigureServices method:
|
||||||
|
|
||||||
``` csharp
|
``` csharp
|
||||||
public void ConfigureServices(IServiceCollection services)
|
public void ConfigureServices(IServiceCollection services)
|
||||||
{
|
{
|
||||||
|
|
@ -73,6 +77,7 @@ Incoming requests of ASP.NET Core app can be automatically tracked.
|
||||||
```
|
```
|
||||||
|
|
||||||
4. Initialize data collection by instantiating singleton in Configure method
|
4. Initialize data collection by instantiating singleton in Configure method
|
||||||
|
|
||||||
``` csharp
|
``` csharp
|
||||||
public void Configure(IApplicationBuilder app, /*... other arguments*/ )
|
public void Configure(IApplicationBuilder app, /*... other arguments*/ )
|
||||||
{
|
{
|
||||||
|
|
@ -88,6 +93,7 @@ Outgoing http calls made by .NET Core `HttpClient` can be automatically tracked.
|
||||||
[OpenTelemetry.Collector.Dependencies][OpenTelemetry-collect-deps-nuget-url]
|
[OpenTelemetry.Collector.Dependencies][OpenTelemetry-collect-deps-nuget-url]
|
||||||
|
|
||||||
2. Make sure `ITracer`, `ISampler`, and `IPropagationComponent` registered in DI.
|
2. Make sure `ITracer`, `ISampler`, and `IPropagationComponent` registered in DI.
|
||||||
|
|
||||||
``` csharp
|
``` csharp
|
||||||
services.AddSingleton<ITracer>(Tracing.Tracer);
|
services.AddSingleton<ITracer>(Tracing.Tracer);
|
||||||
services.AddSingleton<ISampler>(Samplers.AlwaysSample);
|
services.AddSingleton<ISampler>(Samplers.AlwaysSample);
|
||||||
|
|
@ -95,6 +101,7 @@ Outgoing http calls made by .NET Core `HttpClient` can be automatically tracked.
|
||||||
```
|
```
|
||||||
|
|
||||||
3. Configure data collection singletons in ConfigureServices method:
|
3. Configure data collection singletons in ConfigureServices method:
|
||||||
|
|
||||||
``` csharp
|
``` csharp
|
||||||
public void ConfigureServices(IServiceCollection services)
|
public void ConfigureServices(IServiceCollection services)
|
||||||
{
|
{
|
||||||
|
|
@ -104,6 +111,7 @@ Outgoing http calls made by .NET Core `HttpClient` can be automatically tracked.
|
||||||
```
|
```
|
||||||
|
|
||||||
4. Initiate data collection by instantiating singleton in Configure method
|
4. Initiate data collection by instantiating singleton in Configure method
|
||||||
|
|
||||||
``` csharp
|
``` csharp
|
||||||
public void Configure(IApplicationBuilder app, /*... other arguments*/ )
|
public void Configure(IApplicationBuilder app, /*... other arguments*/ )
|
||||||
{
|
{
|
||||||
|
|
@ -119,6 +127,7 @@ Outgoing http calls to Redis made usign StackExchange.Redis library can be autom
|
||||||
[OpenTelemetry.Collector.StackExchangeRedis][OpenTelemetry-collect-stackexchange-redis-nuget-url]
|
[OpenTelemetry.Collector.StackExchangeRedis][OpenTelemetry-collect-stackexchange-redis-nuget-url]
|
||||||
|
|
||||||
2. Make sure `ITracer`, `ISampler`, and `IExportComponent` registered in DI.
|
2. Make sure `ITracer`, `ISampler`, and `IExportComponent` registered in DI.
|
||||||
|
|
||||||
``` csharp
|
``` csharp
|
||||||
services.AddSingleton<ITracer>(Tracing.Tracer);
|
services.AddSingleton<ITracer>(Tracing.Tracer);
|
||||||
services.AddSingleton<ISampler>(Samplers.AlwaysSample);
|
services.AddSingleton<ISampler>(Samplers.AlwaysSample);
|
||||||
|
|
@ -126,6 +135,7 @@ Outgoing http calls to Redis made usign StackExchange.Redis library can be autom
|
||||||
```
|
```
|
||||||
|
|
||||||
3. Configure data collection singletons in ConfigureServices method:
|
3. Configure data collection singletons in ConfigureServices method:
|
||||||
|
|
||||||
``` csharp
|
``` csharp
|
||||||
public void ConfigureServices(IServiceCollection services)
|
public void ConfigureServices(IServiceCollection services)
|
||||||
{
|
{
|
||||||
|
|
@ -135,6 +145,7 @@ Outgoing http calls to Redis made usign StackExchange.Redis library can be autom
|
||||||
```
|
```
|
||||||
|
|
||||||
4. Initiate data collection by instantiating singleton in Configure method
|
4. Initiate data collection by instantiating singleton in Configure method
|
||||||
|
|
||||||
``` csharp
|
``` csharp
|
||||||
public void Configure(IApplicationBuilder app, /*... other arguments*/ )
|
public void Configure(IApplicationBuilder app, /*... other arguments*/ )
|
||||||
{
|
{
|
||||||
|
|
@ -260,8 +271,10 @@ element is part of an API that is only meant to be used by exporters or other
|
||||||
OpenTelemetry libraries, then there is no deprecation period. Otherwise, we will
|
OpenTelemetry libraries, then there is no deprecation period. Otherwise, we will
|
||||||
deprecate it for 18 months before removing it, if possible.
|
deprecate it for 18 months before removing it, if possible.
|
||||||
|
|
||||||
[gitter-image]: https://badges.gitter.im/census-instrumentation/lobby.svg
|
[main-gitter-image]: https://badges.gitter.im/open-telemetry/community.svg
|
||||||
[gitter-url]:https://gitter.im/census-instrumentation/lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
|
[main-gitter-url]:https://gitter.im/open-telemetry/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
|
||||||
|
[dotnet-gitter-image]: https://badges.gitter.im/open-telemetry/opentelemetry-dotnet.svg
|
||||||
|
[dotnet-gitter-url]:https://gitter.im/open-telemetry/opentelemetry-dotnet?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
|
||||||
[OpenTelemetry-myget-image]:https://img.shields.io/myget/OpenTelemetry/vpre/OpenTelemetry.svg
|
[OpenTelemetry-myget-image]:https://img.shields.io/myget/OpenTelemetry/vpre/OpenTelemetry.svg
|
||||||
[OpenTelemetry-myget-url]: https://www.myget.org/feed/OpenTelemetry/package/nuget/OpenTelemetry
|
[OpenTelemetry-myget-url]: https://www.myget.org/feed/OpenTelemetry/package/nuget/OpenTelemetry
|
||||||
[OpenTelemetry-abs-myget-image]:https://img.shields.io/myget/OpenTelemetry/vpre/OpenTelemetry.Abstractions.svg
|
[OpenTelemetry-abs-myget-image]:https://img.shields.io/myget/OpenTelemetry/vpre/OpenTelemetry.Abstractions.svg
|
||||||
|
|
@ -298,8 +311,8 @@ deprecate it for 18 months before removing it, if possible.
|
||||||
[OpenTelemetry-collect-deps-nuget-url]: https://www.nuget.org/packages/OpenTelemetry.Collector.Dependencies
|
[OpenTelemetry-collect-deps-nuget-url]: https://www.nuget.org/packages/OpenTelemetry.Collector.Dependencies
|
||||||
[OpenTelemetry-collect-stackexchange-redis-nuget-image]:https://img.shields.io/nuget/vpre/OpenTelemetry.Collector.StackExchangeRedis.svg
|
[OpenTelemetry-collect-stackexchange-redis-nuget-image]:https://img.shields.io/nuget/vpre/OpenTelemetry.Collector.StackExchangeRedis.svg
|
||||||
[OpenTelemetry-collect-stackexchange-redis-nuget-url]: https://www.nuget.org/packages/OpenTelemetry.Collector.StackExchangeRedis
|
[OpenTelemetry-collect-stackexchange-redis-nuget-url]: https://www.nuget.org/packages/OpenTelemetry.Collector.StackExchangeRedis
|
||||||
[up-for-grabs-issues]: https://github.com/census-instrumentation/OpenTelemetry-csharp/issues?q=is%3Aissue+is%3Aopen+label%3Aup-for-grabs
|
[up-for-grabs-issues]: https://github.com/open-telemetry/OpenTelemetry-dotnet/issues?q=is%3Aissue+is%3Aopen+label%3Aup-for-grabs
|
||||||
[good-first-issues]: https://github.com/census-instrumentation/OpenTelemetry-csharp/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22
|
[good-first-issues]: https://github.com/open-telemetry/OpenTelemetry-dotnet/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22
|
||||||
[zipkin-get-started]: https://zipkin.io/pages/quickstart.html
|
[zipkin-get-started]: https://zipkin.io/pages/quickstart.html
|
||||||
[ai-get-started]: https://docs.microsoft.com/azure/application-insights
|
[ai-get-started]: https://docs.microsoft.com/azure/application-insights
|
||||||
[stackdriver-trace-setup]: https://cloud.google.com/trace/docs/setup/
|
[stackdriver-trace-setup]: https://cloud.google.com/trace/docs/setup/
|
||||||
|
|
@ -308,8 +321,8 @@ deprecate it for 18 months before removing it, if possible.
|
||||||
[GKE]: https://codelabs.developers.google.com/codelabs/cloud-kubernetes-aspnetcore/index.html?index=..%2F..index#0
|
[GKE]: https://codelabs.developers.google.com/codelabs/cloud-kubernetes-aspnetcore/index.html?index=..%2F..index#0
|
||||||
[gcp-auth]: https://cloud.google.com/docs/authentication/getting-started
|
[gcp-auth]: https://cloud.google.com/docs/authentication/getting-started
|
||||||
[semver]: http://semver.org/
|
[semver]: http://semver.org/
|
||||||
[ai-sample]: https://github.com/census-instrumentation/OpenTelemetry-csharp/blob/develop/src/Samples/TestApplicationInsights.cs
|
[ai-sample]: https://github.com/open-telemetry/OpenTelemetry-dotnet/blob/master/src/Samples/TestApplicationInsights.cs
|
||||||
[stackdriver-sample]: https://github.com/census-instrumentation/OpenTelemetry-csharp/blob/develop/src/Samples/TestStackdriver.cs
|
[stackdriver-sample]: https://github.com/open-telemetry/OpenTelemetry-dotnet/blob/master/src/Samples/TestStackdriver.cs
|
||||||
[zipkin-sample]: https://github.com/census-instrumentation/OpenTelemetry-csharp/blob/develop/src/Samples/TestZipkin.cs
|
[zipkin-sample]: https://github.com/open-telemetry/OpenTelemetry-dotnet/blob/master/src/Samples/TestZipkin.cs
|
||||||
[prometheus-get-started]: https://prometheus.io/docs/introduction/first_steps/
|
[prometheus-get-started]: https://prometheus.io/docs/introduction/first_steps/
|
||||||
[prometheus-sample]: https://github.com/census-instrumentation/OpenTelemetry-csharp/blob/develop/src/Samples/TestPrometheus.cs
|
[prometheus-sample]: https://github.com/open-telemetry/OpenTelemetry-dotnet/blob/master/src/Samples/TestPrometheus.cs
|
||||||
|
|
@ -1,10 +1,4 @@
|
||||||
{
|
{
|
||||||
// ACTION REQUIRED: This file was automatically added to your project, but it
|
|
||||||
// will not take effect until additional steps are taken to enable it. See the
|
|
||||||
// following page for additional information:
|
|
||||||
//
|
|
||||||
// https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/master/documentation/EnableConfiguration.md
|
|
||||||
|
|
||||||
"$schema": "https://raw.githubusercontent.com/DotNetAnalyzers/StyleCopAnalyzers/master/StyleCop.Analyzers/StyleCop.Analyzers/Settings/stylecop.schema.json",
|
"$schema": "https://raw.githubusercontent.com/DotNetAnalyzers/StyleCopAnalyzers/master/StyleCop.Analyzers/StyleCop.Analyzers/Settings/stylecop.schema.json",
|
||||||
"settings": {
|
"settings": {
|
||||||
"documentationRules": {
|
"documentationRules": {
|
||||||
|
|
|
||||||
Binary file not shown.
|
|
@ -23,7 +23,7 @@ namespace OpenTelemetry.Trace
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Helper method that populates span properties from http method according
|
/// Helper method that populates span properties from http method according
|
||||||
/// to https://github.com/census-instrumentation/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
/// to https://github.com/open-telemetry/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="span">Span to fill out.</param>
|
/// <param name="span">Span to fill out.</param>
|
||||||
/// <param name="method">Http method.</param>
|
/// <param name="method">Http method.</param>
|
||||||
|
|
@ -36,7 +36,7 @@ namespace OpenTelemetry.Trace
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Helper method that populates span properties from http status code according
|
/// Helper method that populates span properties from http status code according
|
||||||
/// to https://github.com/census-instrumentation/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
/// to https://github.com/open-telemetry/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="span">Span to fill out.</param>
|
/// <param name="span">Span to fill out.</param>
|
||||||
/// <param name="statusCode">Http status code.</param>
|
/// <param name="statusCode">Http status code.</param>
|
||||||
|
|
@ -49,7 +49,7 @@ namespace OpenTelemetry.Trace
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Helper method that populates span properties from http user agent according
|
/// Helper method that populates span properties from http user agent according
|
||||||
/// to https://github.com/census-instrumentation/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
/// to https://github.com/open-telemetry/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="span">Span to fill out.</param>
|
/// <param name="span">Span to fill out.</param>
|
||||||
/// <param name="userAgent">Http status code.</param>
|
/// <param name="userAgent">Http status code.</param>
|
||||||
|
|
@ -66,7 +66,7 @@ namespace OpenTelemetry.Trace
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Helper method that populates span properties from host and port
|
/// Helper method that populates span properties from host and port
|
||||||
/// to https://github.com/census-instrumentation/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
/// to https://github.com/open-telemetry/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="span">Span to fill out.</param>
|
/// <param name="span">Span to fill out.</param>
|
||||||
/// <param name="hostName">Hostr name.</param>
|
/// <param name="hostName">Hostr name.</param>
|
||||||
|
|
@ -88,7 +88,7 @@ namespace OpenTelemetry.Trace
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Helper method that populates span properties from route
|
/// Helper method that populates span properties from route
|
||||||
/// to https://github.com/census-instrumentation/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
/// to https://github.com/open-telemetry/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="span">Span to fill out.</param>
|
/// <param name="span">Span to fill out.</param>
|
||||||
/// <param name="route">Route used to resolve url to controller.</param>
|
/// <param name="route">Route used to resolve url to controller.</param>
|
||||||
|
|
@ -105,7 +105,7 @@ namespace OpenTelemetry.Trace
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Helper method that populates span properties from host and port
|
/// Helper method that populates span properties from host and port
|
||||||
/// to https://github.com/census-instrumentation/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
/// to https://github.com/open-telemetry/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="span">Span to fill out.</param>
|
/// <param name="span">Span to fill out.</param>
|
||||||
/// <param name="rawUrl">Raw url.</param>
|
/// <param name="rawUrl">Raw url.</param>
|
||||||
|
|
@ -122,7 +122,7 @@ namespace OpenTelemetry.Trace
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Helper method that populates span properties from url path according
|
/// Helper method that populates span properties from url path according
|
||||||
/// to https://github.com/census-instrumentation/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
/// to https://github.com/open-telemetry/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="span">Span to fill out.</param>
|
/// <param name="span">Span to fill out.</param>
|
||||||
/// <param name="path">Url path.</param>
|
/// <param name="path">Url path.</param>
|
||||||
|
|
@ -135,7 +135,7 @@ namespace OpenTelemetry.Trace
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Helper method that populates span properties from size according
|
/// Helper method that populates span properties from size according
|
||||||
/// to https://github.com/census-instrumentation/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
/// to https://github.com/open-telemetry/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="span">Span to fill out.</param>
|
/// <param name="span">Span to fill out.</param>
|
||||||
/// <param name="size">Response size.</param>
|
/// <param name="size">Response size.</param>
|
||||||
|
|
@ -148,7 +148,7 @@ namespace OpenTelemetry.Trace
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Helper method that populates span properties from request size according
|
/// Helper method that populates span properties from request size according
|
||||||
/// to https://github.com/census-instrumentation/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
/// to https://github.com/open-telemetry/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="span">Span to fill out.</param>
|
/// <param name="span">Span to fill out.</param>
|
||||||
/// <param name="size">Request size.</param>
|
/// <param name="size">Request size.</param>
|
||||||
|
|
@ -161,7 +161,7 @@ namespace OpenTelemetry.Trace
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Helper method that populates span properties from http status code according
|
/// Helper method that populates span properties from http status code according
|
||||||
/// to https://github.com/census-instrumentation/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
/// to https://github.com/open-telemetry/OpenTelemetry-specs/blob/4954074adf815f437534457331178194f6847ff9/trace/HTTP.md.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="span">Span to fill out.</param>
|
/// <param name="span">Span to fill out.</param>
|
||||||
/// <param name="statusCode">Http status code.</param>
|
/// <param name="statusCode">Http status code.</param>
|
||||||
|
|
|
||||||
|
|
@ -58,7 +58,7 @@ namespace OpenTelemetry.Collector.AspNetCore.Implementation
|
||||||
request,
|
request,
|
||||||
(r, name) => r.Headers[name]);
|
(r, name) => r.Headers[name]);
|
||||||
|
|
||||||
// see the spec https://github.com/census-instrumentation/OpenTelemetry-specs/blob/master/trace/HTTP.md
|
// see the spec https://github.com/open-telemetry/OpenTelemetry-specs/blob/master/trace/HTTP.md
|
||||||
|
|
||||||
string path = (request.PathBase.HasValue || request.Path.HasValue) ? (request.PathBase + request.Path).ToString() : "/";
|
string path = (request.PathBase.HasValue || request.Path.HasValue) ? (request.PathBase + request.Path).ToString() : "/";
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,27 +0,0 @@
|
||||||
# Application Insights Exporter
|
|
||||||
|
|
||||||
## Notes on questionable decisions
|
|
||||||
|
|
||||||
1. Why `Span.Kind` has option to be `Unspecified`? Is it only needed for back
|
|
||||||
compatibility or it is valid long term?
|
|
||||||
2. Span Kind detection logic and relation to `HasRemoteParent` flag. Should
|
|
||||||
`HasRemoteParent` define span kind when `Span.Kind` was `Unspecified`?
|
|
||||||
What if `HasRemoteParent` is `true` when `Span.Kind` is `Client`?
|
|
||||||
3. Should attribute `span.kind` be respected and has priority over `SpanKind`
|
|
||||||
field?
|
|
||||||
4. When `Status` wasn't set - should it be treated as `OK` or `Unknown`?
|
|
||||||
5. ResultCode and ResponseCode calculation was implemented differently in
|
|
||||||
Local Forwarder for Request and Dependency. Is there a reason for this?
|
|
||||||
6. Why use Canonical code, not the textual representation of it?
|
|
||||||
7. When http.url is bad formed – should we store it in properties collection to
|
|
||||||
preserve an original value?
|
|
||||||
8. I don't understand why this concatenation is required for identifiers like
|
|
||||||
trace id an span id?
|
|
||||||
9. Should we recover url as https or http?
|
|
||||||
10. Will url or individual components win when looking at port, host, path? I
|
|
||||||
think individual properties conflicting with url should win.
|
|
||||||
11. Why start and end time of span are not required fields?
|
|
||||||
12. Span
|
|
||||||
[name](https://github.com/census-instrumentation/OpenTelemetry-proto/blob/ba49f56771b83cff7bea7f34d1236fc139dbc471/src/OpenTelemetry/proto/trace/v1/trace.proto#L85-L86)
|
|
||||||
is required. Does it mean that it's not empty?
|
|
||||||
13. LinkList should use `Attributes` class for consistency.
|
|
||||||
|
|
@ -76,7 +76,7 @@ namespace OpenTelemetry.Exporter.Ocagent.Implementation
|
||||||
// TODO: Is there a way to handle this better?
|
// TODO: Is there a way to handle this better?
|
||||||
// This type of error processing is very aggressive and doesn't follow the
|
// This type of error processing is very aggressive and doesn't follow the
|
||||||
// error handling practices when smart defaults should be used when possible.
|
// error handling practices when smart defaults should be used when possible.
|
||||||
// See: https://github.com/census-instrumentation/OpenTelemetry-csharp/blob/develop/docs/error-handling.md
|
// See: https://github.com/open-telemetry/OpenTelemetry-dotnet/blob/master/docs/error-handling.md
|
||||||
ExporterOcagentEventSource.Log.FailedToConvertToProtoDefinitionError(e);
|
ExporterOcagentEventSource.Log.FailedToConvertToProtoDefinitionError(e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -98,11 +98,11 @@ namespace OpenTelemetry.Exporter.Stackdriver.Implementation
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
string assemblyPackageVersion = typeof(StackdriverStatsExporter).GetTypeInfo().Assembly.GetCustomAttributes<AssemblyInformationalVersionAttribute>().First().InformationalVersion;
|
string assemblyPackageVersion = typeof(StackdriverStatsExporter).GetTypeInfo().Assembly.GetCustomAttributes<AssemblyInformationalVersionAttribute>().First().InformationalVersion;
|
||||||
USER_AGENT = $"OpenTelemetry-csharp/{assemblyPackageVersion}";
|
USER_AGENT = $"OpenTelemetry-dotnet/{assemblyPackageVersion}";
|
||||||
}
|
}
|
||||||
catch (Exception)
|
catch (Exception)
|
||||||
{
|
{
|
||||||
USER_AGENT = $"OpenTelemetry-csharp/{Constants.PACKAGE_VERSION_UNDEFINED}";
|
USER_AGENT = $"OpenTelemetry-dotnet/{Constants.PACKAGE_VERSION_UNDEFINED}";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue