google-cloud-gke_connect-gateway 2.0.0 → 2.1.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 +4 -4
- data/README.md +6 -1
- data/lib/google/cloud/gke_connect/gateway/version.rb +1 -1
- data/lib/google/cloud/gke_connect/gateway.rb +33 -0
- metadata +4 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 42720d23559ea509477c71e52721045aed1eee0390268c278a0626ac4ebe394b
|
4
|
+
data.tar.gz: '095829014be3c9effd0a79a3c5e5fdfaeb2b04086745502310708ac0077e7d6e'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8a9ccb409c29bc5c9314ec8095dfff7c572f549bbb38da3290db0fbd1e27c1f5cc902fa2ebd76afa1eb1fabb87a09e2ae747cd77c2cea9d49ae76e3fe2ea6e95
|
7
|
+
data.tar.gz: 4cd4605acc92a180324bb7f8ee51fe1455c728ae876a5086729f323de5df2da5c6d0fe5b83f891fae4538df9d15f2e2d06be9cf6e50834145594816a2308a515
|
data/README.md
CHANGED
@@ -59,9 +59,14 @@ service such as [Google Cloud Run](https://cloud.google.com/run), this generally
|
|
59
59
|
results in logs appearing alongside your application logs in the
|
60
60
|
[Google Cloud Logging](https://cloud.google.com/logging/) service.
|
61
61
|
|
62
|
+
Debug logging also requires that the versioned clients for this service be
|
63
|
+
sufficiently recent, released after about Dec 10, 2024. If logging is not
|
64
|
+
working, try updating the versioned clients in your bundle or installed gems:
|
65
|
+
[google-cloud-gke_connect-gateway-v1](https://cloud.google.com/ruby/docs/reference/google-cloud-gke_connect-gateway-v1/latest).
|
66
|
+
|
62
67
|
## Supported Ruby Versions
|
63
68
|
|
64
|
-
This library is supported on Ruby
|
69
|
+
This library is supported on Ruby 3.0+.
|
65
70
|
|
66
71
|
Google provides official support for Ruby versions that are actively supported
|
67
72
|
by Ruby Core—that is, Ruby versions that are either in normal maintenance or
|
@@ -56,6 +56,11 @@ module Google
|
|
56
56
|
# supported by that API version, and the corresponding gem is available, the
|
57
57
|
# appropriate versioned client will be returned.
|
58
58
|
#
|
59
|
+
# Raises an exception if the currently installed versioned client gem for the
|
60
|
+
# given API version does not support the GatewayControl service.
|
61
|
+
# You can determine whether the method will succeed by calling
|
62
|
+
# {Google::Cloud::GkeConnect::Gateway.gateway_control_available?}.
|
63
|
+
#
|
59
64
|
# ## About GatewayControl
|
60
65
|
#
|
61
66
|
# GatewayControl is the control plane API for Connect Gateway.
|
@@ -75,6 +80,34 @@ module Google
|
|
75
80
|
service_module.const_get(:Rest).const_get(:Client).new(&block)
|
76
81
|
end
|
77
82
|
|
83
|
+
##
|
84
|
+
# Determines whether the GatewayControl service is supported by the current client.
|
85
|
+
# If true, you can retrieve a client object by calling {Google::Cloud::GkeConnect::Gateway.gateway_control}.
|
86
|
+
# If false, that method will raise an exception. This could happen if the given
|
87
|
+
# API version does not exist or does not support the GatewayControl service,
|
88
|
+
# or if the versioned client gem needs an update to support the GatewayControl service.
|
89
|
+
#
|
90
|
+
# @param version [::String, ::Symbol] The API version to connect to. Optional.
|
91
|
+
# Defaults to `:v1`.
|
92
|
+
# @return [boolean] Whether the service is available.
|
93
|
+
#
|
94
|
+
def self.gateway_control_available? version: :v1
|
95
|
+
require "google/cloud/gke_connect/gateway/#{version.to_s.downcase}"
|
96
|
+
package_name = Google::Cloud::GkeConnect::Gateway
|
97
|
+
.constants
|
98
|
+
.select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
|
99
|
+
.first
|
100
|
+
return false unless package_name
|
101
|
+
service_module = Google::Cloud::GkeConnect::Gateway.const_get package_name
|
102
|
+
return false unless service_module.const_defined? :GatewayControl
|
103
|
+
service_module = service_module.const_get :GatewayControl
|
104
|
+
return false unless service_module.const_defined? :Rest
|
105
|
+
service_module = service_module.const_get :Rest
|
106
|
+
service_module.const_defined? :Client
|
107
|
+
rescue ::LoadError
|
108
|
+
false
|
109
|
+
end
|
110
|
+
|
78
111
|
##
|
79
112
|
# Configure the google-cloud-gke_connect-gateway library.
|
80
113
|
#
|
metadata
CHANGED
@@ -1,14 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-gke_connect-gateway
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Google LLC
|
8
|
-
autorequire:
|
9
8
|
bindir: bin
|
10
9
|
cert_chain: []
|
11
|
-
date:
|
10
|
+
date: 2025-01-29 00:00:00.000000000 Z
|
12
11
|
dependencies:
|
13
12
|
- !ruby/object:Gem::Dependency
|
14
13
|
name: google-cloud-core
|
@@ -65,7 +64,6 @@ homepage: https://github.com/googleapis/google-cloud-ruby
|
|
65
64
|
licenses:
|
66
65
|
- Apache-2.0
|
67
66
|
metadata: {}
|
68
|
-
post_install_message:
|
69
67
|
rdoc_options: []
|
70
68
|
require_paths:
|
71
69
|
- lib
|
@@ -73,15 +71,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
73
71
|
requirements:
|
74
72
|
- - ">="
|
75
73
|
- !ruby/object:Gem::Version
|
76
|
-
version: '
|
74
|
+
version: '3.0'
|
77
75
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
78
76
|
requirements:
|
79
77
|
- - ">="
|
80
78
|
- !ruby/object:Gem::Version
|
81
79
|
version: '0'
|
82
80
|
requirements: []
|
83
|
-
rubygems_version: 3.
|
84
|
-
signing_key:
|
81
|
+
rubygems_version: 3.6.2
|
85
82
|
specification_version: 4
|
86
83
|
summary: API Client library for the Connect Gateway API
|
87
84
|
test_files: []
|