From 895c86910f10b2ead7523022cc3b0ba525b65403 Mon Sep 17 00:00:00 2001 From: Xavier Lamorlette Date: Wed, 18 Feb 2026 16:23:11 +0100 Subject: [PATCH 1/7] Little fixes and improvements in general documentation --- .gitignore | 21 ++++++++++----------- README.md | 24 +++++++++--------------- 2 files changed, 19 insertions(+), 26 deletions(-) diff --git a/.gitignore b/.gitignore index 60c94744..cb7439c6 100644 --- a/.gitignore +++ b/.gitignore @@ -1,14 +1,13 @@ -/bazel-* -/.build/ -/build/ -/build-*/ -/.coverage/ +.build/ +.cache/ +.coverage/ +.cursor/ +.DS_Store +.install/ +.vscode +bazel-* +build-*/ build/ - dist/ -out/ MODULE.bazel.lock -.vscode -.cache/ -.cursor/ -.DS_Store \ No newline at end of file +out/ diff --git a/README.md b/README.md index 310a1199..a18c62d8 100644 --- a/README.md +++ b/README.md @@ -53,12 +53,12 @@ The library has been tested and is compatible on the following CPU architecture, ### Requirements `dd-trace-cpp` requires a [supported](#platform-support) C++17 compiler. -A recent version of CMake is required (`3.24`), which might not be in your +A recent version of CMake is required (`3.28`), which might not be in your system's package manager. [bin/install-cmake](bin/install-cmake) is an installer -for a recent CMake. +for a recent CMake, on Linux. ### Building -Build this library from source using [CMake][1]. +Build this library from source using [CMake](https://cmake.org). ```shell git clone 'https://github.com/datadog/dd-trace-cpp' @@ -67,7 +67,7 @@ cmake -B build . cmake --build build -j ``` -By default CMake will generate both static and shared libraries. To build either on of them use +By default CMake will generate both static and shared libraries. To build only one of them use either `BUILD_SHARED_LIBS` or `BUILD_STATIC_LIBS`. Example: ```shell @@ -76,14 +76,11 @@ cmake -B build -DBUILD_SHARED_LIBS=1 . ### Installation Installation places a shared library and public headers into the appropriate system directories -(`/usr/local/[...]`), or to a specified installation prefix. +(`/usr/local/[...]`), or to a specified installation prefix. Example: ```shell -cmake --install - -# Here is how to install dd-trace-cpp into `.install/` within the source -# repository. -# cmake --install build --prefix=.install +# Install dd-trace-cpp into `.install/` within the source repository. +cmake --install build --prefix=.install ``` ### Optional: Linking to the shared library @@ -111,18 +108,15 @@ Pass `-DDD_TRACE_BUILD_TESTING=1` to `cmake` to include the unit tests in the bu The resulting unit test executable is `test/tests` within the build directory. ```shell -cmake -Bbuild -DDD_TRACE_BUILD_TESTING=1 .. +cmake -Bbuild -DDD_TRACE_BUILD_TESTING=1 . cmake --build build -j ./build/test/tests ``` Alternatively, [bin/test](bin/test) is provided for convenience. -Code coverage reports are available [here][2]. +Code coverage reports are available on [CodeCov](https://app.codecov.io/gh/DataDog/dd-trace-cpp). Contributing ------------ See the [contributing guidelines](CONTRIBUTING.md) and the [maintainer docs](doc/maintainers.md) for information on the overall structure of the repository. - -[1]: https://cmake.org/ -[2]: https://datadog.github.io/dd-trace-cpp-coverage From bc4435030301ca762afd59b655461ec192640b2b Mon Sep 17 00:00:00 2001 From: Xavier Lamorlette Date: Fri, 20 Feb 2026 17:05:15 +0100 Subject: [PATCH 2/7] In format script, check that Docker is running --- bin/format | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bin/format b/bin/format index 6a5d66ac..87008fff 100755 --- a/bin/format +++ b/bin/format @@ -33,6 +33,11 @@ if ! >/dev/null command -v docker; then exit 1 fi +if ! docker info >/dev/null 2>&1; then + >&2 echo "Docker is not running. Please start Docker." + exit 1 +fi + # If they haven't downloaded the clang docker image before, then prompt the # user before telling docker to download it (it's large). image=silkeh/clang:$version From 5a52bccf8f03c1c2a2bb69f05861d07cfa1a50f0 Mon Sep 17 00:00:00 2001 From: Xavier Lamorlette Date: Fri, 20 Feb 2026 17:16:33 +0100 Subject: [PATCH 3/7] silkeh/clang:14 Docker image doesn't exist for arm64, it only exists for amd64 --- bin/format | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/format b/bin/format index 87008fff..68927341 100755 --- a/bin/format +++ b/bin/format @@ -69,6 +69,7 @@ docker_clang_format() { process_arg "$arg" done | xargs -0 \ docker run \ + --platform linux/amd64 \ --interactive \ --rm \ --volume /etc/passwd:/etc/passwd:ro \ From 351d058ecb856184d31fb802fe96be8c2cb7f806 Mon Sep 17 00:00:00 2001 From: Xavier Lamorlette Date: Fri, 13 Mar 2026 17:57:29 +0100 Subject: [PATCH 4/7] Documentation: cleaned deprecated references to CircleCI --- Dockerfile | 4 +--- bin/README.md | 16 ++++++---------- bin/check | 2 +- 3 files changed, 8 insertions(+), 14 deletions(-) diff --git a/Dockerfile b/Dockerfile index 81dad396..ef3c9a23 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,4 @@ -# This is the image used to build and test the library in CircleCI. -# See .circleci/ for more information. +# This is the image used to build and test the library in CI. from ubuntu:22.04 @@ -37,4 +36,3 @@ copy bin/install-lcov /tmp/install-lcov run chmod +x /tmp/install-lcov && /tmp/install-lcov && rm /tmp/install-lcov run curl -fLSs https://raw.githubusercontent.com/CircleCI-Public/circleci-cli/main/install.sh | bash - diff --git a/bin/README.md b/bin/README.md index d4bc645a..5a5126ec 100644 --- a/bin/README.md +++ b/bin/README.md @@ -2,20 +2,21 @@ Scripts ======= This directory contains scripts that are useful during development. -- [bazel-build](bazel-build) builds the library using [Bazel][1] via [bazelisk][2]. +- [bazel-build](bazel-build) builds the library using + [Bazel](https://bazel.build) via [bazelisk](https://github.com/bazelbuild/bazelisk). - [benchmark](benchmark) builds the library and its [benchmark](../benchmark), and runs the benchmark. - [check](check) performs some of the checks that [continuous - integration](../.circleci) performs. It's convenient to run this script before - pushing changes. + integration](../github/workflows) performs. It's convenient to run this script + before pushing changes. - [check-format](check-format) verifies that the source code is formatted as [format](format) prefers. - [check-version](check-version) accepts a version string as a command line argument (e.g. "v1.2.3") and checks whether the version within the source code matches. This is a good check to perform before publishing a source release. -- [cmake-build](cmake-build) builds the library using [CMake][3]. +- [cmake-build](cmake-build) builds the library using [CMake](https://cmake.org). - [format](format) formats all of the C++ source code using - [clang-format-14][4]. + [clang-format-14]( https://releases.llvm.org/14.0.0/tools/clang/docs/ClangFormat.html). - [hasher-example](hasher-example) builds the library, including the [command line example](../examples/hasher) program, and then runs the example. - [http-server-example](http-server-example) runs the docker compose based [HTTP @@ -33,8 +34,3 @@ This directory contains scripts that are useful during development. `CXX` environment variables based on its first argument, which is either "gnu" (to use the gcc/g++ toolchain) or "llvm" (to use the clang/clang++ toolchain). For example: `with-toolchain llvm cmake -DDD_TRACE_BUILD_TESTING=1 ..`. - -[1]: https://bazel.build/ -[2]: https://github.com/bazelbuild/bazelisk -[3]: https://cmake.org/ -[4]: https://releases.llvm.org/14.0.0/tools/clang/docs/ClangFormat.html diff --git a/bin/check b/bin/check index 5c60c924..dbf8e7e0 100755 --- a/bin/check +++ b/bin/check @@ -1,6 +1,6 @@ #!/bin/sh -# Run some of the checks that are performed by CircleCI. +# Run some of the checks that are performed by the CI. # This is convenient to run before committing. set -e From 482c52d38f8a1a2be6eb7fab3ebe86da33943d0d Mon Sep 17 00:00:00 2001 From: Xavier Lamorlette Date: Fri, 13 Mar 2026 18:10:23 +0100 Subject: [PATCH 5/7] Tiny documentation clean up --- README.md | 10 ++++++---- doc/maintainers.md | 22 ---------------------- 2 files changed, 6 insertions(+), 26 deletions(-) diff --git a/README.md b/README.md index a18c62d8..b674acf9 100644 --- a/README.md +++ b/README.md @@ -76,7 +76,7 @@ cmake -B build -DBUILD_SHARED_LIBS=1 . ### Installation Installation places a shared library and public headers into the appropriate system directories -(`/usr/local/[...]`), or to a specified installation prefix. Example: +(`/usr/local/[…]`), or to a specified installation prefix. Example: ```shell # Install dd-trace-cpp into `.install/` within the source repository. @@ -108,15 +108,17 @@ Pass `-DDD_TRACE_BUILD_TESTING=1` to `cmake` to include the unit tests in the bu The resulting unit test executable is `test/tests` within the build directory. ```shell -cmake -Bbuild -DDD_TRACE_BUILD_TESTING=1 . +cmake -B build -DDD_TRACE_BUILD_TESTING=1 . cmake --build build -j ./build/test/tests ``` Alternatively, [bin/test](bin/test) is provided for convenience. -Code coverage reports are available on [CodeCov](https://app.codecov.io/gh/DataDog/dd-trace-cpp). +Code coverage reports, run on pull requests, are available +[in Datadog](https://app.datadoghq.com/ci/code-coverage/github.com%2Fdatadog%2Fdd-trace-cpp/pull-requests). Contributing ------------ -See the [contributing guidelines](CONTRIBUTING.md) and the [maintainer docs](doc/maintainers.md) for information on the overall structure of the repository. +See the [contributing guidelines](CONTRIBUTING.md) and the [maintainer docs](doc/maintainers.md) +for information on the overall structure of the repository. diff --git a/doc/maintainers.md b/doc/maintainers.md index 40273768..76cf4a6b 100644 --- a/doc/maintainers.md +++ b/doc/maintainers.md @@ -630,28 +630,6 @@ approaches: - Add a `Logger::log_debug` function that optionally prints fine-grained tracing information to the log, in violation of constraint (1). -Operations ----------- -TODO - -### Testing -TODO - -### Code Coverage -TODO - -### Benchmarks -TODO - -### Continuous Integration -TODO - -### Releases -TODO - -### Support -TODO - [1]: https://github.com/DataDog/dd-opentracing-cpp [2]: https://github.com/open-telemetry/opentelemetry-cpp [3]: ../include/datadog/span.h From a02c20f98ba4e064ca3f9a7dcfffbddc6c173cbc Mon Sep 17 00:00:00 2001 From: Xavier Lamorlette Date: Fri, 13 Mar 2026 18:37:40 +0100 Subject: [PATCH 6/7] Add reference to baggage example --- examples/README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/examples/README.md b/examples/README.md index a6287f5e..d1884716 100644 --- a/examples/README.md +++ b/examples/README.md @@ -3,6 +3,8 @@ Example Usage This directory contains two example projects that illustrate how dd-trace-cpp can be used to add Datadog tracing to a C++ application. +- [baggage](baggage) demonstrates how to parse and validate baggage header + strings. - [hasher](hasher) is a command-line tool that creates a complete trace involving only one service. - [http-server](http-server) is an ensemble of services, including two C++ From 45cb80bba88cda12fc72544e7090ab41f69fb91e Mon Sep 17 00:00:00 2001 From: Xavier Lamorlette Date: Fri, 13 Mar 2026 19:14:45 +0100 Subject: [PATCH 7/7] Add cpp-reviewers as code owners --- .github/CODEOWNERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index e7fadda2..05a58738 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -2,4 +2,4 @@ # https://help.github.com/en/articles/about-code-owners # Default owners, overridden by file/directory specific owners below -* @DataDog/dd-trace-cpp +* @DataDog/dd-trace-cpp @DataDog/cpp-reviewers