Skip to content
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
2,209 changes: 11 additions & 2,198 deletions CHANGELOG.md

Large diffs are not rendered by default.

12 changes: 2 additions & 10 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,20 +54,12 @@ if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
" We will consider patches for older versions.")
endif ()
elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS 6.0)
if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS 14.0.0)
message(
WARNING
"The `google-cloud-cpp` library is tested with Clang >= 6.0."
"The `google-cloud-cpp` library is tested with Clang >= 14.0.0."
" We will consider patches for older versions.")
endif ()
elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC")
if (CMAKE_VERSION VERSION_LESS 3.15)
message(
FATAL_ERROR
"MSVC builds require CMake >= 3.15."
" Previous versions of CMake lack a standard mechanism to"
" select the runtime C++ library.")
endif ()
endif ()

list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake)
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -577,16 +577,16 @@ run the examples included with the libraries.

### Building with Bazel

This library requires Bazel >= 6.0. From the top-level directory, run the usual
commands.
This library requires Bazel >= 7.0. We recommend using Bazel modules instead of
WORKSPACE files. From the top-level directory, run the usual commands.

```shell
bazel build //...
```

### Building with CMake

This library requires CMake >= 3.10. If you are planning to install the
This library requires CMake >= 3.22. If you are planning to install the
libraries please consult the [packaging guide](/doc/packaging.md), these
instructions will **NOT** produce artifacts that you can put in `/usr/local`, or
share with your colleagues.
Expand All @@ -607,11 +607,11 @@ The binary artifacts, such as examples, will be placed in `cmake-out/`.
- This project follows Google's
[Foundational C++ Support Policy][support-policy], which is summarized in the
[Foundational C++ Support Matrix][support-matrix].
- Language Version (>= C++14).
- Language Version (>= C++17).
- Operating Systems: Windows, macOS, and Linux.
- Build Systems: Bazel (>= 6.0), CMake (>= 3.10).
- Compilers: GCC (>= 7.5), Clang (>= 6.0), MSVC (>= 2022), Apple Clang (>=
12).
- Build Systems: Bazel (>= 7.0), CMake (>= 3.22).
- Compilers: GCC (>= 7.5), Clang (>= 14.0.0), MSVC (>= 2022), Apple Clang (>=
17).
- This project uses dependencies described in
[doc/packaging.md](https://github.com/googleapis/google-cloud-cpp/blob/main/doc/packaging.md).
- This project works with or without exceptions enabled.
Expand Down
16 changes: 3 additions & 13 deletions doc/compile-time-configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,28 +78,19 @@ We expect that application developers using Bazel will include

### The C++ Standard

The default Bazel toolchain forces C++11 on Linux and macOS. `google-cloud-cpp`
requires C++14, so you will need to update the C++ standard version. You must
either:
`google-cloud-cpp` requires C++17, so you may need to update the C++ standard
version. You want to either:

- Provide your own C++ toolchain configuration for Bazel. Consult the Bazel
documentation if you want to attempt this approach.
- Add `--cxxopt=-std=c++14` and `--host_cxxopt=-std=c++14` (or higher) in your
- Add `--cxxopt=-std=c++17` and `--host_cxxopt=-std=c++17` (or higher) in your
Bazel command-line.
- Add the same options in your Bazel `.bazelrc` file.

The `--host_cxxopt` may be unfamiliar. This is required to support Protobuf and
gRPC, which compile code generators for the "host" environment, and generate
libraries for the "target" environment.

### Enabling OpenTelemetry

[OpenTelemetry] is disabled by default. Add `--//:enable_opentelemetry` to your
Bazel command-line parameters to enable OpenTelemetry features, such as
instrumentation to collect distributed traces.

See the [OpenTelemetry quickstart] for more details.

### Workarounds

gRPC circa 1.58.1 fails to build with Bazel and Clang >= 16 (see [grpc#34482]).
Expand All @@ -110,4 +101,3 @@ Add the `--features=-layering_check` option to your Bazel command-line or add
[github discussion]: https://github.com/googleapis/google-cloud-cpp/discussions
[grpc#34482]: https://github.com/grpc/grpc/issues/34482
[opentelemetry]: https://opentelemetry.io/
[opentelemetry quickstart]: https://github.com/googleapis/google-cloud-cpp/tree/main/google/cloud/opentelemetry/quickstart
115 changes: 1 addition & 114 deletions doc/deprecated.md
Original file line number Diff line number Diff line change
@@ -1,55 +1,8 @@
# Future Breaking Changes

The next major version of `google-cloud-cpp` (the 3.x series) is expected to
The next major version of `google-cloud-cpp` (the 4.x series) is expected to
include the following **breaking changes**.

<details>
<summary>Bigtable: mark <code>bigtable::DataClient</code> as <code>final</code>
</summary>
<br>

We will mark `bigtable::DataClient` as `final` and remove the following member
functions:

- `DataClient::Channel()`
- `DataClient::reset()`
- `DataClient::BackgroundThreadsFactory()`

Application developers should not need to interact with this class directly.
Please use `google::cloud::bigtable::MakeDataClient(...)` with the options from
`google::cloud::GrpcOptionList<>` if you need to configure the gRPC channel or
background threads. More details can be found in [#8800].

</details>

<details>
<summary>Bigtable: remove <code>bigtable::RowReader</code> constructors
</summary>
<br>

We will remove `bigtable::RowReader` constructors which accept `DataClient` as
an argument.

Application developers who read rows by directly constructing a `RowReader`
object should instead construct a `Table` object and call `Table::ReadRows(...)`
on it.

For status on this, see [#8854].

</details>

<details>
<summary>BigQuery: remove <code>BigQueryReadReadRowsStreamingUpdater</code> from
<code>google::cloud::bigquery</code> namespace</summary>
<br>

We will remove `BigQueryReadReadRowsStreamingUpdater` from its declaration in
`google/cloud/bigquery/read_connection.h` and from the `google::cloud::bigquery`
namespace. The function continues to exist but in an internal file and
namespace. For status on this see [#8234].

</details>

<details>
<summary>Pubsub: remove legacy admin APIs</summary>
<br>
Expand All @@ -65,70 +18,4 @@ details.

</details>

<details>
<summary>Spanner: remove legacy admin APIs</summary>
<br>

We will remove the hand-written versions of the Spanner admin APIs. These have
been superseded by versions generated automatically from the service
definitions. The new APIs can be found in the
[`google/cloud/spanner/admin`](https://github.com/googleapis/google-cloud-cpp/tree/main/google/cloud/spanner/admin)
tree and within the `google::cloud::spanner_admin` namespace. Starting with the
v1.32.0 release, and depending on your compiler settings, using the old
classes/functions may elicit a deprecation warning. See [#7356] for more
details.

</details>

<details>
<summary>Spanner: remove <code>spanner::MakeTestRow()</code></summary>
<br>

We will remove `spanner::MakeTestRow()`, which has been replaced by
`spanner_mocks::MakeRow()`. Starting with the v1.41.0 release, and depending on
your compiler settings, using `spanner::MakeTestRow()` may elicit a deprecation
warning. See [#9086] for more details.

</details>

<details>
<summary>Storage: remove the `google::cloud::storage::oauth2` namespace</summary>
<br>

We will remove the `google::cloud::storage::oauth2` namespace, and all the
header files in `google/cloud/storage/oauth2/`. The new credential types in
`google/cloud/credentials.h` are work with gRPC-based services and support more
use-cases. To create access tokens use the supporting classes in
`google/cloud/oauth2/`.

</details>

<details>
<summary>Common Libraries: remove <code>v1</code> and <code>gcpcxxV1</code>
backward compatibility aliases</summary>
<br>

We will remove the inline namespace aliases of `v1` and `gcpcxxV1` that are
declared in `google/cloud/version.h`. These aliases exist because we changed the
format of our inline namespace name to include the major, minor, and patch
numbers for each release, and we didn't want to break users. Our Doxygen
documentation was mistakenly recommending that users include the inline
namespace names in their code, but this was also fixed to now recommend against
doing so. Users should generally omit the name of our versioned inline namespace
name because that will tightly couple their code to a specific release, and will
make upgrading to newer versions more difficult. Instead, users should simply
omit the inline namespace name, for example, instead of
~`google::cloud::v1::Status`~ use `google::cloud::Status`. Please update your
code to avoid naming the `v1` and `gcpcxxV1` inline namespace names. For more
info, see [#7463] and [#5976].

</details>

[#12987]: https://github.com/googleapis/google-cloud-cpp/issues/12987
[#5976]: https://github.com/googleapis/google-cloud-cpp/issues/5976
[#7356]: https://github.com/googleapis/google-cloud-cpp/issues/7356
[#7463]: https://github.com/googleapis/google-cloud-cpp/issues/7463
[#8234]: https://github.com/googleapis/google-cloud-cpp/issues/8234
[#8800]: https://github.com/googleapis/google-cloud-cpp/issues/8800
[#8854]: https://github.com/googleapis/google-cloud-cpp/issues/8854
[#9086]: https://github.com/googleapis/google-cloud-cpp/issues/9086
26 changes: 8 additions & 18 deletions doc/packaging.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,20 +115,13 @@ quickstart guides also cover this use-case.

| Library | Minimum version | Description |
| --------------------------------- | ----------------: | ---------------------------------------------------------- |
| [Abseil][abseil-gh] | 20200923, Patch 3 | Abseil C++ common library [^1] |
| [gRPC][grpc-gh] | 1.35.x | An RPC library and framework [^2] |
| [libcurl][libcurl-gh] | 7.47.0 | HTTP client library [^3] |
| [crc32c][crc32c-gh] | 1.0.6 | Hardware-accelerated CRC32C implementation [^4] |
| [OpenSSL][openssl-gh] | 1.0.2 | Crypto functions for [^3] |
| [nlohmann/json][nlohmann-json-gh] | 3.4.0 | JSON for Modern C++ [^3] |
| [protobuf][protobuf-gh] | 3.15.8 | Protobuf is needed for any library based on gRPC [^5] [^6] |

`google-cloud-cpp` also has an **optional** dependency on the following
libraries:

| Library | Minimum version | Description |
| --------------------------------- | --------------- | ------------------------------ |
| [OpenTelemetry][opentelemetry-gh] | 1.9.1 | An observability framework[^7] |
| [Abseil][abseil-gh] | 20250814, Patch 1 | Abseil C++ common library [^1] |
| [gRPC][grpc-gh] | 1.76.x | An RPC library and framework [^2] |
| [libcurl][libcurl-gh] | 7.74.0 | HTTP client library [^3] |
| [OpenSSL][openssl-gh] | 3.0.17 | Crypto functions for [^3] |
| [nlohmann/json][nlohmann-json-gh] | 3.12.0 | JSON for Modern C++ [^3] |
| [protobuf][protobuf-gh] | 6.33.x | Protobuf is needed for any library based on gRPC [^5] [^6] |
| [OpenTelemetry][opentelemetry-gh] | 1.23.0 | An observability framework[^7] |

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

With OpenTelemetry now being a required dependency, the referenced footnote [^7] is outdated as it still refers to it as an 'optional dependency'. Suggest removing the reference to avoid confusion.

Suggested change
| [OpenTelemetry][opentelemetry-gh] | 1.23.0 | An observability framework[^7] |
| [OpenTelemetry][opentelemetry-gh] | 1.23.0 | An observability framework |

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated footnote.


Note that these libraries may also depend on other libraries. The following
instructions include steps to install these indirect dependencies too.
Expand Down Expand Up @@ -1211,20 +1204,17 @@ cmake --build cmake-out --target install
[^3]: Only some libraries (Compute, SQL Admin, and Google Cloud Storage) require
this dependency.

[^4]: Only the Google Cloud Storage client library requires this dependency.

[^5]: The Google Cloud Storage client does not require Protobuf.

[^6]: On some platforms, some libraries may need a newer version of Protobuf to
workaround conflicts between system pre-processor macros and symbols used in
the Protobuf-generated code.

[^7]: See the [OpenTelemetry quickstart][otel-qs] for detailed instructions on how
to enable and build this optional dependency.
to build this dependency.

[abseil-gh]: https://github.com/abseil/abseil-cpp
[abseil/abseil-cpp#696]: https://github.com/abseil/abseil-cpp/issues/696
[crc32c-gh]: https://github.com/google/crc32c
[grpc-gh]: https://github.com/grpc/grpc
[homebrew formula]: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/abseil.rb
[howto-setup-dev-workstation]: /doc/contributor/howto-guide-setup-development-workstation.md
Expand Down
8 changes: 0 additions & 8 deletions google/cloud/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,6 @@ intended for general use. They are subject to change and/or removal without
notice. These include `google/cloud/internal/`, and
`google/cloud/testing_utils/`.

## Supported Platforms
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

qq: Why is this section being removed? Is 3.x compatible with all common platforms?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That same information already exists in the top level README.md. It was duplicated here and didn't seem necessary to keep both.


- Windows, macOS, Linux
- C++14 (and higher) compilers. We test with GCC >= 7.5, Clang >= 6.0, and MSVC
\>= 2022
- Environments with or without exceptions
- Bazel (>= 6.0) and CMake (>= 3.5) builds

## Documentation

- [Reference doxygen documentation][doxygen-link] for each release of this
Expand Down
6 changes: 1 addition & 5 deletions vcpkg.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
"supports": "!uwp",
"dependencies": [
"abseil",
"crc32c",
{
"name": "curl",
"features": [
Expand All @@ -32,10 +31,7 @@
"nlohmann-json",
"benchmark",
"gtest",
{
"$description": "Only used for the opentelemetry feature.",
"name": "opentelemetry-cpp"
},
"opentelemetry-cpp",
{
"$description": "Only used for the docfx feature.",
"name": "pugixml"
Expand Down