Skip to content

Commit

Permalink
Merge branch 'main' into fix/reader_data_race
Browse files Browse the repository at this point in the history
  • Loading branch information
arekay authored Apr 4, 2024
2 parents 1c4b7f3 + 848db57 commit 950db86
Show file tree
Hide file tree
Showing 41 changed files with 4,553 additions and 81 deletions.
60 changes: 22 additions & 38 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
CC: /usr/bin/gcc-10
CXX: /usr/bin/g++-10
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: run cmake tests (without otlp-exporter)
env:
Expand All @@ -41,7 +41,7 @@ jobs:
CXX: /usr/bin/g++-13
PROTOBUF_VERSION: 21.12
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/install_protobuf.sh
- name: run cmake gcc (maintainer mode, sync)
Expand Down Expand Up @@ -73,7 +73,7 @@ jobs:
CXX: /usr/bin/g++-13
PROTOBUF_VERSION: 21.12
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/install_protobuf.sh
- name: run cmake gcc (maintainer mode, async)
Expand Down Expand Up @@ -105,7 +105,7 @@ jobs:
CXX: /usr/bin/clang++-15
PROTOBUF_VERSION: 21.12
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/install_protobuf.sh
- name: run cmake clang (maintainer mode, sync)
Expand Down Expand Up @@ -137,7 +137,7 @@ jobs:
CXX: /usr/bin/clang++-15
PROTOBUF_VERSION: 21.12
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/install_protobuf.sh
- name: run cmake clang (maintainer mode, async)
Expand Down Expand Up @@ -169,7 +169,7 @@ jobs:
CXX: /usr/bin/clang++-15
PROTOBUF_VERSION: 21.12
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/install_protobuf.sh
- name: run cmake clang (maintainer mode, abiv2)
Expand Down Expand Up @@ -197,7 +197,6 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
./ci/setup_windows_cmake.ps1
./ci/setup_windows_ci_environment.ps1
- name: run tests
run: ./ci/do_ci.ps1 cmake.maintainer.test
Expand All @@ -211,7 +210,6 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
./ci/setup_windows_cmake.ps1
./ci/setup_windows_ci_environment.ps1
- name: run tests
env:
Expand All @@ -230,7 +228,7 @@ jobs:
CC: /usr/bin/gcc-10
CXX: /usr/bin/g++-10
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: run cmake tests (without otlp-exporter)
env:
Expand All @@ -248,7 +246,7 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: run cmake tests (enable abseil-cpp)
run: |
Expand All @@ -264,7 +262,7 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: run cmake tests (enable opentracing-shim)
run: ./ci/do_ci.sh cmake.opentracing_shim.test
Expand All @@ -277,11 +275,9 @@ jobs:
with:
submodules: 'recursive'
- name: setup
env:
CMAKE_VERSION: 3.20.6
run: |
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
- name: run tests (enable stl)
env:
CXX_STANDARD: '14'
Expand All @@ -295,11 +291,9 @@ jobs:
with:
submodules: 'recursive'
- name: setup
env:
CMAKE_VERSION: 3.20.6
run: |
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
- name: run tests (enable stl)
env:
CXX_STANDARD: '17'
Expand All @@ -313,11 +307,9 @@ jobs:
with:
submodules: 'recursive'
- name: setup
env:
CMAKE_VERSION: 3.20.6
run: |
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
- name: run tests
env:
CXX_STANDARD: '20'
Expand All @@ -339,10 +331,9 @@ jobs:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
CXXFLAGS: "-stdlib=libc++"
CMAKE_VERSION: 3.20.6
run: |
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
- name: run tests
env:
CC: /usr/bin/clang
Expand All @@ -366,11 +357,9 @@ jobs:
with:
submodules: 'recursive'
- name: setup
env:
CMAKE_VERSION: 3.20.6
run: |
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
- name: run tests
env:
CXX_STANDARD: '23'
Expand All @@ -392,10 +381,9 @@ jobs:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
CXXFLAGS: "-stdlib=libc++"
CMAKE_VERSION: 3.20.6
run: |
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
- name: run tests
env:
CC: /usr/bin/clang
Expand All @@ -420,7 +408,7 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: run otlp exporter tests
run: |
Expand All @@ -440,7 +428,7 @@ jobs:
ABSEIL_CPP_VERSION: '20230125.3'
CXX_STANDARD: '14'
run: |
sudo ./ci/setup_cmake.sh
sudo ./ci/setup_googletest.sh
sudo ./ci/setup_ci_environment.sh
sudo -E ./ci/install_abseil.sh
sudo -E ./ci/install_protobuf.sh
Expand All @@ -461,7 +449,7 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: run otlp exporter tests
run: |
Expand All @@ -477,7 +465,7 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: run otlp exporter tests
run: |
Expand All @@ -493,7 +481,7 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: run cmake install (with abseil)
run: |
Expand All @@ -515,7 +503,7 @@ jobs:
CC: /usr/bin/gcc-10
CXX: /usr/bin/g++-10
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: run tests
env:
Expand Down Expand Up @@ -763,7 +751,6 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
./ci/setup_windows_cmake.ps1
./ci/setup_windows_ci_environment.ps1
./ci/install_windows_protobuf.ps1
- name: run cmake test
Expand All @@ -780,7 +767,6 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
./ci/setup_windows_cmake.ps1
./ci/setup_windows_ci_environment.ps1
./ci/install_windows_protobuf.ps1
- name: run cmake test (DLL build)
Expand All @@ -799,7 +785,6 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
./ci/setup_windows_cmake.ps1
./ci/setup_windows_ci_environment.ps1
./ci/install_windows_protobuf.ps1
- name: run cmake test
Expand Down Expand Up @@ -829,7 +814,6 @@ jobs:
submodules: 'recursive'
- name: setup
run: |
./ci/setup_windows_cmake.ps1
./ci/setup_windows_ci_environment.ps1
- name: run tests
run: ./ci/do_ci.ps1 cmake.test_example_plugin
Expand All @@ -846,7 +830,7 @@ jobs:
CC: /usr/bin/gcc-10
CXX: /usr/bin/g++-10
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: run tests and generate report
env:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
CXX: /usr/bin/g++-10
GOOGLETEST_VERSION: 1.12.1
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_googletest.sh
sudo -E ./ci/setup_ci_environment.sh
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
Expand Down
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,14 @@ Increment the:

## [Unreleased]

* [EXPORTER] Add OTLP File exporters
[#2540](https://github.com/open-telemetry/opentelemetry-cpp/pull/2540)
* [EXPORTER] Gzip compression support for OTLP/HTTP and OTLP/gRPC exporter
[#2530](https://github.com/open-telemetry/opentelemetry-cpp/pull/2530)
* [EXPORTER] Support URL-encoded values for `OTEL_EXPORTER_OTLP_HEADERS`
[#2579](https://github.com/open-telemetry/opentelemetry-cpp/pull/2579)
* [CI] Use platform CMake
[#2627](https://github.com/open-telemetry/opentelemetry-cpp/pull/2627)

Important changes:

Expand All @@ -32,6 +36,13 @@ Important changes:
dependency on zlib.
* [SDK] Change OTLP HTTP content_type default to binary
[#2558](https://github.com/open-telemetry/opentelemetry-cpp/pull/2558)
* [CI] Use platform CMake
[#2627](https://github.com/open-telemetry/opentelemetry-cpp/pull/2627)
* The `CI` in github no longer install a different version of `cmake`.
* It now always use the `cmake` provided by the platform.
* As part of this change, the script `ci/setup_cmake.sh` was renamed
to `ci/setup_googletest.sh`, for clarity, now that this script
only installs googletest.

## [1.14.2] 2024-02-27

Expand Down
8 changes: 7 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,9 @@ option(WITH_OTLP_GRPC "Whether to include the OTLP gRPC exporter in the SDK"
option(WITH_OTLP_HTTP "Whether to include the OTLP http exporter in the SDK"
OFF)

option(WITH_OTLP_FILE "Whether to include the OTLP file exporter in the SDK"
OFF)

option(
WITH_OTLP_HTTP_COMPRESSION
"Whether to include gzip compression for the OTLP http exporter in the SDK"
Expand Down Expand Up @@ -370,7 +373,9 @@ if(WITH_ABSEIL)
find_package(absl CONFIG REQUIRED)
endif()

if(WITH_OTLP_GRPC OR WITH_OTLP_HTTP)
if(WITH_OTLP_GRPC
OR WITH_OTLP_HTTP
OR WITH_OTLP_FILE)
find_package(Protobuf)
if(Protobuf_VERSION AND Protobuf_VERSION VERSION_GREATER_EQUAL "3.22.0")
if(NOT WITH_ABSEIL)
Expand Down Expand Up @@ -473,6 +478,7 @@ endif()
if(WITH_ELASTICSEARCH
OR WITH_ZIPKIN
OR WITH_OTLP_HTTP
OR WITH_OTLP_FILE
OR BUILD_W3CTRACECONTEXT_TEST
OR WITH_ETW)
set(USE_NLOHMANN_JSON ON)
Expand Down
4 changes: 2 additions & 2 deletions bazel/otel_cc_benchmark.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ def otel_cc_benchmark(name, srcs, deps, tags = [""]):
tools = [":" + name],
tags = tags + ["benchmark_result", "manual"],
testonly = True,
cmd = "$(location :" + name + (") --benchmark_format=json --benchmark_color=false --benchmark_min_time=.1 &> $@"),
cmd = "$(location :" + name + (") --benchmark_format=json --benchmark_color=false --benchmark_min_time=.1s &> $@"),
)

# This is run as part of "bazel test ..." to smoke-test benchmarks. It's
Expand All @@ -46,7 +46,7 @@ def otel_cc_benchmark(name, srcs, deps, tags = [""]):
name = name + "_smoketest",
srcs = srcs,
deps = deps + ["@com_github_google_benchmark//:benchmark"],
args = ["--benchmark_min_time=0"],
args = ["--benchmark_min_time=1x"],
tags = tags + ["benchmark"],
defines = ["BAZEL_BUILD"],
)
Loading

0 comments on commit 950db86

Please sign in to comment.