BUILD.bazel 9.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365
  1. # This file was automatically generated by BuildFileGenerator
  2. # This is an API workspace, having public visibility by default makes perfect sense.
  3. package(default_visibility = ["//visibility:public"])
  4. ##############################################################################
  5. # Common
  6. ##############################################################################
  7. load("@rules_proto//proto:defs.bzl", "proto_library")
  8. load("@com_google_googleapis_imports//:imports.bzl", "proto_library_with_info")
  9. proto_library(
  10. name = "bigquery_proto",
  11. srcs = [
  12. "encryption_config.proto",
  13. "model.proto",
  14. "model_reference.proto",
  15. "standard_sql.proto",
  16. "table_reference.proto",
  17. ],
  18. deps = [
  19. "//google/api:annotations_proto",
  20. "//google/api:client_proto",
  21. "//google/api:field_behavior_proto",
  22. "@com_google_protobuf//:empty_proto",
  23. "@com_google_protobuf//:timestamp_proto",
  24. "@com_google_protobuf//:wrappers_proto",
  25. ],
  26. )
  27. proto_library_with_info(
  28. name = "bigquery_proto_with_info",
  29. deps = [
  30. ":bigquery_proto",
  31. "//google/cloud:common_resources_proto",
  32. ],
  33. )
  34. ##############################################################################
  35. # Java
  36. ##############################################################################
  37. load(
  38. "@com_google_googleapis_imports//:imports.bzl",
  39. "java_gapic_assembly_gradle_pkg",
  40. "java_gapic_library",
  41. "java_gapic_test",
  42. "java_grpc_library",
  43. "java_proto_library",
  44. )
  45. java_proto_library(
  46. name = "bigquery_java_proto",
  47. deps = [":bigquery_proto"],
  48. )
  49. java_grpc_library(
  50. name = "bigquery_java_grpc",
  51. srcs = [":bigquery_proto"],
  52. deps = [":bigquery_java_proto"],
  53. )
  54. java_gapic_library(
  55. name = "bigquery_java_gapic",
  56. srcs = [":bigquery_proto_with_info"],
  57. grpc_service_config = "bigquery_grpc_service_config.json",
  58. rest_numeric_enums = False,
  59. test_deps = [
  60. ":bigquery_java_grpc",
  61. ],
  62. transport = "grpc+rest",
  63. deps = [
  64. ":bigquery_java_proto",
  65. ],
  66. )
  67. java_gapic_test(
  68. name = "bigquery_java_gapic_test_suite",
  69. test_classes = [
  70. "com.google.cloud.bigquery.v2.ModelServiceClientHttpJsonTest",
  71. "com.google.cloud.bigquery.v2.ModelServiceClientTest",
  72. ],
  73. runtime_deps = [":bigquery_java_gapic_test"],
  74. )
  75. # Open Source Packages
  76. java_gapic_assembly_gradle_pkg(
  77. name = "google-cloud-bigquery-v2-java",
  78. include_samples = True,
  79. transport = "grpc+rest",
  80. deps = [
  81. ":bigquery_java_gapic",
  82. ":bigquery_java_grpc",
  83. ":bigquery_java_proto",
  84. ":bigquery_proto",
  85. ],
  86. )
  87. ##############################################################################
  88. # Go
  89. ##############################################################################
  90. load(
  91. "@com_google_googleapis_imports//:imports.bzl",
  92. "go_gapic_assembly_pkg",
  93. "go_gapic_library",
  94. "go_proto_library",
  95. "go_test",
  96. )
  97. go_proto_library(
  98. name = "bigquery_go_proto",
  99. compilers = ["@io_bazel_rules_go//proto:go_grpc"],
  100. importpath = "google.golang.org/genproto/googleapis/cloud/bigquery/v2",
  101. protos = [":bigquery_proto"],
  102. deps = [
  103. "//google/api:annotations_go_proto",
  104. ],
  105. )
  106. go_gapic_library(
  107. name = "bigquery_go_gapic",
  108. srcs = [":bigquery_proto_with_info"],
  109. grpc_service_config = "bigquery_grpc_service_config.json",
  110. importpath = "cloud.google.com/go/bigquery/apiv2;bigquery",
  111. rest_numeric_enums = False,
  112. service_yaml = "bigquery_v2.yaml",
  113. transport = "grpc+rest",
  114. deps = [
  115. ":bigquery_go_proto",
  116. ],
  117. )
  118. go_test(
  119. name = "bigquery_go_gapic_test",
  120. srcs = [":bigquery_go_gapic_srcjar_test"],
  121. embed = [":bigquery_go_gapic"],
  122. importpath = "cloud.google.com/go/bigquery/apiv2",
  123. )
  124. # Open Source Packages
  125. go_gapic_assembly_pkg(
  126. name = "gapi-cloud-bigquery-v2-go",
  127. deps = [
  128. ":bigquery_go_gapic",
  129. ":bigquery_go_gapic_srcjar-test.srcjar",
  130. ":bigquery_go_proto",
  131. ],
  132. )
  133. ##############################################################################
  134. # Python
  135. ##############################################################################
  136. load(
  137. "@com_google_googleapis_imports//:imports.bzl",
  138. "py_gapic_assembly_pkg",
  139. "py_gapic_library",
  140. )
  141. py_gapic_library(
  142. name = "bigquery_py_gapic",
  143. srcs = [":bigquery_proto"],
  144. grpc_service_config = "bigquery_grpc_service_config.json",
  145. opt_args = ["autogen-snippets=False"],
  146. rest_numeric_enums = False,
  147. transport = "grpc",
  148. )
  149. py_test(
  150. name = "bigquery_py_gapic_test",
  151. srcs = [
  152. "bigquery_py_gapic_pytest.py",
  153. "bigquery_py_gapic_test.py",
  154. ],
  155. legacy_create_init = False,
  156. deps = [":bigquery_py_gapic"],
  157. )
  158. py_gapic_assembly_pkg(
  159. name = "bigquery-v2-py",
  160. deps = [
  161. ":bigquery_py_gapic",
  162. ],
  163. )
  164. ##############################################################################
  165. # PHP
  166. ##############################################################################
  167. load(
  168. "@com_google_googleapis_imports//:imports.bzl",
  169. "php_gapic_assembly_pkg",
  170. "php_gapic_library",
  171. "php_grpc_library",
  172. "php_proto_library",
  173. )
  174. php_proto_library(
  175. name = "bigquery_php_proto",
  176. deps = [":bigquery_proto"],
  177. )
  178. php_grpc_library(
  179. name = "bigquery_php_grpc",
  180. srcs = [":bigquery_proto"],
  181. deps = [":bigquery_php_proto"],
  182. )
  183. # Add api.http options to all RPCs in the services to enable PHP GAPIC
  184. #php_gapic_library(
  185. # name = "bigquery_php_gapic",
  186. # src = ":bigquery_proto_with_info",
  187. # gapic_yaml = "bigquery_gapic.yaml",
  188. # package = "google.cloud.bigquery.v2",
  189. # service_yaml = "bigquery_v2.yaml",
  190. # deps = [
  191. # ":bigquery_php_grpc",
  192. # ":bigquery_php_proto",
  193. # ],
  194. #)
  195. #
  196. ## Open Source Packages
  197. #php_gapic_assembly_pkg(
  198. # name = "google-cloud-bigquery-v2-php",
  199. # deps = [
  200. # ":bigquery_php_gapic",
  201. # ":bigquery_php_grpc",
  202. # ":bigquery_php_proto",
  203. # ],
  204. #)
  205. ##############################################################################
  206. # Node.js
  207. ##############################################################################
  208. load(
  209. "@com_google_googleapis_imports//:imports.bzl",
  210. "nodejs_gapic_assembly_pkg",
  211. "nodejs_gapic_library",
  212. )
  213. nodejs_gapic_library(
  214. name = "bigquery_nodejs_gapic",
  215. src = ":bigquery_proto_with_info",
  216. extra_protoc_parameters = ["metadata"],
  217. grpc_service_config = "bigquery_grpc_service_config.json",
  218. package = "google.cloud.bigquery.v2",
  219. rest_numeric_enums = False,
  220. service_yaml = "bigquery_v2.yaml",
  221. transport = "grpc+rest",
  222. deps = [],
  223. )
  224. nodejs_gapic_assembly_pkg(
  225. name = "bigquery-v2-nodejs",
  226. deps = [
  227. ":bigquery_nodejs_gapic",
  228. ":bigquery_proto",
  229. ],
  230. )
  231. ##############################################################################
  232. # Ruby
  233. ##############################################################################
  234. load(
  235. "@com_google_googleapis_imports//:imports.bzl",
  236. "ruby_cloud_gapic_library",
  237. "ruby_gapic_assembly_pkg",
  238. "ruby_grpc_library",
  239. "ruby_proto_library",
  240. )
  241. ruby_proto_library(
  242. name = "bigquery_ruby_proto",
  243. deps = [":bigquery_proto"],
  244. )
  245. ruby_grpc_library(
  246. name = "bigquery_ruby_grpc",
  247. srcs = [":bigquery_proto"],
  248. deps = [":bigquery_ruby_proto"],
  249. )
  250. ruby_cloud_gapic_library(
  251. name = "bigquery_ruby_gapic",
  252. srcs = [":bigquery_proto_with_info"],
  253. extra_protoc_parameters = ["ruby-cloud-gem-name=google-cloud-bigquery-v2"],
  254. rest_numeric_enums = False,
  255. deps = [
  256. ":bigquery_ruby_grpc",
  257. ":bigquery_ruby_proto",
  258. ],
  259. )
  260. # Open Source Packages
  261. ruby_gapic_assembly_pkg(
  262. name = "google-cloud-bigquery-v2-ruby",
  263. deps = [
  264. ":bigquery_ruby_gapic",
  265. ":bigquery_ruby_grpc",
  266. ":bigquery_ruby_proto",
  267. ],
  268. )
  269. ##############################################################################
  270. # C#
  271. ##############################################################################
  272. load(
  273. "@com_google_googleapis_imports//:imports.bzl",
  274. "csharp_gapic_assembly_pkg",
  275. "csharp_gapic_library",
  276. "csharp_grpc_library",
  277. "csharp_proto_library",
  278. )
  279. csharp_proto_library(
  280. name = "bigquery_csharp_proto",
  281. deps = [":bigquery_proto"],
  282. )
  283. csharp_grpc_library(
  284. name = "bigquery_csharp_grpc",
  285. srcs = [":bigquery_proto"],
  286. deps = [":bigquery_csharp_proto"],
  287. )
  288. csharp_gapic_library(
  289. name = "bigquery_csharp_gapic",
  290. srcs = [":bigquery_proto_with_info"],
  291. common_resources_config = "@gax_dotnet//:Google.Api.Gax/ResourceNames/CommonResourcesConfig.json",
  292. grpc_service_config = "bigquery_grpc_service_config.json",
  293. rest_numeric_enums = False,
  294. service_yaml = "bigquery_v2.yaml",
  295. deps = [
  296. ":bigquery_csharp_grpc",
  297. ":bigquery_csharp_proto",
  298. ],
  299. )
  300. # Open Source Packages
  301. csharp_gapic_assembly_pkg(
  302. name = "google-cloud-bigquery-v2-csharp",
  303. deps = [
  304. ":bigquery_csharp_gapic",
  305. ":bigquery_csharp_grpc",
  306. ":bigquery_csharp_proto",
  307. ],
  308. )
  309. ##############################################################################
  310. # C++
  311. ##############################################################################
  312. load(
  313. "@com_google_googleapis_imports//:imports.bzl",
  314. "cc_grpc_library",
  315. "cc_proto_library",
  316. )
  317. cc_proto_library(
  318. name = "bigquery_cc_proto",
  319. deps = [":bigquery_proto"],
  320. )
  321. cc_grpc_library(
  322. name = "bigquery_cc_grpc",
  323. srcs = [":bigquery_proto"],
  324. grpc_only = True,
  325. deps = [":bigquery_cc_proto"],
  326. )