Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[REMOVAL] Remove ZPAGES #2433

Merged
merged 4 commits into from
Dec 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ Increment the:
[#2388](https://github.com/open-telemetry/opentelemetry-cpp/pull/2388)
* [SEMANTIC CONVENTION] Upgrade to semconv 1.23.1
[#2428](https://github.com/open-telemetry/opentelemetry-cpp/pull/2428)
* [REMOVAL] Remove ZPAGES
[#2433](https://github.com/open-telemetry/opentelemetry-cpp/pull/2433)

Important changes:

Expand Down Expand Up @@ -103,6 +105,11 @@ Breaking changes:
* Please check configuration variables,
to make sure `_LOGS_` variables are set as expected.

* [REMOVAL] Remove ZPAGES
[#2433](https://github.com/open-telemetry/opentelemetry-cpp/pull/2433)
* As announced in release 1.12.0,
the deprecated ZPAGES exporter is now removed.

## [1.12.0] 2023-10-16

* [BUILD] Support `pkg-config`
Expand Down
12 changes: 0 additions & 12 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -212,9 +212,6 @@ option(WITH_PROMETHEUS "Whether to include the Prometheus Client in the SDK"
option(WITH_ELASTICSEARCH
"Whether to include the Elasticsearch Client in the SDK" OFF)

option(WITH_ZPAGES
"DEPRECATED - Whether to include the Zpages Server in the SDK" OFF)

option(WITH_NO_GETENV "Whether the platform supports environment variables" OFF)

option(BUILD_TESTING "Whether to enable tests" ON)
Expand Down Expand Up @@ -290,14 +287,6 @@ option(WITH_OTLP_HTTP_SSL_TLS_PREVIEW
option(WITH_METRICS_EXEMPLAR_PREVIEW
"Whether to enable exemplar within metrics" OFF)

if(WITH_ZPAGES)
if(WITH_NO_DEPRECATED_CODE)
message(FATAL_ERROR "WITH_ZPAGES is DEPRECATED.")
else()
message(WARNING "WITH_ZPAGES is DEPRECATED.")
endif()
endif()

#
# Verify options dependencies
#
Expand Down Expand Up @@ -480,7 +469,6 @@ endif()
if(WITH_ELASTICSEARCH
OR WITH_ZIPKIN
OR WITH_OTLP_HTTP
OR WITH_ZPAGES
OR BUILD_W3CTRACECONTEXT_TEST
OR WITH_ETW)
set(USE_NLOHMANN_JSON ON)
Expand Down
84 changes: 1 addition & 83 deletions DEPRECATED.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,89 +92,7 @@ N/A

## [opentelemetry-cpp Exporter]

### ZPages exporter

#### Announcement (ZPages)

* Version: 1.11.0
* Date: 2023-09-01
* PR: [DEPRECATION] Deprecate ZPAGES
[#2291](https://github.com/open-telemetry/opentelemetry-cpp/pull/2291)

#### Motivation (ZPages)

The ZPages specification itself was introduced in 2020,
and has been experimental ever since,
not getting a lot of attention, and never reaching a stable status.

Several other opentelemetry projects have implemented support for zpages,
only to later deprecate and then remove the zpages implementation (Java,
C#), abandoning the zpages feature.

In this context, it does not make sense to continue to maintain the zpages
code in opentelemetry-cpp.

#### Scope (ZPages)

The following are deprecated and planned for removal:

* all the API headers located under
`ext/include/opentelemetry/ext/zpages/`, including:
* the C++ class `ThreadsafeSpanData`
* the C++ class `TracezDataAggregator`
* the C++ class `TracezHttpServer`
* the C++ class `TracezSpanProcessor`
* the C++ class `TracezSharedData`
* the C++ class `ZPages`
* the C++ class `zPagesHttpServer`
* all the code and doc located under `ext/src/zpages/`
* all the tests located under `ext/test/zpages/`
* the zpages exporter library(`opentelemetry_zpages`)
* the zpages build options in CMake (`WITH_ZPAGES`)

The following code is no longer considered public, will no longer be
installed, and will no longer be useable outside of
the opentelemetry-cpp implementation:

* all the API headers located under
`ext/include/opentelemetry/ext/http/server`, including:
* the C++ class `FileHttpServer`
* the C++ class `HttpRequestCallback`
* the C++ class `HttpServer`
* the C++ class `HttpRequestHandler`
* the C++ class `SocketCallback`

This implementation of an HTTP server is meant to be used for testing only,
it is not production ready.

#### Mitigation (ZPages)

Consider using a different exporter,
for example the OTLP exporter (both OTLP HTTP and OTLP GRPC are supported),
to expose trace data to a separate trace backend.

Note that this changes the access pattern:

* with zpages, data is only available locally (in process)
* with other exporters, data is available externally (not in process)

Our assessment is that the zpages implementation is no longer in use,
and can be removed.

If that assessment is incorrect (i.e., if you own a project that depends
on the zpage exporter from opentelemetry-cpp), please comment on the
removal issue
[#2292](https://github.com/open-telemetry/opentelemetry-cpp/issues/2292).

An alternative to zpage removal is to move the code to the
opentelemetry-cpp-contrib github
[repository](https://github.com/open-telemetry/opentelemetry-cpp-contrib).

Contributions to migrate the code, and maintain zpages, are welcome.

#### Planned removal (ZPages)

* Date: December, 2023
N/A

## [Documentation]

Expand Down
4 changes: 0 additions & 4 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -124,10 +124,6 @@ You can link OpenTelemetry C++ SDK with libraries provided in
-- Installing: /<install-root>/lib/cmake/opentelemetry-cpp/opentelemetry-cpp-config.cmake
-- Installing: /<install-root>/lib/cmake/opentelemetry-cpp/opentelemetry-cpp-config-version.cmake
...
-- Installing: /<install-root>/include/opentelemetry//ext/zpages/static/tracez_index.h
-- Installing: /<install-root>/include/opentelemetry//ext/zpages/static/tracez_style.h
-- Installing: /<install-root>/include/opentelemetry//ext/zpages/threadsafe_span_data.h
-- Installing: /<install-root>/lib/libopentelemetry_zpages.a
$
```

Expand Down
3 changes: 1 addition & 2 deletions ci/do_ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -459,8 +459,7 @@ elif [[ "$1" == "bazel.asan" ]]; then
elif [[ "$1" == "bazel.tsan" ]]; then
# TODO - potential race condition in Civetweb server used by prometheus-cpp during shutdown
# https://github.com/civetweb/civetweb/issues/861, so removing prometheus from the test
# zpages test failing with tsan. Ignoring the tests for now, as zpages will be removed soon.
bazel $BAZEL_STARTUP_OPTIONS test --config=tsan $BAZEL_TEST_OPTIONS_ASYNC -- //... -//exporters/prometheus/... -//ext/test/zpages/...
bazel $BAZEL_STARTUP_OPTIONS test --config=tsan $BAZEL_TEST_OPTIONS_ASYNC -- //... -//exporters/prometheus/...
exit 0
elif [[ "$1" == "bazel.valgrind" ]]; then
bazel $BAZEL_STARTUP_OPTIONS build $BAZEL_OPTIONS_ASYNC //...
Expand Down
2 changes: 0 additions & 2 deletions cmake/opentelemetry-cpp-config.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@
# opentelemetry-cpp::ostream_span_exporter - Imported target of opentelemetry-cpp::ostream_span_exporter
# opentelemetry-cpp::elasticsearch_log_record_exporter - Imported target of opentelemetry-cpp::elasticsearch_log_record_exporter
# opentelemetry-cpp::etw_exporter - Imported target of opentelemetry-cpp::etw_exporter
# opentelemetry-cpp::zpages - Imported target of opentelemetry-cpp::zpages
# opentelemetry-cpp::http_client_curl - Imported target of opentelemetry-cpp::http_client_curl
# opentelemetry-cpp::opentracing_shim - Imported target of opentelemetry-cpp::opentracing_shim
#
Expand Down Expand Up @@ -100,7 +99,6 @@ set(_OPENTELEMETRY_CPP_LIBRARIES_TEST_TARGETS
prometheus_exporter
elasticsearch_log_record_exporter
etw_exporter
zpages
http_client_curl
opentracing_shim)
foreach(_TEST_TARGET IN LISTS _OPENTELEMETRY_CPP_LIBRARIES_TEST_TARGETS)
Expand Down
3 changes: 0 additions & 3 deletions docs/dependencies.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,9 +92,6 @@ Both these dependencies are listed here:
- `libcurl` for connecting with Elasticsearch server over HTTP protocol.
- `nlohmann/json` for encoding Elastic Search messages.

- [Zpages](/ext/src/zpages):
- None

- [Opentracing](/opentracing-shim)
shim:
- [`opentracing-cpp`](https://github.com/opentracing/opentracing-cpp)
Expand Down
21 changes: 0 additions & 21 deletions examples/zpages/BUILD

This file was deleted.

60 changes: 0 additions & 60 deletions examples/zpages/zpages_example.cc

This file was deleted.

60 changes: 0 additions & 60 deletions ext/include/opentelemetry/ext/zpages/latency_boundaries.h

This file was deleted.

48 changes: 0 additions & 48 deletions ext/include/opentelemetry/ext/zpages/static/tracez_index.h

This file was deleted.

Loading