Skip to content

Commit

Permalink
Merge remote-tracking branch 'opentelemetry/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
owent committed Oct 1, 2023
2 parents bb62f0a + bd11434 commit 9826f67
Show file tree
Hide file tree
Showing 16 changed files with 381 additions and 185 deletions.
111 changes: 24 additions & 87 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,8 @@ jobs:
run: |
./ci/do_ci.sh cmake.test
#
# This build uses the latest libraries compatible
# with C++11
#
cmake_gcc_maintainer_cpp11_async_test:
name: CMake gcc 12 (maintainer mode, C++11, async)
cmake_gcc_maintainer_sync_test:
name: CMake gcc 12 (maintainer mode, sync)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -43,18 +39,17 @@ jobs:
env:
CC: /usr/bin/gcc-12
CXX: /usr/bin/g++-12
GOOGLETEST_VERSION: 1.12.1
PROTOBUF_VERSION: 21.12
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/install_protobuf.sh
- name: run cmake gcc (maintainer mode, C++11, async)
- name: run cmake gcc (maintainer mode, sync)
env:
CC: /usr/bin/gcc-12
CXX: /usr/bin/g++-12
run: |
./ci/do_ci.sh cmake.maintainer.cpp11.async.test
./ci/do_ci.sh cmake.maintainer.sync.test
- name: generate test cert
env:
CFSSL_VERSION: 1.6.3
Expand All @@ -65,8 +60,8 @@ jobs:
run: |
(cd ./functional/otlp; ./run_test.sh)
cmake_gcc_maintainer_sync_test:
name: CMake gcc 12 (maintainer mode, sync)
cmake_gcc_maintainer_async_test:
name: CMake gcc 12 (maintainer mode, async)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -81,12 +76,12 @@ jobs:
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/install_protobuf.sh
- name: run cmake gcc (maintainer mode, sync)
- name: run cmake gcc (maintainer mode, async)
env:
CC: /usr/bin/gcc-12
CXX: /usr/bin/g++-12
run: |
./ci/do_ci.sh cmake.maintainer.sync.test
./ci/do_ci.sh cmake.maintainer.async.test
- name: generate test cert
env:
CFSSL_VERSION: 1.6.3
Expand All @@ -97,28 +92,28 @@ jobs:
run: |
(cd ./functional/otlp; ./run_test.sh)
cmake_gcc_maintainer_async_test:
name: CMake gcc 12 (maintainer mode, async)
cmake_clang_maintainer_sync_test:
name: CMake clang 14 (maintainer mode, sync)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: setup
env:
CC: /usr/bin/gcc-12
CXX: /usr/bin/g++-12
CC: /usr/bin/clang-14
CXX: /usr/bin/clang++-14
PROTOBUF_VERSION: 21.12
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/install_protobuf.sh
- name: run cmake gcc (maintainer mode, async)
- name: run cmake clang (maintainer mode, sync)
env:
CC: /usr/bin/gcc-12
CXX: /usr/bin/g++-12
CC: /usr/bin/clang-14
CXX: /usr/bin/clang++-14
run: |
./ci/do_ci.sh cmake.maintainer.async.test
./ci/do_ci.sh cmake.maintainer.sync.test
- name: generate test cert
env:
CFSSL_VERSION: 1.6.3
Expand All @@ -129,8 +124,8 @@ jobs:
run: |
(cd ./functional/otlp; ./run_test.sh)
cmake_clang_maintainer_sync_test:
name: CMake clang 14 (maintainer mode, sync)
cmake_clang_maintainer_async_test:
name: CMake clang 14 (maintainer mode, async)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -145,12 +140,12 @@ jobs:
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/install_protobuf.sh
- name: run cmake clang (maintainer mode, sync)
- name: run cmake clang (maintainer mode, async)
env:
CC: /usr/bin/clang-14
CXX: /usr/bin/clang++-14
run: |
./ci/do_ci.sh cmake.maintainer.sync.test
./ci/do_ci.sh cmake.maintainer.async.test
- name: generate test cert
env:
CFSSL_VERSION: 1.6.3
Expand All @@ -161,8 +156,8 @@ jobs:
run: |
(cd ./functional/otlp; ./run_test.sh)
cmake_clang_maintainer_async_test:
name: CMake clang 14 (maintainer mode, async)
cmake_clang_maintainer_abiv2_test:
name: CMake clang 14 (maintainer mode, abiv2)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -177,12 +172,12 @@ jobs:
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/install_protobuf.sh
- name: run cmake clang (maintainer mode, async)
- name: run cmake clang (maintainer mode, abiv2)
env:
CC: /usr/bin/clang-14
CXX: /usr/bin/clang++-14
run: |
./ci/do_ci.sh cmake.maintainer.async.test
./ci/do_ci.sh cmake.maintainer.abiv2.test
- name: generate test cert
env:
CFSSL_VERSION: 1.6.3
Expand Down Expand Up @@ -258,64 +253,6 @@ jobs:
- name: run cmake tests (enable opentracing-shim)
run: ./ci/do_ci.sh cmake.opentracing_shim.test

cmake_gcc_48_test:
name: CMake gcc 4.8 (without otlp exporter)
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: Add Ubuntu Xenial package sources
run: |
sudo apt-add-repository 'deb http://archive.ubuntu.com/ubuntu/ xenial main'
sudo apt-add-repository 'deb http://archive.ubuntu.com/ubuntu/ xenial universe'
- name: setup
run: |
sudo ./ci/setup_ci_environment.sh
sudo ./ci/install_gcc48.sh
- name: setup cmake
env:
CC: /usr/bin/gcc-4.8
CXX: /usr/bin/g++-4.8
GOOGLETEST_VERSION: 1.10.0
run: |
sudo -E ./ci/setup_cmake.sh
- name: run tests
env:
CC: /usr/bin/gcc-4.8
CXX: /usr/bin/g++-4.8
CXX_STANDARD: '11'
run: ./ci/do_ci.sh cmake.legacy.test

cmake_gcc_48_otlp_exporter_test:
name: CMake gcc 4.8 (with otlp exporter)
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: Add Ubuntu Xenial package sources
run: |
sudo apt-add-repository 'deb http://archive.ubuntu.com/ubuntu/ xenial main'
sudo apt-add-repository 'deb http://archive.ubuntu.com/ubuntu/ xenial universe'
- name: setup
run: |
sudo ./ci/setup_ci_environment.sh
sudo ./ci/install_gcc48.sh
- name: setup cmake and grpc
env:
CC: /usr/bin/gcc-4.8
CXX: /usr/bin/g++-4.8
GOOGLETEST_VERSION: 1.10.0
run: |
sudo -E ./ci/setup_cmake.sh
sudo -E ./ci/setup_grpc.sh -v 4.8
- name: run tests
env:
CC: /usr/bin/gcc-4.8
CXX: /usr/bin/g++-4.8
run: ./ci/do_ci.sh cmake.legacy.exporter.otprotocol.test

cmake_test_cxx14_gcc:
name: CMake C++14 test(GCC)
runs-on: ubuntu-20.04
Expand Down
22 changes: 20 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,23 @@ Increment the:
* [EXPORTER] Remove explicit timestamps from metric points exported by Prometheus
[#2324](https://github.com/open-telemetry/opentelemetry-cpp/pull/2324)
* [EXPORTER] Handle attribute key collisions caused by sanitation
[#2324](https://github.com/open-telemetry/opentelemetry-cpp/pull/2326)
[#2326](https://github.com/open-telemetry/opentelemetry-cpp/pull/2326)
* [EXPORTER] Replace colons with underscores when converting to Prometheus label
[#2324](https://github.com/open-telemetry/opentelemetry-cpp/pull/2330)
[#2330](https://github.com/open-telemetry/opentelemetry-cpp/pull/2330)
* [API] Add InstrumentationScope attributes in MeterProvider::GetMeter()
[#2224](https://github.com/open-telemetry/opentelemetry-cpp/pull/2224)
* [REMOVAL] Drop C++11 support
[#2342](https://github.com/open-telemetry/opentelemetry-cpp/pull/2342)

Important changes:

* [API] Add InstrumentationScope attributes in MeterProvider::GetMeter()
[#2224](https://github.com/open-telemetry/opentelemetry-cpp/pull/2224)
* MeterProvider::GetMeter() now accepts InstrumentationScope attributes.
* Because this is an `ABI` breaking change, the fix is only available
with the `CMake` option `WITH_ABI_VERSION_2=ON`.
* When building with `CMake` option `WITH_ABI_VERSION_1=ON` (by default)
the `ABI` is unchanged, and the fix is not available.

Breaking changes:

Expand All @@ -49,6 +63,10 @@ Breaking changes:
* Applications that set neither CMAKE_CXX_STANDARD nor -stdc++
options may need to provide a C++ standard in their makefiles.

* [REMOVAL] Drop C++11 support
[#2342](https://github.com/open-telemetry/opentelemetry-cpp/pull/2342)
* Building with C++11 is no longer supported.

## [1.11.0] 2023-08-21

* [BUILD] Fix more cases for symbol name for 32-bit win32 DLL build
Expand Down
61 changes: 1 addition & 60 deletions DEPRECATED.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,66 +30,7 @@ N/A

## [Compilers]

### Drop C++11 support

#### Announcement (C++11)

* Date: 2022-12-01
* Issue: [DEPRECATION] Drop C++11 support
[#1830](https://github.com/open-telemetry/opentelemetry-cpp/pull/1830)
* This announcement has been pinned,
visible in the issues pages since December 2022.

#### Motivation (C++11)

This repository, opentelemetry-cpp, supports a "bring your own dependency" model.

In this model,
the build scripts can be configured to:

* pick a given version for a third party library,
* build opentelemetry-cpp with the library given.

The makefiles do not mandate to use a particular version,
hence the "bring your own" denomination.

To have an up to date build, projects are encouraged to use up to date
versions of third party libraries, to benefit from bug fixes.

Now, many libraries deliver new versions that require C++14, bug fixes
releases for C++11 are no longer available.

In particular, the following components:

* GRPC C++
* abseil
* googletest

now require C++14, per
[google support policies](https://github.com/google/oss-policies-info/blob/main/foundational-cxx-support-matrix.md)

As a result, to stay up to date, opentelemetry-cpp needs to upgrade its
minimum build requirements to use C++14 instead of C++11.

#### Scope (C++11)

Continuous Integration (CI) builds will use C++14 instead of C++11.

The CI build for gcc 4.8 is now deprecated, to be decommissioned when C++11
support is dropped.

#### Mitigation (C++11)

Building the code with recent third party libraries will require C++14
instead of C++11.

#### Planned end of life (C++11)

Support for C++11 in opentelemetry-cpp will end on September 2023.

After this date, opentelemetry-cpp may still build properly in C++11 mode,
assuming a suitable, old, version for each dependency is used,
but the C++11 build will no longer be tested for each new release.
N/A

## [Third party dependencies]

Expand Down
4 changes: 2 additions & 2 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ You can link OpenTelemetry C++ SDK with libraries provided in

- A supported platform (e.g. Windows, macOS or Linux). Refer to [Platforms
Supported](./README.md#supported-development-platforms) for more information.
- A compatible C++ compiler supporting at least C++11. Major compilers are
- A compatible C++ compiler supporting at least C++14. Major compilers are
supported. Refer to [Supported Compilers](./README.md#supported-c-versions)
for more information.
- [Git](https://git-scm.com/) for fetching opentelemetry-cpp source code from
Expand Down Expand Up @@ -158,7 +158,7 @@ path.

- A supported platform (e.g. Windows, macOS or Linux). Refer to [Platforms
Supported](./README.md#supported-development-platforms) for more information.
- A compatible C++ compiler supporting at least C++11. Major compilers are
- A compatible C++ compiler supporting at least C++14. Major compilers are
supported. Refer to [Supported Compilers](./README.md#supported-c-versions) for
more information.
- [Git](https://git-scm.com/) for fetching opentelemetry-cpp source code from
Expand Down
19 changes: 6 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,8 @@ repo.
Code shipped from this repository generally supports the following versions of
C++ standards:

* ISO/IEC 14882:2011 (C++11, C++0x)
* ISO/IEC 14882:2014 (C++14, C++1y)
* ISO/IEC 14882:2017 (C++17, C++1z)
* ISO/IEC 14882:2014 (C++14)
* ISO/IEC 14882:2017 (C++17)
* ISO/IEC 14882:2020 (C++20)

Any exceptions to this are noted in the individual `README.md` files.
Expand All @@ -39,19 +38,13 @@ of the current project.

| Platform | Build type |
|---------------------------------------------------------------------|---------------|
| ubuntu-22.04 (GCC - 10, 12) | CMake, Bazel |
| ubuntu-20.04 (GCC 4.8 with -std=c++11 flag) | CMake [1] |
| ubuntu-20.04 (GCC 9.4.0) | CMake, Bazel |
| ubuntu-20.04 (Default GCC Compiler - 9.4.0 with -std=c++20 flags) | CMake, Bazel |
| macOS 12.0 (Xcode 14.2) | Bazel |
| ubuntu-22.04 (GCC 10, GCC 12, Clang 14) | CMake, Bazel |
| ubuntu-20.04 (GCC 9.4.0 - default compiler) | CMake, Bazel |
| ubuntu-20.04 (GCC 9.4.0 with -std=c++14/17/20 flags) | CMake, Bazel |
| macOS 12.7 (Xcode 14.2) | Bazel |
| Windows Server 2019 (Visual Studio Enterprise 2019) | CMake, Bazel |
| Windows Server 2022 (Visual Studio Enterprise 2022) | CMake |

[1]: Bazel build is disabled for GCC 4.8, as gRPC library 1.38 and above
(required by OTLP exporter) don't build with this compiler. See gRPC [official
support](https://grpc.io/docs/#official-support) document. CMake build doesn't
build OTLP exporter with GCC 4.8.

In general, the code shipped from this repository should build on all platforms
having C++ compiler with [supported C++ standards](#supported-c-versions).

Expand Down
Loading

0 comments on commit 9826f67

Please sign in to comment.