-
Notifications
You must be signed in to change notification settings - Fork 764
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[logs-branch] Merge from main into main-logs (#3809)
* [Logs] Fix buffered log scopes being reused (#3731) * Fix buffered log scopes being reused. * CHANGELOG update. * Test fixes. Co-authored-by: Cijo Thomas <[email protected]> * clarify that Prometheus HttpListner is not for production at this moment (#3737) * [HttpClient] Export spans corresponding to retries (#3732) * Minor update to OTLP readme (#3739) * Nit fixes to prometheus readme * Add minor clarification about OTLP logs * Update workflow (#3741) * Minor improvement to log message (#3742) * [SDK + Jaeger] Support loading environment variables from IConfiguration in Traces & Metrics (#3720) * Support retrieval of environment variables through IConfiguration in SDK. * Update Jaeger to load environment variables through IConfiguration. * Warning fix. * CHANGELOG patch. * Bug fixes. * Warning cleanup. * Code review. * [Zipkin] Support loading envvars from IConfiguration (#3759) * Support loading envvars from IConfiguration in Zipkin exporter. * CHANGELOG patch. * SqlClient Instrumentation to leverage native Activity Status. (#3751) * [Metrics] Update default buckets for Explicit Bucket Histogram from spec (#3722) * [Logs] Fix: Respect AttributeValueLengthLimit when building otlp LogRecord data (#3684) * Respect SdkConfiguration.AttributeValueLengthLimit so otlp data points are not rejected by monitoring tools * Respect maxAttributeCount and use OtlpKeyValueTransformer in AddStringAttribute and in AddIntAttribute * Extend CHANGELOG.md Co-authored-by: Mikel Blanchard <[email protected]> * Bump actions/setup-dotnet from 3.0.1 to 3.0.2 (#3764) Bumps [actions/setup-dotnet](https://github.com/actions/setup-dotnet) from 3.0.1 to 3.0.2. - [Release notes](https://github.com/actions/setup-dotnet/releases) - [Commits](actions/setup-dotnet@v3.0.1...v3.0.2) --- updated-dependencies: - dependency-name: actions/setup-dotnet dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * [Repo] Attempting to stabilize the API Compatibility CI job (#3766) * Attempting to stablize the API Compatibility CI. * Tweak. * More logging. * Increase build logging level for api compat ci job. * Tweak. * Tweak. * Revert extra logging in ci job. * Switched some logging back to debug. * Adding MinMax to Histograms (#2735) * Logging state during building of TracerProvider (#3746) * [HttpClient] Add unit tests for `RecordException` case (#3761) * Add a separate example project for Logs redaction (#3744) * Update CHANGELOG for 1.4.0-beta.2 release (#3772) * [SDK + Otlp] Support loading envvars from IConfiguration (#3760) * Updated Otlp Trace & Metrics exporters to load envvars from IConfiguration. * Patch CHANGELOGs. * Fix up otlp log exporter for SdkOptions changes. * Revert SdkOptions public api. * Restore tests. * Fix benchmarks. * SdkLimitOptions IConfiguration test. * OtlpExporterOptions IConfiguration test. * MetricReaderOptions IConfiguration test. * Bug fix. * Nit. * [SqlClient] Add support for Filter expression (#3743) * [SDK, Jaeger, Zipkin, & Otlp] Support loading envvars for BatchExportActivityProcessorOptions from IConfiguration (#3776) * Support loading envvars for ExportActivityProcessorOptions & BatchExportActivityProcessorOptions from IConfiguration. * Update src/OpenTelemetry/CHANGELOG.md Co-authored-by: Piotr Kiełkowicz <[email protected]> * Patch CHANGELOG. * Unit test. Co-authored-by: Cijo Thomas <[email protected]> Co-authored-by: Piotr Kiełkowicz <[email protected]> * Remove Env from CI `DOTNET_MULTILEVEL_LOOKUP = 1` (#3779) * Link to .NET docs about different ports (#3704) * Update DS to rc2 (#3781) * ConsoleLogExporter to output full exception (#3784) * [ASP.NET Core] Add back netstandard2.0 and 2.1 targets (#3755) * [HttpClient] Add back netstandard2.0 target (#3787) * Add back netstandard2.0 target * changelog * public api files * Bump System.Text.Json version due to CVE-2021-26701 (#3789) * Auto-generated Semantic Conventions (#2069) * [SDK] Support dependency injection in ResourceBuilder and load envvars from IConfiguration (#3782) * Add Vishwesh as an Approver (#3783) Co-authored-by: Cijo Thomas <[email protected]> * Move more SDK docs to docs folder (#3794) * [Prometheus AspNetCore] Support named options in pipeline extensions (#3780) * Support named options in Prometheus AspNetCore pipeline extensions. * Patch CHANGELOG. Co-authored-by: Cijo Thomas <[email protected]> * [Logs] UnitTest: LogRecord attribute limits (#3758) * Unittest for LogRecord attribute limits * Remove maxValueLength from LogRecordExtensions.AddIntAttribute. Change requested from #3684 (comment) * Pr commits addressed Co-authored-by: Mikel Blanchard <[email protected]> * Add MinMax to console and doc additions (#3795) * Mark private and internal classes as sealed (#3799) Co-authored-by: Cijo Thomas <[email protected]> * Move more docs to docs folder (#3801) * [ASP.NET Core] Update enrich callbacks to use specific type. (#3749) * [Http] Update enrich callbacks for http (#3792) * [SDK] Support dependency injection in the GetDefaultResource API (#3798) * Support dependency injection in the GetDefaultResource API. * CHANGELOG patch. * Test tweaks. Co-authored-by: Cijo Thomas <[email protected]> * Fix circular reference issue building up tracer provider. (#3803) * [SDK] Add some missing nullable annotations (#3796) * Added some missing nullable annotations in SDK. * Handle null span names in SamplingParameters. * Warning cleanup. * Warning cleanup. * Added link to issue in comment. Co-authored-by: Alan West <[email protected]> * Guard.Range now uses invariant culture for error message (#3778) Co-authored-by: Utkarsh Umesan Pillai <[email protected]> * Fix circular reference issue building up meter provider. (#3806) Co-authored-by: Utkarsh Umesan Pillai <[email protected]> * Add missing end of code block backticks (#3807) * More doc tweaks (#3805) * More doc tweaks * remove draft staatus * Update grpc client enrich callbacks (#3804) * Port refactor from main-logs branch. (#3808) Co-authored-by: Cijo Thomas <[email protected]> * Merge fixes. * Merge fixes. * Merge fix. Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: Cijo Thomas <[email protected]> Co-authored-by: Reiley Yang <[email protected]> Co-authored-by: Vishwesh Bankwar <[email protected]> Co-authored-by: Cijo Thomas <[email protected]> Co-authored-by: Yun-Ting Lin <[email protected]> Co-authored-by: Sebastian Schoder Moreno <[email protected]> Co-authored-by: Jonathan Wilhelm <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Michael Maxwell <[email protected]> Co-authored-by: ggoel <[email protected]> Co-authored-by: Utkarsh Umesan Pillai <[email protected]> Co-authored-by: Pavel Steinl <[email protected]> Co-authored-by: Piotr Kiełkowicz <[email protected]> Co-authored-by: aristotelos <[email protected]> Co-authored-by: Joao Grassi <[email protected]> Co-authored-by: Alan West <[email protected]> Co-authored-by: benhall_io <[email protected]>
- Loading branch information
1 parent
4defde9
commit aba8a69
Showing
248 changed files
with
8,101 additions
and
1,399 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,13 +11,12 @@ jobs: | |
runs-on: windows-latest | ||
env: | ||
CheckAPICompatibility: true | ||
# https://github.com/actions/setup-dotnet/issues/122 | ||
DOTNET_MULTILEVEL_LOOKUP: 1 | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 # fetching all | ||
- uses: actions/[email protected].1 | ||
- uses: actions/[email protected].2 | ||
with: | ||
dotnet-version: '7.0.x' | ||
include-prerelease: true | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,16 +18,12 @@ jobs: | |
fail-fast: false | ||
matrix: | ||
os: [windows-latest] | ||
env: | ||
OS: ${{ matrix.os }} | ||
# https://github.com/actions/setup-dotnet/issues/122 | ||
DOTNET_MULTILEVEL_LOOKUP: 1 | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 # fetching all | ||
- uses: actions/[email protected].1 | ||
- uses: actions/[email protected].2 | ||
with: | ||
dotnet-version: '7.0.x' | ||
include-prerelease: true | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,7 +21,7 @@ jobs: | |
uses: actions/checkout@v3 | ||
|
||
- name: Setup .NET Core 7.0 | ||
uses: actions/[email protected].1 | ||
uses: actions/[email protected].2 | ||
with: | ||
dotnet-version: '7.0.x' | ||
include-prerelease: true | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,11 +23,11 @@ jobs: | |
with: | ||
fetch-depth: 0 # fetching all | ||
|
||
- uses: actions/[email protected].1 | ||
- uses: actions/[email protected].2 | ||
with: | ||
dotnet-version: '6.0.x' | ||
|
||
- uses: actions/[email protected].1 | ||
- uses: actions/[email protected].2 | ||
with: | ||
dotnet-version: '7.0.x' | ||
include-prerelease: true | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,7 +23,7 @@ jobs: | |
fetch-depth: 0 # fetching all | ||
ref: ${{ github.ref || 'main' }} | ||
|
||
- uses: actions/[email protected].1 | ||
- uses: actions/[email protected].2 | ||
with: | ||
dotnet-version: '7.0.x' | ||
include-prerelease: true | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,9 +13,6 @@ on: | |
jobs: | ||
build-test: | ||
runs-on: windows-latest | ||
env: | ||
# https://github.com/actions/setup-dotnet/issues/122 | ||
DOTNET_MULTILEVEL_LOOKUP: 1 | ||
|
||
strategy: | ||
matrix: | ||
|
@@ -26,7 +23,7 @@ jobs: | |
with: | ||
fetch-depth: 0 # fetching all | ||
|
||
- uses: actions/[email protected].1 | ||
- uses: actions/[email protected].2 | ||
with: | ||
dotnet-version: '7.0.x' | ||
include-prerelease: true | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,6 +41,7 @@ | |
"tracestate", | ||
"Tracestate", | ||
"triager", | ||
"typeparam", | ||
"umesan", | ||
"unencrypted", | ||
"unvalidated", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,31 @@ | ||
param([string]$package, [string]$version) | ||
param( | ||
[string]$package, | ||
[string]$version, | ||
[string]$workDir = ".\LastMajorVersionBinaries" | ||
) | ||
|
||
$workDir = "..\LastMajorVersionBinaries" | ||
if (-Not (Test-Path $workDir)) | ||
{ | ||
Write-Host "Working directory for previous package versions not found, creating..." | ||
Write-Host "Working directory for compatibility check packages '$workDir' not found, creating..." | ||
New-Item -Path $workDir -ItemType "directory" | Out-Null | ||
} | ||
|
||
if (Test-Path -Path "$workDir\$package.$version.zip") | ||
{ | ||
Write-Debug "Previous package version already downloaded" | ||
Write-Debug "Previous package $package@$version already downloaded for compatibility check" | ||
} | ||
else | ||
{ | ||
Write-Host "Retrieving $package @$version for compatibility check" | ||
Write-Host "Retrieving package $package@$version for compatibility check" | ||
Invoke-WebRequest -Uri https://www.nuget.org/api/v2/package/$package/$version -Outfile "$workDir\$package.$version.zip" | ||
} | ||
|
||
if (Test-Path -Path "$workDir\$package\$version\lib") | ||
{ | ||
Write-Debug "Previous package version already extracted" | ||
Write-Debug "Previous package $package@$version already extracted to '$workDir\$package\$version\lib'" | ||
} | ||
else | ||
{ | ||
Write-Host "Extracting package $package@$version from '$workDir\$package.$version.zip' to '$workDir\$package\$version' for compatibility check" | ||
Expand-Archive -LiteralPath "$workDir\$package.$version.zip" -DestinationPath "$workDir\$package\$version" -Force | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
// <copyright file="Program.cs" company="OpenTelemetry Authors"> | ||
// Copyright The OpenTelemetry Authors | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
// </copyright> | ||
|
||
using Microsoft.Extensions.Logging; | ||
using OpenTelemetry.Logs; | ||
|
||
namespace Redaction; | ||
|
||
public class Program | ||
{ | ||
public static void Main() | ||
{ | ||
using var loggerFactory = LoggerFactory.Create(builder => builder | ||
.AddOpenTelemetry() | ||
.AddProcessor(new MyRedactionProcessor()) | ||
.AddConsoleExporter()); | ||
|
||
var logger = loggerFactory.CreateLogger<Program>(); | ||
|
||
// message will be redacted by MyRedactionProcessor | ||
logger.LogInformation("OpenTelemetry {sensitiveString}.", "<secret>"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Redaction | ||
|
||
This example shows how to redact sensitive information from Logs. | ||
In this example, we attach a custom `Processor` called `MyRedactionProcessor` | ||
which is responsible for replacing any instance of the word "<secret>" | ||
with the value "newRedactedValueHere". |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
<ItemGroup> | ||
<PackageReference Include="Microsoft.Extensions.Logging" Version="$(MicrosoftExtensionsLoggingPkgVer)" /> | ||
<ProjectReference Include="$(RepoRoot)\src\OpenTelemetry.Exporter.Console\OpenTelemetry.Exporter.Console.csproj" /> | ||
</ItemGroup> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.