google-cloud-bigquery-data_exchange 0.7.1 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9eaaad183f062a3142c1ccb93adc059b3332415ff5e79d150a1ad1b8bb492908
4
- data.tar.gz: 98cf9240eb56354b1264d2212c964bd0302cf11cb2daf630590da7287f6b488f
3
+ metadata.gz: 846978c557a70172bd267f275c8624c6b03103241adf052395500c12c05a7e5e
4
+ data.tar.gz: 6a1a0b3fe80f6792ea2195c73e22c32f9557ef0ebe448fab748191e7fe164eed
5
5
  SHA512:
6
- metadata.gz: aa8d6cc33880e9d2b35976bcb342d28404a281fc1ae2a23caf98043ee01d78b912fad6783f2d9ce216586bd0b9931d94ba6f8fea89851d412b6739ff98e77b57
7
- data.tar.gz: dc6aa70532d2ae9935906449d915162758f5ea33f92c0fb5cceaf06f9cfc41cb2b4b0f939a5dbb3dd55c016cec279259dc2efdf3b11cc480d5e207de8988c913
6
+ metadata.gz: 86b07f5ae13f3dcfac3b2b6cf54d1e9276a07106191bfd10dac0047457f061e1ad44c3c880f269c60bf705877cec2aacdbadfb16efa73cdb0ce063873dc3865a
7
+ data.tar.gz: 2ed024fb5e7a0225d63fafa984da98165274042d7c2500efdd60b4917bdb44638544c29b0702b172a54690b5aef6e5452a78a5637c171618ffa1660925e076c5
data/README.md CHANGED
@@ -1,8 +1,7 @@
1
1
  # Ruby Client for the Analytics Hub API
2
2
 
3
- API Client library for the Analytics Hub API
3
+ Exchange data and analytics assets securely and efficiently.
4
4
 
5
- Analytics Hub is a data exchange that allows you to efficiently and securely exchange data assets across organizations to address challenges of data reliability and cost. Curate a library of internal and external assets, including unique datasets like Google Trends, backed by the power of BigQuery.
6
5
 
7
6
  Actual client classes for the various versions of this API are defined in
8
7
  _versioned_ client gems, with names of the form `google-cloud-bigquery-data_exchange-v*`.
@@ -18,9 +17,6 @@ themselves can be found in the client library documentation for the versioned
18
17
  client gems:
19
18
  [google-cloud-bigquery-data_exchange-v1beta1](https://cloud.google.com/ruby/docs/reference/google-cloud-bigquery-data_exchange-v1beta1/latest).
20
19
 
21
- See also the [Product Documentation](https://cloud.google.com/analytics-hub/)
22
- for more usage information.
23
-
24
20
  ## Quick Start
25
21
 
26
22
  ```
@@ -76,12 +72,10 @@ working, try updating the versioned clients in your bundle or installed gems:
76
72
 
77
73
  This library is supported on Ruby 3.2+.
78
74
 
79
- Google provides official support for Ruby versions that are actively supported
80
- by Ruby Core—that is, Ruby versions that are either in normal maintenance or
81
- in security maintenance, and not end of life. Older versions of Ruby _may_
82
- still work, but are unsupported and not recommended. See
83
- https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby
84
- support schedule.
75
+ Google provides official support for Ruby versions as described in the
76
+ [Supported Ruby versions](https://docs.cloud.google.com/ruby/getting-started/supported-ruby-versions)
77
+ policy. Older versions of Ruby _may_ still work, but are unsupported and not
78
+ recommended.
85
79
 
86
80
  ## Which client should I use?
87
81
 
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module Bigquery
23
23
  module DataExchange
24
- VERSION = "0.7.1"
24
+ VERSION = "0.8.0"
25
25
  end
26
26
  end
27
27
  end
@@ -56,9 +56,11 @@ module Google
56
56
  # `version` parameter. If the AnalyticsHubService service is
57
57
  # supported by that API version, and the corresponding gem is available, the
58
58
  # appropriate versioned client will be returned.
59
+ # You can also specify a different transport by passing `:rest` or `:grpc` in
60
+ # the `transport` parameter.
59
61
  #
60
62
  # Raises an exception if the currently installed versioned client gem for the
61
- # given API version does not support the AnalyticsHubService service.
63
+ # given API version does not support the given transport of the AnalyticsHubService service.
62
64
  # You can determine whether the method will succeed by calling
63
65
  # {Google::Cloud::Bigquery::DataExchange.analytics_hub_service_available?}.
64
66
  #
@@ -73,9 +75,10 @@ module Google
73
75
  #
74
76
  # @param version [::String, ::Symbol] The API version to connect to. Optional.
75
77
  # Defaults to `:v1beta1`.
78
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
76
79
  # @return [::Object] A client object for the specified version.
77
80
  #
78
- def self.analytics_hub_service version: :v1beta1, &block
81
+ def self.analytics_hub_service version: :v1beta1, transport: :grpc, &block
79
82
  require "google/cloud/bigquery/data_exchange/#{version.to_s.downcase}"
80
83
 
81
84
  package_name = Google::Cloud::Bigquery::DataExchange
@@ -83,6 +86,7 @@ module Google
83
86
  .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
84
87
  .first
85
88
  service_module = Google::Cloud::Bigquery::DataExchange.const_get(package_name).const_get(:AnalyticsHubService)
89
+ service_module = service_module.const_get(:Rest) if transport == :rest
86
90
  service_module.const_get(:Client).new(&block)
87
91
  end
88
92
 
@@ -95,9 +99,10 @@ module Google
95
99
  #
96
100
  # @param version [::String, ::Symbol] The API version to connect to. Optional.
97
101
  # Defaults to `:v1beta1`.
102
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
98
103
  # @return [boolean] Whether the service is available.
99
104
  #
100
- def self.analytics_hub_service_available? version: :v1beta1
105
+ def self.analytics_hub_service_available? version: :v1beta1, transport: :grpc
101
106
  require "google/cloud/bigquery/data_exchange/#{version.to_s.downcase}"
102
107
  package_name = Google::Cloud::Bigquery::DataExchange
103
108
  .constants
@@ -107,6 +112,10 @@ module Google
107
112
  service_module = Google::Cloud::Bigquery::DataExchange.const_get package_name
108
113
  return false unless service_module.const_defined? :AnalyticsHubService
109
114
  service_module = service_module.const_get :AnalyticsHubService
115
+ if transport == :rest
116
+ return false unless service_module.const_defined? :Rest
117
+ service_module = service_module.const_get :Rest
118
+ end
110
119
  service_module.const_defined? :Client
111
120
  rescue ::LoadError
112
121
  false
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-bigquery-data_exchange
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.1
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
@@ -43,10 +43,7 @@ dependencies:
43
43
  - - "~>"
44
44
  - !ruby/object:Gem::Version
45
45
  version: '1.6'
46
- description: Analytics Hub is a data exchange that allows you to efficiently and securely
47
- exchange data assets across organizations to address challenges of data reliability
48
- and cost. Curate a library of internal and external assets, including unique datasets
49
- like Google Trends, backed by the power of BigQuery.
46
+ description: Exchange data and analytics assets securely and efficiently.
50
47
  email: googleapis-packages@google.com
51
48
  executables: []
52
49
  extensions: []
@@ -79,5 +76,5 @@ required_rubygems_version: !ruby/object:Gem::Requirement
79
76
  requirements: []
80
77
  rubygems_version: 3.6.9
81
78
  specification_version: 4
82
- summary: API Client library for the Analytics Hub API
79
+ summary: Exchange data and analytics assets securely and efficiently.
83
80
  test_files: []