Skip to content

Commit 309dded

Browse files
impl(bq_driver): Update client library version
1 parent fe83580 commit 309dded

14 files changed

Lines changed: 181 additions & 49 deletions

File tree

WORKSPACE.bazel

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,25 +27,19 @@ bazel_skylib_workspace()
2727
# Dependencies for google_cloud_cpp
2828

2929
load("@com_google_cloud_cpp//bazel:workspace0.bzl", "gl_cpp_workspace0")
30-
3130
gl_cpp_workspace0()
3231

3332
load("@com_google_cloud_cpp//bazel:workspace1.bzl", "gl_cpp_workspace1")
34-
3533
gl_cpp_workspace1()
3634

3735
load("@com_google_cloud_cpp//bazel:workspace2.bzl", "gl_cpp_workspace2")
38-
3936
gl_cpp_workspace2()
4037

4138
load("@com_google_cloud_cpp//bazel:workspace3.bzl", "gl_cpp_workspace3")
42-
4339
gl_cpp_workspace3()
4440

4541
load("@com_google_cloud_cpp//bazel:workspace4.bzl", "gl_cpp_workspace4")
46-
4742
gl_cpp_workspace4()
4843

4944
load("@com_google_cloud_cpp//bazel:workspace5.bzl", "gl_cpp_workspace5")
50-
51-
gl_cpp_workspace5()
45+
gl_cpp_workspace5()

bazel/deps.bzl

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -47,23 +47,13 @@ def cpp_bigquery_odbc_development_deps(name = None):
4747
http_archive,
4848
name = "rules_cc",
4949
urls = [
50-
"https://storage.googleapis.com/cloud-cpp-community-archive/rules_cc/rules_cc-0.0.15.tar.gz",
5150
"https://github.com/bazelbuild/rules_cc/releases/download/0.0.15/rules_cc-0.0.15.tar.gz",
5251
],
5352
sha256 = "f4aadd8387f381033a9ad0500443a52a0cea5f8ad1ede4369d3c614eb7b2682e",
5453
strip_prefix = "rules_cc-0.0.15",
5554
)
5655

5756
# Load Abseil
58-
maybe(
59-
http_archive,
60-
name = "com_google_absl",
61-
urls = [
62-
"https://github.com/abseil/abseil-cpp/archive/20240722.0.tar.gz",
63-
],
64-
sha256 = "f50e5ac311a81382da7fa75b97310e4b9006474f9560ac46f54a9967f07d4ae3",
65-
strip_prefix = "abseil-cpp-20240722.0",
66-
)
6757

6858
def cpp_bigquery_odbc_deps(name = None):
6959
"""Loads dependencies need to compile the cpp-bigquery-odbc libraries.

bazel/remove_upb_c_rules.patch

Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
diff --git google/api/expr/v1alpha1/BUILD.bazel google/api/expr/v1alpha1/BUILD.bazel
2+
index 9bed46809..197e5249c 100644
3+
--- google/api/expr/v1alpha1/BUILD.bazel
4+
+++ google/api/expr/v1alpha1/BUILD.bazel
5+
@@ -233,32 +233,32 @@ cc_proto_library(
6+
##############################################################################
7+
# upb
8+
##############################################################################
9+
-load(
10+
- "@com_google_googleapis_imports//:imports.bzl",
11+
- "upb_c_proto_library",
12+
-)
13+
-
14+
-upb_c_proto_library(
15+
- name = "checked_upb_proto",
16+
- deps = [":checked_proto"],
17+
-)
18+
-
19+
-upb_c_proto_library(
20+
- name = "eval_upb_proto",
21+
- deps = [":eval_proto"],
22+
-)
23+
-
24+
-upb_c_proto_library(
25+
- name = "explain_upb_proto",
26+
- deps = [":explain_proto"],
27+
-)
28+
-
29+
-upb_c_proto_library(
30+
- name = "syntax_upb_proto",
31+
- deps = [":syntax_proto"],
32+
-)
33+
-
34+
-upb_c_proto_library(
35+
- name = "value_upb_proto",
36+
- deps = [":value_proto"],
37+
-)
38+
+#load(
39+
+ #"@com_google_googleapis_imports//:imports.bzl",
40+
+ #"upb_c_proto_library",
41+
+#)
42+
+#
43+
+#upb_c_proto_library(
44+
+ #name = "checked_upb_proto",
45+
+ #deps = [":checked_proto"],
46+
+#)
47+
+#
48+
+#upb_c_proto_library(
49+
+ #name = "eval_upb_proto",
50+
+ #deps = [":eval_proto"],
51+
+#)
52+
+#
53+
+#upb_c_proto_library(
54+
+ #name = "explain_upb_proto",
55+
+ #deps = [":explain_proto"],
56+
+#)
57+
+#
58+
+#upb_c_proto_library(
59+
+ #name = "syntax_upb_proto",
60+
+ #deps = [":syntax_proto"],
61+
+#)
62+
+#
63+
+#upb_c_proto_library(
64+
+ #name = "value_upb_proto",
65+
+ #deps = [":value_proto"],
66+
+#)
67+
diff --git google/rpc/BUILD.bazel google/rpc/BUILD.bazel
68+
index 31fd6457d..c38f00c46 100644
69+
--- google/rpc/BUILD.bazel
70+
+++ google/rpc/BUILD.bazel
71+
@@ -11,7 +11,7 @@ load(
72+
"php_proto_library",
73+
"py_gapic_assembly_pkg",
74+
"py_proto_library",
75+
- "upb_c_proto_library",
76+
+ #"upb_c_proto_library",
77+
)
78+
load("@rules_proto//proto:defs.bzl", "proto_library")
79+
80+
@@ -104,15 +104,15 @@ cc_proto_library(
81+
deps = [":status_proto"],
82+
)
83+
84+
-upb_c_proto_library(
85+
- name = "code_upb_proto",
86+
- deps = [":code_proto"],
87+
-)
88+
+#upb_c_proto_library(
89+
+ #name = "code_upb_proto",
90+
+ #deps = [":code_proto"],
91+
+#)
92+
93+
-upb_c_proto_library(
94+
- name = "status_upb_proto",
95+
- deps = [":status_proto"],
96+
-)
97+
+#upb_c_proto_library(
98+
+ #name = "status_upb_proto",
99+
+ #deps = [":status_proto"],
100+
+#)
101+
102+
py_proto_library(
103+
name = "code_py_proto",
104+
diff --git repository_rules.bzl repository_rules.bzl
105+
index 2f87ad682..2ab3bd054 100644
106+
--- repository_rules.bzl
107+
+++ repository_rules.bzl
108+
@@ -224,11 +224,11 @@ def switched_rules_by_language(
109+
#
110+
# upb
111+
#
112+
- rules["upb_c_proto_library"] = _switch(
113+
- upb,
114+
- "@com_google_protobuf//bazel:upb_c_proto_library.bzl",
115+
- "upb_c_proto_library",
116+
- )
117+
+ #rules["upb_c_proto_library"] = _switch(
118+
+ # upb,
119+
+ # "@com_google_protobuf//bazel:upb_c_proto_library.bzl",
120+
+ # "upb_c_proto_library",
121+
+ #)
122+
123+
#
124+
# PHP

ci/cloudbuild/dockerfiles/ubuntu-22.04-full.Dockerfile

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -87,13 +87,13 @@ RUN pip3 install --require-hashes --no-deps -r /var/tmp/ci/requirements.txt
8787
# image smaller (and with fewer layers)
8888

8989
WORKDIR /var/tmp/build/abseil-cpp
90-
RUN curl -fsSL https://github.com/abseil/abseil-cpp/archive/20240116.3.tar.gz | \
90+
RUN curl -fsSL https://github.com/abseil/abseil-cpp/archive/20250512.0.tar.gz | \
9191
tar -xzf - --strip-components=1 && \
9292
cmake \
9393
-DCMAKE_BUILD_TYPE="Release" \
9494
-DABSL_BUILD_TESTING=OFF \
9595
-DABSL_PROPAGATE_CXX_STD=ON \
96-
-DCMAKE_CXX_STANDARD=17 \
96+
-DCMAKE_CXX_STANDARD=17 \
9797
-DBUILD_SHARED_LIBS=yes \
9898
-DCMAKE_POSITION_INDEPENDENT_CODE=ON \
9999
-S . -B cmake-out -GNinja && \
@@ -156,7 +156,7 @@ RUN curl -fsSL https://github.com/nlohmann/json/archive/v3.11.2.tar.gz | \
156156
cd /var/tmp && rm -fr build
157157

158158
WORKDIR /var/tmp/build/protobuf
159-
RUN curl -fsSL https://github.com/protocolbuffers/protobuf/archive/v29.3.tar.gz | \
159+
RUN curl -fsSL https://github.com/protocolbuffers/protobuf/archive/v31.1.tar.gz | \
160160
tar -xzf - --strip-components=1 && \
161161
cmake \
162162
-DCMAKE_BUILD_TYPE=Release \
@@ -196,7 +196,7 @@ RUN curl -fsSL https://github.com/google/re2/archive/2024-07-02.tar.gz | \
196196
cd /var/tmp && rm -fr build
197197

198198
WORKDIR /var/tmp/build/grpc
199-
RUN curl -fsSL https://github.com/grpc/grpc/archive/v1.66.0.tar.gz | \
199+
RUN curl -fsSL https://github.com/grpc/grpc/archive/v1.71.2.tar.gz | \
200200
tar -xzf - --strip-components=1 && \
201201
cmake \
202202
-DCMAKE_BUILD_TYPE=Release \
@@ -216,6 +216,25 @@ RUN curl -fsSL https://github.com/grpc/grpc/archive/v1.66.0.tar.gz | \
216216
ldconfig && \
217217
cd /var/tmp && rm -fr build
218218

219+
RUN curl -fsSL https://github.com/open-telemetry/opentelemetry-cpp/archive/refs/tags/v1.24.0.tar.gz | \
220+
tar -xzf - --strip-components=1 && \
221+
cmake \
222+
-DCMAKE_CXX_STANDARD=17 \
223+
-DCMAKE_BUILD_TYPE=Release \
224+
-DCMAKE_POSITION_INDEPENDENT_CODE=TRUE \
225+
-DBUILD_SHARED_LIBS=ON \
226+
-DWITH_EXAMPLES=OFF \
227+
-DWITH_STL=CXX17 \
228+
-DBUILD_TESTING=OFF \
229+
-DOPENTELEMETRY_INSTALL=ON \
230+
-DOPENTELEMETRY_ABI_VERSION_NO=2 \
231+
-DWITH_TEST=OFF \
232+
-GNinja \
233+
-S . -B cmake-out && \
234+
cmake --build cmake-out --target install && \
235+
ldconfig && \
236+
cd /var/tmp && rm -fr build
237+
219238
# Install ctcache to speed up our clang-tidy build
220239
WORKDIR /var/tmp/build
221240
RUN curl -fsSL https://github.com/matus-chochlik/ctcache/archive/0ad2e227e8a981a9c1a6060ee6c8ec144bb976c6.tar.gz | \
@@ -239,7 +258,7 @@ RUN curl -fsSL https://github.com/googleapis/google-cloud-cpp/archive/refs/tags/
239258
-DCMAKE_INSTALL_PREFIX=/usr/local \
240259
-DGOOGLE_CLOUD_CPP_ENABLE_CTYPE_CORD_WORKAROUND=ON \
241260
-DBUILD_TESTING=OFF \
242-
-DCMAKE_POSITION_INDEPENDENT_CODE=ON \
261+
-DCMAKE_POSITION_INDEPENDENT_CODE=ON \
243262
-DGOOGLE_CLOUD_CPP_ENABLE_EXAMPLES=OFF \
244263
-DGOOGLE_CLOUD_CPP_ENABLE=experimental-bigquery_rest,oauth2,bigquery,resourcemanager,serviceusage \
245264
-S . -B cmake-out -GNinja && \

ci/cloudbuild/dockerfiles/ubuntu-22.04-install.Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,3 +173,4 @@ RUN echo 'Verifying glibc version...'
173173
RUN dpkg -l libc6
174174
RUN if [ $(ldd --version | grep GLIBC | awk '{print $5}') -lt 2.17 ] ; \
175175
then echo 'glibc version is < 2.17: exiting...' ; exit 1 ; fi
176+

ci/cloudbuild/dockerfiles/ubuntu-msan.Dockerfile

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,13 +98,14 @@ RUN cmake --install build
9898
# use `absl::any`, `absl::string_view`, and `absl::variant`. See
9999
# [abseil/abseil-cpp#696] for more information.
100100
WORKDIR /var/tmp/build/abseil-cpp
101-
RUN curl -fsSL https://github.com/abseil/abseil-cpp/archive/20230802.0.tar.gz | \
101+
RUN curl -fsSL https://github.com/abseil/abseil-cpp/archive/20250512.0.tar.gz | \
102102
tar -xzf - --strip-components=1 && \
103103
cmake \
104104
-DCMAKE_BUILD_TYPE="Release" \
105105
-DABSL_BUILD_TESTING=OFF \
106106
-DABSL_PROPAGATE_CXX_STD=ON \
107107
-DBUILD_SHARED_LIBS=yes \
108+
-Dprotobuf_ABSL_PROVIDER=module \
108109
-S . -B cmake-out -GNinja && \
109110
cmake --build cmake-out --target install && \
110111
ldconfig && \
@@ -167,7 +168,7 @@ RUN curl -fsSL https://github.com/nlohmann/json/archive/v3.11.2.tar.gz | \
167168
# We need to install a version of Protobuf that is recent enough to support the
168169
# Google Cloud Platform proto files:
169170
WORKDIR /var/tmp/build/protobuf
170-
RUN curl -fsSL https://github.com/protocolbuffers/protobuf/archive/v23.2.tar.gz | \
171+
RUN curl -fsSL https://github.com/protocolbuffers/protobuf/archive/v25.3.tar.gz | \
171172
tar -xzf - --strip-components=1 && \
172173
cmake \
173174
-DCMAKE_BUILD_TYPE=Release \
@@ -189,7 +190,7 @@ RUN curl -fsSL https://github.com/mozilla/sccache/releases/download/v0.5.4/sccac
189190
chmod +x /usr/local/bin/sccache
190191

191192
WORKDIR /var/tmp/build/grpc
192-
RUN curl -fsSL https://github.com/grpc/grpc/archive/v1.55.0.tar.gz | \
193+
RUN curl -fsSL https://github.com/grpc/grpc/archive/v1.63.2.tar.gz | \
193194
tar -xzf - --strip-components=1 && \
194195
cmake \
195196
-DCMAKE_BUILD_TYPE=Release \

google/cloud/odbc/BUILD.bazel

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,10 @@ cc_library(
5353
"//google/cloud/odbc/bq_client_interface:odbc_bq_client_interface",
5454
"//google/cloud/odbc/internal:odbc_internal",
5555
"@com_google_absl//absl/base:core_headers",
56-
"@com_google_absl//absl/log",
56+
"@com_google_absl//absl/log:log",
5757
"@com_google_absl//absl/log:initialize",
5858
"@com_google_absl//absl/log:log_sink",
59+
"@com_google_absl//absl/strings:str_format",
5960
"@com_google_absl//absl/strings",
6061
"@com_google_absl//absl/time",
6162
"@com_google_absl//absl/time/internal/cctz:time_zone",
@@ -81,6 +82,7 @@ cc_test(
8182
"//google/cloud/odbc/testing:google_cloud_odbc_testing_bq_driver_utils",
8283
"//google/cloud/odbc/testing:google_cloud_odbc_testing_utils",
8384
"@com_google_googletest//:gtest_main",
85+
"@com_google_absl//absl/strings:str_format",
8486
],
8587
)
8688

@@ -116,5 +118,6 @@ cc_test(
116118
"//google/cloud/odbc/testing:google_cloud_odbc_testing_bq_driver_utils",
117119
"//google/cloud/odbc/testing:google_cloud_odbc_testing_utils",
118120
"@com_google_googletest//:gtest_main",
121+
"@com_google_absl//absl/log:log",
119122
],
120123
)

google/cloud/odbc/CMakeLists.txt

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -60,23 +60,23 @@ endif ()
6060

6161
find_package(absl CONFIG REQUIRED)
6262

63-
if (ODBC_UNIT_TESTING)
64-
FetchContent_Declare(
65-
fuzztest
66-
URL "https://github.com/google/fuzztest/archive/refs/tags/2024-10-28.tar.gz"
67-
)
68-
set(FUZZTEST_USE_EXTERNAL_ABSL
69-
ON
70-
CACHE BOOL "" FORCE)
71-
set(FUZZTEST_USE_EXTERNAL_RE2
72-
ON
73-
CACHE BOOL "" FORCE)
74-
set(FUZZTEST_USE_EXTERNAL_GTEST
75-
ON
76-
CACHE BOOL "" FORCE)
77-
78-
FetchContent_MakeAvailable(fuzztest)
79-
endif ()
63+
# if (ODBC_UNIT_TESTING)
64+
# FetchContent_Declare(
65+
# fuzztest
66+
# URL "https://github.com/google/fuzztest/archive/refs/tags/2024-10-28.tar.gz"
67+
# )
68+
# set(FUZZTEST_USE_EXTERNAL_ABSL
69+
# ON
70+
# CACHE BOOL "" FORCE)
71+
# set(FUZZTEST_USE_EXTERNAL_RE2
72+
# ON
73+
# CACHE BOOL "" FORCE)
74+
# set(FUZZTEST_USE_EXTERNAL_GTEST
75+
# ON
76+
# CACHE BOOL "" FORCE)
77+
78+
# FetchContent_MakeAvailable(fuzztest)
79+
# endif ()
8080

8181
# Arrow is not supported on 32-bit systems
8282
if (CMAKE_SIZEOF_VOID_P EQUAL 8 AND NOT NO_ARROW)

google/cloud/odbc/bq_client_interface/projects.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
#include "google/cloud/odbc/bq_client_interface/datasets.h"
1717
#include "google/cloud/odbc/internal/sql_state_constants.h"
1818
#include "google/cloud/odbc/internal/status_record_or.h"
19-
#include <google/cloud/resourcemanager/v3/projects.pb.h>
19+
#include "google/cloud/resourcemanager/v3/projects.pb.h"
2020
#include <absl/log/log.h>
2121

2222
namespace google::cloud::odbc_bigquery_client_interface {

google/cloud/odbc/bq_client_interface/projects_test.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
#include "google/cloud/resourcemanager/v3/mocks/mock_projects_connection.h"
2121
#include "google/cloud/resourcemanager/v3/projects_client.h"
2222
#include "google/cloud/serviceusage/v1/mocks/mock_service_usage_connection.h"
23-
#include <google/cloud/resourcemanager/v3/projects.pb.h>
23+
#include "google/cloud/resourcemanager/v3/projects.pb.h"
2424
#include <gmock/gmock.h>
2525

2626
namespace google::cloud::odbc_bigquery_client_interface {

0 commit comments

Comments
 (0)