google-cloud-bigtable-admin-v2 0.3.0 → 0.5.3
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/AUTHENTICATION.md +8 -8
- data/LICENSE.md +188 -190
- data/README.md +3 -3
- data/lib/google/bigtable/admin/v2/bigtable_table_admin_services_pb.rb +1 -1
- data/lib/google/bigtable/admin/v2/instance_pb.rb +5 -0
- data/lib/google/bigtable/admin/v2/table_pb.rb +16 -0
- data/lib/google/cloud/bigtable/admin/v2/bigtable_instance_admin/client.rb +39 -73
- data/lib/google/cloud/bigtable/admin/v2/bigtable_instance_admin/operations.rb +11 -11
- data/lib/google/cloud/bigtable/admin/v2/bigtable_instance_admin/paths.rb +21 -0
- data/lib/google/cloud/bigtable/admin/v2/bigtable_table_admin/client.rb +44 -70
- data/lib/google/cloud/bigtable/admin/v2/bigtable_table_admin/operations.rb +11 -11
- data/lib/google/cloud/bigtable/admin/v2/bigtable_table_admin/paths.rb +23 -0
- data/lib/google/cloud/bigtable/admin/v2/version.rb +1 -1
- data/proto_docs/google/api/field_behavior.rb +7 -1
- data/proto_docs/google/bigtable/admin/v2/bigtable_table_admin.rb +2 -2
- data/proto_docs/google/bigtable/admin/v2/instance.rb +21 -1
- data/proto_docs/google/bigtable/admin/v2/table.rb +58 -4
- data/proto_docs/google/type/expr.rb +35 -12
- metadata +18 -12
@@ -127,7 +127,7 @@ module Google
|
|
127
127
|
# backups.
|
128
128
|
rpc :ListBackups, ::Google::Cloud::Bigtable::Admin::V2::ListBackupsRequest, ::Google::Cloud::Bigtable::Admin::V2::ListBackupsResponse
|
129
129
|
# Create a new table by restoring from a completed backup. The new table
|
130
|
-
# must be in the same
|
130
|
+
# must be in the same project as the instance containing the backup. The
|
131
131
|
# returned table [long-running operation][google.longrunning.Operation] can
|
132
132
|
# be used to track the progress of the operation, and to cancel it. The
|
133
133
|
# [metadata][google.longrunning.Operation.metadata] field type is
|
@@ -31,6 +31,10 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
31
31
|
optional :state, :enum, 3, "google.bigtable.admin.v2.Cluster.State"
|
32
32
|
optional :serve_nodes, :int32, 4
|
33
33
|
optional :default_storage_type, :enum, 5, "google.bigtable.admin.v2.StorageType"
|
34
|
+
optional :encryption_config, :message, 6, "google.bigtable.admin.v2.Cluster.EncryptionConfig"
|
35
|
+
end
|
36
|
+
add_message "google.bigtable.admin.v2.Cluster.EncryptionConfig" do
|
37
|
+
optional :kms_key_name, :string, 1
|
34
38
|
end
|
35
39
|
add_enum "google.bigtable.admin.v2.Cluster.State" do
|
36
40
|
value :STATE_NOT_KNOWN, 0
|
@@ -66,6 +70,7 @@ module Google
|
|
66
70
|
Instance::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.Instance.State").enummodule
|
67
71
|
Instance::Type = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.Instance.Type").enummodule
|
68
72
|
Cluster = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.Cluster").msgclass
|
73
|
+
Cluster::EncryptionConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.Cluster.EncryptionConfig").msgclass
|
69
74
|
Cluster::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.Cluster.State").enummodule
|
70
75
|
AppProfile = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.AppProfile").msgclass
|
71
76
|
AppProfile::MultiClusterRoutingUseAny = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny").msgclass
|
@@ -7,6 +7,7 @@ require 'google/api/field_behavior_pb'
|
|
7
7
|
require 'google/api/resource_pb'
|
8
8
|
require 'google/protobuf/duration_pb'
|
9
9
|
require 'google/protobuf/timestamp_pb'
|
10
|
+
require 'google/rpc/status_pb'
|
10
11
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
11
12
|
add_file("google/bigtable/admin/v2/table.proto", :syntax => :proto3) do
|
12
13
|
add_message "google.bigtable.admin.v2.RestoreInfo" do
|
@@ -24,6 +25,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
24
25
|
end
|
25
26
|
add_message "google.bigtable.admin.v2.Table.ClusterState" do
|
26
27
|
optional :replication_state, :enum, 1, "google.bigtable.admin.v2.Table.ClusterState.ReplicationState"
|
28
|
+
repeated :encryption_info, :message, 2, "google.bigtable.admin.v2.EncryptionInfo"
|
27
29
|
end
|
28
30
|
add_enum "google.bigtable.admin.v2.Table.ClusterState.ReplicationState" do
|
29
31
|
value :STATE_NOT_KNOWN, 0
|
@@ -42,6 +44,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
42
44
|
value :NAME_ONLY, 1
|
43
45
|
value :SCHEMA_VIEW, 2
|
44
46
|
value :REPLICATION_VIEW, 3
|
47
|
+
value :ENCRYPTION_VIEW, 5
|
45
48
|
value :FULL, 4
|
46
49
|
end
|
47
50
|
add_message "google.bigtable.admin.v2.ColumnFamily" do
|
@@ -61,6 +64,16 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
61
64
|
add_message "google.bigtable.admin.v2.GcRule.Union" do
|
62
65
|
repeated :rules, :message, 1, "google.bigtable.admin.v2.GcRule"
|
63
66
|
end
|
67
|
+
add_message "google.bigtable.admin.v2.EncryptionInfo" do
|
68
|
+
optional :encryption_type, :enum, 3, "google.bigtable.admin.v2.EncryptionInfo.EncryptionType"
|
69
|
+
optional :encryption_status, :message, 4, "google.rpc.Status"
|
70
|
+
optional :kms_key_version, :string, 2
|
71
|
+
end
|
72
|
+
add_enum "google.bigtable.admin.v2.EncryptionInfo.EncryptionType" do
|
73
|
+
value :ENCRYPTION_TYPE_UNSPECIFIED, 0
|
74
|
+
value :GOOGLE_DEFAULT_ENCRYPTION, 1
|
75
|
+
value :CUSTOMER_MANAGED_ENCRYPTION, 2
|
76
|
+
end
|
64
77
|
add_message "google.bigtable.admin.v2.Snapshot" do
|
65
78
|
optional :name, :string, 1
|
66
79
|
optional :source_table, :message, 2, "google.bigtable.admin.v2.Table"
|
@@ -83,6 +96,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
83
96
|
optional :end_time, :message, 5, "google.protobuf.Timestamp"
|
84
97
|
optional :size_bytes, :int64, 6
|
85
98
|
optional :state, :enum, 7, "google.bigtable.admin.v2.Backup.State"
|
99
|
+
optional :encryption_info, :message, 9, "google.bigtable.admin.v2.EncryptionInfo"
|
86
100
|
end
|
87
101
|
add_enum "google.bigtable.admin.v2.Backup.State" do
|
88
102
|
value :STATE_UNSPECIFIED, 0
|
@@ -117,6 +131,8 @@ module Google
|
|
117
131
|
GcRule = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.GcRule").msgclass
|
118
132
|
GcRule::Intersection = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.GcRule.Intersection").msgclass
|
119
133
|
GcRule::Union = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.GcRule.Union").msgclass
|
134
|
+
EncryptionInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.EncryptionInfo").msgclass
|
135
|
+
EncryptionInfo::EncryptionType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.EncryptionInfo.EncryptionType").enummodule
|
120
136
|
Snapshot = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.Snapshot").msgclass
|
121
137
|
Snapshot::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.Snapshot.State").enummodule
|
122
138
|
Backup = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.bigtable.admin.v2.Backup").msgclass
|
@@ -63,7 +63,7 @@ module Google
|
|
63
63
|
parent_config = while namespace.any?
|
64
64
|
parent_name = namespace.join "::"
|
65
65
|
parent_const = const_get parent_name
|
66
|
-
break parent_const.configure if parent_const
|
66
|
+
break parent_const.configure if parent_const.respond_to? :configure
|
67
67
|
namespace.pop
|
68
68
|
end
|
69
69
|
default_config = Client::Configuration.new parent_config
|
@@ -72,34 +72,22 @@ module Google
|
|
72
72
|
|
73
73
|
default_config.rpcs.get_instance.timeout = 60.0
|
74
74
|
default_config.rpcs.get_instance.retry_policy = {
|
75
|
-
initial_delay: 1.0,
|
76
|
-
max_delay: 60.0,
|
77
|
-
multiplier: 2,
|
78
|
-
retry_codes: [14, 4]
|
75
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
79
76
|
}
|
80
77
|
|
81
78
|
default_config.rpcs.list_instances.timeout = 60.0
|
82
79
|
default_config.rpcs.list_instances.retry_policy = {
|
83
|
-
initial_delay: 1.0,
|
84
|
-
max_delay: 60.0,
|
85
|
-
multiplier: 2,
|
86
|
-
retry_codes: [14, 4]
|
80
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
87
81
|
}
|
88
82
|
|
89
83
|
default_config.rpcs.update_instance.timeout = 60.0
|
90
84
|
default_config.rpcs.update_instance.retry_policy = {
|
91
|
-
initial_delay: 1.0,
|
92
|
-
max_delay: 60.0,
|
93
|
-
multiplier: 2,
|
94
|
-
retry_codes: [14, 4]
|
85
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
95
86
|
}
|
96
87
|
|
97
88
|
default_config.rpcs.partial_update_instance.timeout = 60.0
|
98
89
|
default_config.rpcs.partial_update_instance.retry_policy = {
|
99
|
-
initial_delay: 1.0,
|
100
|
-
max_delay: 60.0,
|
101
|
-
multiplier: 2,
|
102
|
-
retry_codes: [14, 4]
|
90
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
103
91
|
}
|
104
92
|
|
105
93
|
default_config.rpcs.delete_instance.timeout = 60.0
|
@@ -108,26 +96,17 @@ module Google
|
|
108
96
|
|
109
97
|
default_config.rpcs.get_cluster.timeout = 60.0
|
110
98
|
default_config.rpcs.get_cluster.retry_policy = {
|
111
|
-
initial_delay: 1.0,
|
112
|
-
max_delay: 60.0,
|
113
|
-
multiplier: 2,
|
114
|
-
retry_codes: [14, 4]
|
99
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
115
100
|
}
|
116
101
|
|
117
102
|
default_config.rpcs.list_clusters.timeout = 60.0
|
118
103
|
default_config.rpcs.list_clusters.retry_policy = {
|
119
|
-
initial_delay: 1.0,
|
120
|
-
max_delay: 60.0,
|
121
|
-
multiplier: 2,
|
122
|
-
retry_codes: [14, 4]
|
104
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
123
105
|
}
|
124
106
|
|
125
107
|
default_config.rpcs.update_cluster.timeout = 60.0
|
126
108
|
default_config.rpcs.update_cluster.retry_policy = {
|
127
|
-
initial_delay: 1.0,
|
128
|
-
max_delay: 60.0,
|
129
|
-
multiplier: 2,
|
130
|
-
retry_codes: [14, 4]
|
109
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
131
110
|
}
|
132
111
|
|
133
112
|
default_config.rpcs.delete_cluster.timeout = 60.0
|
@@ -136,46 +115,31 @@ module Google
|
|
136
115
|
|
137
116
|
default_config.rpcs.get_app_profile.timeout = 60.0
|
138
117
|
default_config.rpcs.get_app_profile.retry_policy = {
|
139
|
-
initial_delay: 1.0,
|
140
|
-
max_delay: 60.0,
|
141
|
-
multiplier: 2,
|
142
|
-
retry_codes: [14, 4]
|
118
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
143
119
|
}
|
144
120
|
|
145
121
|
default_config.rpcs.list_app_profiles.timeout = 60.0
|
146
122
|
default_config.rpcs.list_app_profiles.retry_policy = {
|
147
|
-
initial_delay: 1.0,
|
148
|
-
max_delay: 60.0,
|
149
|
-
multiplier: 2,
|
150
|
-
retry_codes: [14, 4]
|
123
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
151
124
|
}
|
152
125
|
|
153
126
|
default_config.rpcs.update_app_profile.timeout = 60.0
|
154
127
|
default_config.rpcs.update_app_profile.retry_policy = {
|
155
|
-
initial_delay: 1.0,
|
156
|
-
max_delay: 60.0,
|
157
|
-
multiplier: 2,
|
158
|
-
retry_codes: [14, 4]
|
128
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
159
129
|
}
|
160
130
|
|
161
131
|
default_config.rpcs.delete_app_profile.timeout = 60.0
|
162
132
|
|
163
133
|
default_config.rpcs.get_iam_policy.timeout = 60.0
|
164
134
|
default_config.rpcs.get_iam_policy.retry_policy = {
|
165
|
-
initial_delay: 1.0,
|
166
|
-
max_delay: 60.0,
|
167
|
-
multiplier: 2,
|
168
|
-
retry_codes: [14, 4]
|
135
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
169
136
|
}
|
170
137
|
|
171
138
|
default_config.rpcs.set_iam_policy.timeout = 60.0
|
172
139
|
|
173
140
|
default_config.rpcs.test_iam_permissions.timeout = 60.0
|
174
141
|
default_config.rpcs.test_iam_permissions.retry_policy = {
|
175
|
-
initial_delay: 1.0,
|
176
|
-
max_delay: 60.0,
|
177
|
-
multiplier: 2,
|
178
|
-
retry_codes: [14, 4]
|
142
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
179
143
|
}
|
180
144
|
|
181
145
|
default_config
|
@@ -244,9 +208,9 @@ module Google
|
|
244
208
|
enable_self_signed_jwt = @config.scope == Client.configure.scope &&
|
245
209
|
@config.endpoint == Client.configure.endpoint &&
|
246
210
|
!@config.endpoint.split(".").first.include?("-")
|
247
|
-
credentials ||= Credentials.default scope:
|
211
|
+
credentials ||= Credentials.default scope: @config.scope,
|
248
212
|
enable_self_signed_jwt: enable_self_signed_jwt
|
249
|
-
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
213
|
+
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
250
214
|
credentials = Credentials.new credentials, scope: @config.scope
|
251
215
|
end
|
252
216
|
@quota_project_id = @config.quota_project
|
@@ -944,7 +908,7 @@ module Google
|
|
944
908
|
# @param options [::Gapic::CallOptions, ::Hash]
|
945
909
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
946
910
|
#
|
947
|
-
# @overload update_cluster(location: nil, serve_nodes: nil, default_storage_type: nil)
|
911
|
+
# @overload update_cluster(location: nil, serve_nodes: nil, default_storage_type: nil, encryption_config: nil)
|
948
912
|
# Pass arguments to `update_cluster` via keyword arguments. Note that at
|
949
913
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
950
914
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
@@ -962,6 +926,8 @@ module Google
|
|
962
926
|
# (`CreationOnly`)
|
963
927
|
# The type of storage used by this cluster to serve its
|
964
928
|
# parent instance's tables, unless explicitly overridden.
|
929
|
+
# @param encryption_config [::Google::Cloud::Bigtable::Admin::V2::Cluster::EncryptionConfig, ::Hash]
|
930
|
+
# Immutable. The encryption configuration for CMEK-protected clusters.
|
965
931
|
#
|
966
932
|
# @yield [response, operation] Access the result along with the RPC operation
|
967
933
|
# @yieldparam response [::Gapic::Operation]
|
@@ -1752,7 +1718,7 @@ module Google
|
|
1752
1718
|
config_attr :scope, nil, ::String, ::Array, nil
|
1753
1719
|
config_attr :lib_name, nil, ::String, nil
|
1754
1720
|
config_attr :lib_version, nil, ::String, nil
|
1755
|
-
config_attr(:channel_args, { "grpc.service_config_disable_resolution"=>1 }, ::Hash, nil)
|
1721
|
+
config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil)
|
1756
1722
|
config_attr :interceptors, nil, ::Array, nil
|
1757
1723
|
config_attr :timeout, nil, ::Numeric, nil
|
1758
1724
|
config_attr :metadata, nil, ::Hash, nil
|
@@ -1773,7 +1739,7 @@ module Google
|
|
1773
1739
|
def rpcs
|
1774
1740
|
@rpcs ||= begin
|
1775
1741
|
parent_rpcs = nil
|
1776
|
-
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config
|
1742
|
+
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
|
1777
1743
|
Rpcs.new parent_rpcs
|
1778
1744
|
end
|
1779
1745
|
end
|
@@ -1894,43 +1860,43 @@ module Google
|
|
1894
1860
|
|
1895
1861
|
# @private
|
1896
1862
|
def initialize parent_rpcs = nil
|
1897
|
-
create_instance_config = parent_rpcs
|
1863
|
+
create_instance_config = parent_rpcs.create_instance if parent_rpcs.respond_to? :create_instance
|
1898
1864
|
@create_instance = ::Gapic::Config::Method.new create_instance_config
|
1899
|
-
get_instance_config = parent_rpcs
|
1865
|
+
get_instance_config = parent_rpcs.get_instance if parent_rpcs.respond_to? :get_instance
|
1900
1866
|
@get_instance = ::Gapic::Config::Method.new get_instance_config
|
1901
|
-
list_instances_config = parent_rpcs
|
1867
|
+
list_instances_config = parent_rpcs.list_instances if parent_rpcs.respond_to? :list_instances
|
1902
1868
|
@list_instances = ::Gapic::Config::Method.new list_instances_config
|
1903
|
-
update_instance_config = parent_rpcs
|
1869
|
+
update_instance_config = parent_rpcs.update_instance if parent_rpcs.respond_to? :update_instance
|
1904
1870
|
@update_instance = ::Gapic::Config::Method.new update_instance_config
|
1905
|
-
partial_update_instance_config = parent_rpcs
|
1871
|
+
partial_update_instance_config = parent_rpcs.partial_update_instance if parent_rpcs.respond_to? :partial_update_instance
|
1906
1872
|
@partial_update_instance = ::Gapic::Config::Method.new partial_update_instance_config
|
1907
|
-
delete_instance_config = parent_rpcs
|
1873
|
+
delete_instance_config = parent_rpcs.delete_instance if parent_rpcs.respond_to? :delete_instance
|
1908
1874
|
@delete_instance = ::Gapic::Config::Method.new delete_instance_config
|
1909
|
-
create_cluster_config = parent_rpcs
|
1875
|
+
create_cluster_config = parent_rpcs.create_cluster if parent_rpcs.respond_to? :create_cluster
|
1910
1876
|
@create_cluster = ::Gapic::Config::Method.new create_cluster_config
|
1911
|
-
get_cluster_config = parent_rpcs
|
1877
|
+
get_cluster_config = parent_rpcs.get_cluster if parent_rpcs.respond_to? :get_cluster
|
1912
1878
|
@get_cluster = ::Gapic::Config::Method.new get_cluster_config
|
1913
|
-
list_clusters_config = parent_rpcs
|
1879
|
+
list_clusters_config = parent_rpcs.list_clusters if parent_rpcs.respond_to? :list_clusters
|
1914
1880
|
@list_clusters = ::Gapic::Config::Method.new list_clusters_config
|
1915
|
-
update_cluster_config = parent_rpcs
|
1881
|
+
update_cluster_config = parent_rpcs.update_cluster if parent_rpcs.respond_to? :update_cluster
|
1916
1882
|
@update_cluster = ::Gapic::Config::Method.new update_cluster_config
|
1917
|
-
delete_cluster_config = parent_rpcs
|
1883
|
+
delete_cluster_config = parent_rpcs.delete_cluster if parent_rpcs.respond_to? :delete_cluster
|
1918
1884
|
@delete_cluster = ::Gapic::Config::Method.new delete_cluster_config
|
1919
|
-
create_app_profile_config = parent_rpcs
|
1885
|
+
create_app_profile_config = parent_rpcs.create_app_profile if parent_rpcs.respond_to? :create_app_profile
|
1920
1886
|
@create_app_profile = ::Gapic::Config::Method.new create_app_profile_config
|
1921
|
-
get_app_profile_config = parent_rpcs
|
1887
|
+
get_app_profile_config = parent_rpcs.get_app_profile if parent_rpcs.respond_to? :get_app_profile
|
1922
1888
|
@get_app_profile = ::Gapic::Config::Method.new get_app_profile_config
|
1923
|
-
list_app_profiles_config = parent_rpcs
|
1889
|
+
list_app_profiles_config = parent_rpcs.list_app_profiles if parent_rpcs.respond_to? :list_app_profiles
|
1924
1890
|
@list_app_profiles = ::Gapic::Config::Method.new list_app_profiles_config
|
1925
|
-
update_app_profile_config = parent_rpcs
|
1891
|
+
update_app_profile_config = parent_rpcs.update_app_profile if parent_rpcs.respond_to? :update_app_profile
|
1926
1892
|
@update_app_profile = ::Gapic::Config::Method.new update_app_profile_config
|
1927
|
-
delete_app_profile_config = parent_rpcs
|
1893
|
+
delete_app_profile_config = parent_rpcs.delete_app_profile if parent_rpcs.respond_to? :delete_app_profile
|
1928
1894
|
@delete_app_profile = ::Gapic::Config::Method.new delete_app_profile_config
|
1929
|
-
get_iam_policy_config = parent_rpcs
|
1895
|
+
get_iam_policy_config = parent_rpcs.get_iam_policy if parent_rpcs.respond_to? :get_iam_policy
|
1930
1896
|
@get_iam_policy = ::Gapic::Config::Method.new get_iam_policy_config
|
1931
|
-
set_iam_policy_config = parent_rpcs
|
1897
|
+
set_iam_policy_config = parent_rpcs.set_iam_policy if parent_rpcs.respond_to? :set_iam_policy
|
1932
1898
|
@set_iam_policy = ::Gapic::Config::Method.new set_iam_policy_config
|
1933
|
-
test_iam_permissions_config = parent_rpcs
|
1899
|
+
test_iam_permissions_config = parent_rpcs.test_iam_permissions if parent_rpcs.respond_to? :test_iam_permissions
|
1934
1900
|
@test_iam_permissions = ::Gapic::Config::Method.new test_iam_permissions_config
|
1935
1901
|
|
1936
1902
|
yield self if block_given?
|
@@ -83,7 +83,7 @@ module Google
|
|
83
83
|
# Create credentials
|
84
84
|
credentials = @config.credentials
|
85
85
|
credentials ||= Credentials.default scope: @config.scope
|
86
|
-
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
86
|
+
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
87
87
|
credentials = Credentials.new credentials, scope: @config.scope
|
88
88
|
end
|
89
89
|
@quota_project_id = @config.quota_project
|
@@ -397,9 +397,9 @@ module Google
|
|
397
397
|
end
|
398
398
|
|
399
399
|
##
|
400
|
-
# Waits
|
401
|
-
#
|
402
|
-
#
|
400
|
+
# Waits until the specified long-running operation is done or reaches at most
|
401
|
+
# a specified timeout, returning the latest state. If the operation is
|
402
|
+
# already done, the latest state is immediately returned. If the timeout
|
403
403
|
# specified is greater than the default HTTP/RPC timeout, the HTTP/RPC
|
404
404
|
# timeout is used. If the server does not support this method, it returns
|
405
405
|
# `google.rpc.Code.UNIMPLEMENTED`.
|
@@ -561,7 +561,7 @@ module Google
|
|
561
561
|
config_attr :scope, nil, ::String, ::Array, nil
|
562
562
|
config_attr :lib_name, nil, ::String, nil
|
563
563
|
config_attr :lib_version, nil, ::String, nil
|
564
|
-
config_attr(:channel_args, { "grpc.service_config_disable_resolution"=>1 }, ::Hash, nil)
|
564
|
+
config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil)
|
565
565
|
config_attr :interceptors, nil, ::Array, nil
|
566
566
|
config_attr :timeout, nil, ::Numeric, nil
|
567
567
|
config_attr :metadata, nil, ::Hash, nil
|
@@ -582,7 +582,7 @@ module Google
|
|
582
582
|
def rpcs
|
583
583
|
@rpcs ||= begin
|
584
584
|
parent_rpcs = nil
|
585
|
-
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config
|
585
|
+
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
|
586
586
|
Rpcs.new parent_rpcs
|
587
587
|
end
|
588
588
|
end
|
@@ -633,15 +633,15 @@ module Google
|
|
633
633
|
|
634
634
|
# @private
|
635
635
|
def initialize parent_rpcs = nil
|
636
|
-
list_operations_config = parent_rpcs
|
636
|
+
list_operations_config = parent_rpcs.list_operations if parent_rpcs.respond_to? :list_operations
|
637
637
|
@list_operations = ::Gapic::Config::Method.new list_operations_config
|
638
|
-
get_operation_config = parent_rpcs
|
638
|
+
get_operation_config = parent_rpcs.get_operation if parent_rpcs.respond_to? :get_operation
|
639
639
|
@get_operation = ::Gapic::Config::Method.new get_operation_config
|
640
|
-
delete_operation_config = parent_rpcs
|
640
|
+
delete_operation_config = parent_rpcs.delete_operation if parent_rpcs.respond_to? :delete_operation
|
641
641
|
@delete_operation = ::Gapic::Config::Method.new delete_operation_config
|
642
|
-
cancel_operation_config = parent_rpcs
|
642
|
+
cancel_operation_config = parent_rpcs.cancel_operation if parent_rpcs.respond_to? :cancel_operation
|
643
643
|
@cancel_operation = ::Gapic::Config::Method.new cancel_operation_config
|
644
|
-
wait_operation_config = parent_rpcs
|
644
|
+
wait_operation_config = parent_rpcs.wait_operation if parent_rpcs.respond_to? :wait_operation
|
645
645
|
@wait_operation = ::Gapic::Config::Method.new wait_operation_config
|
646
646
|
|
647
647
|
yield self if block_given?
|
@@ -63,6 +63,27 @@ module Google
|
|
63
63
|
"projects/#{project}/instances/#{instance}/clusters/#{cluster}"
|
64
64
|
end
|
65
65
|
|
66
|
+
##
|
67
|
+
# Create a fully-qualified CryptoKey resource string.
|
68
|
+
#
|
69
|
+
# The resource will be in the following format:
|
70
|
+
#
|
71
|
+
# `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`
|
72
|
+
#
|
73
|
+
# @param project [String]
|
74
|
+
# @param location [String]
|
75
|
+
# @param key_ring [String]
|
76
|
+
# @param crypto_key [String]
|
77
|
+
#
|
78
|
+
# @return [::String]
|
79
|
+
def crypto_key_path project:, location:, key_ring:, crypto_key:
|
80
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
81
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
82
|
+
raise ::ArgumentError, "key_ring cannot contain /" if key_ring.to_s.include? "/"
|
83
|
+
|
84
|
+
"projects/#{project}/locations/#{location}/keyRings/#{key_ring}/cryptoKeys/#{crypto_key}"
|
85
|
+
end
|
86
|
+
|
66
87
|
##
|
67
88
|
# Create a fully-qualified Instance resource string.
|
68
89
|
#
|
@@ -65,7 +65,7 @@ module Google
|
|
65
65
|
parent_config = while namespace.any?
|
66
66
|
parent_name = namespace.join "::"
|
67
67
|
parent_const = const_get parent_name
|
68
|
-
break parent_const.configure if parent_const
|
68
|
+
break parent_const.configure if parent_const.respond_to? :configure
|
69
69
|
namespace.pop
|
70
70
|
end
|
71
71
|
default_config = Client::Configuration.new parent_config
|
@@ -74,18 +74,12 @@ module Google
|
|
74
74
|
|
75
75
|
default_config.rpcs.list_tables.timeout = 60.0
|
76
76
|
default_config.rpcs.list_tables.retry_policy = {
|
77
|
-
initial_delay: 1.0,
|
78
|
-
max_delay: 60.0,
|
79
|
-
multiplier: 2,
|
80
|
-
retry_codes: [14, 4]
|
77
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
81
78
|
}
|
82
79
|
|
83
80
|
default_config.rpcs.get_table.timeout = 60.0
|
84
81
|
default_config.rpcs.get_table.retry_policy = {
|
85
|
-
initial_delay: 1.0,
|
86
|
-
max_delay: 60.0,
|
87
|
-
multiplier: 2,
|
88
|
-
retry_codes: [14, 4]
|
82
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
89
83
|
}
|
90
84
|
|
91
85
|
default_config.rpcs.delete_table.timeout = 60.0
|
@@ -96,44 +90,31 @@ module Google
|
|
96
90
|
|
97
91
|
default_config.rpcs.generate_consistency_token.timeout = 60.0
|
98
92
|
default_config.rpcs.generate_consistency_token.retry_policy = {
|
99
|
-
initial_delay: 1.0,
|
100
|
-
max_delay: 60.0,
|
101
|
-
multiplier: 2,
|
102
|
-
retry_codes: [14, 4]
|
93
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
103
94
|
}
|
104
95
|
|
105
96
|
default_config.rpcs.check_consistency.timeout = 60.0
|
106
97
|
default_config.rpcs.check_consistency.retry_policy = {
|
107
|
-
initial_delay: 1.0,
|
108
|
-
max_delay: 60.0,
|
109
|
-
multiplier: 2,
|
110
|
-
retry_codes: [14, 4]
|
98
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
111
99
|
}
|
112
100
|
|
113
101
|
default_config.rpcs.get_snapshot.timeout = 60.0
|
114
102
|
default_config.rpcs.get_snapshot.retry_policy = {
|
115
|
-
initial_delay: 1.0,
|
116
|
-
max_delay: 60.0,
|
117
|
-
multiplier: 2,
|
118
|
-
retry_codes: [14, 4]
|
103
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
119
104
|
}
|
120
105
|
|
121
106
|
default_config.rpcs.list_snapshots.timeout = 60.0
|
122
107
|
default_config.rpcs.list_snapshots.retry_policy = {
|
123
|
-
initial_delay: 1.0,
|
124
|
-
max_delay: 60.0,
|
125
|
-
multiplier: 2,
|
126
|
-
retry_codes: [14, 4]
|
108
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
127
109
|
}
|
128
110
|
|
129
111
|
default_config.rpcs.delete_snapshot.timeout = 60.0
|
130
112
|
|
113
|
+
default_config.rpcs.create_backup.timeout = 60.0
|
114
|
+
|
131
115
|
default_config.rpcs.get_backup.timeout = 60.0
|
132
116
|
default_config.rpcs.get_backup.retry_policy = {
|
133
|
-
initial_delay: 1.0,
|
134
|
-
max_delay: 60.0,
|
135
|
-
multiplier: 2,
|
136
|
-
retry_codes: [14, 4]
|
117
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
137
118
|
}
|
138
119
|
|
139
120
|
default_config.rpcs.update_backup.timeout = 60.0
|
@@ -142,28 +123,21 @@ module Google
|
|
142
123
|
|
143
124
|
default_config.rpcs.list_backups.timeout = 60.0
|
144
125
|
default_config.rpcs.list_backups.retry_policy = {
|
145
|
-
initial_delay: 1.0,
|
146
|
-
max_delay: 60.0,
|
147
|
-
multiplier: 2,
|
148
|
-
retry_codes: [14, 4]
|
126
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
149
127
|
}
|
150
128
|
|
129
|
+
default_config.rpcs.restore_table.timeout = 60.0
|
130
|
+
|
151
131
|
default_config.rpcs.get_iam_policy.timeout = 60.0
|
152
132
|
default_config.rpcs.get_iam_policy.retry_policy = {
|
153
|
-
initial_delay: 1.0,
|
154
|
-
max_delay: 60.0,
|
155
|
-
multiplier: 2,
|
156
|
-
retry_codes: [14, 4]
|
133
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
157
134
|
}
|
158
135
|
|
159
136
|
default_config.rpcs.set_iam_policy.timeout = 60.0
|
160
137
|
|
161
138
|
default_config.rpcs.test_iam_permissions.timeout = 60.0
|
162
139
|
default_config.rpcs.test_iam_permissions.retry_policy = {
|
163
|
-
initial_delay: 1.0,
|
164
|
-
max_delay: 60.0,
|
165
|
-
multiplier: 2,
|
166
|
-
retry_codes: [14, 4]
|
140
|
+
initial_delay: 1.0, max_delay: 60.0, multiplier: 2, retry_codes: [14, 4]
|
167
141
|
}
|
168
142
|
|
169
143
|
default_config
|
@@ -232,9 +206,9 @@ module Google
|
|
232
206
|
enable_self_signed_jwt = @config.scope == Client.configure.scope &&
|
233
207
|
@config.endpoint == Client.configure.endpoint &&
|
234
208
|
!@config.endpoint.split(".").first.include?("-")
|
235
|
-
credentials ||= Credentials.default scope:
|
209
|
+
credentials ||= Credentials.default scope: @config.scope,
|
236
210
|
enable_self_signed_jwt: enable_self_signed_jwt
|
237
|
-
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
211
|
+
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
238
212
|
credentials = Credentials.new credentials, scope: @config.scope
|
239
213
|
end
|
240
214
|
@quota_project_id = @config.quota_project
|
@@ -1707,7 +1681,7 @@ module Google
|
|
1707
1681
|
|
1708
1682
|
##
|
1709
1683
|
# Create a new table by restoring from a completed backup. The new table
|
1710
|
-
# must be in the same
|
1684
|
+
# must be in the same project as the instance containing the backup. The
|
1711
1685
|
# returned table {::Google::Longrunning::Operation long-running operation} can
|
1712
1686
|
# be used to track the progress of the operation, and to cancel it. The
|
1713
1687
|
# {::Google::Longrunning::Operation#metadata metadata} field type is
|
@@ -1732,8 +1706,8 @@ module Google
|
|
1732
1706
|
#
|
1733
1707
|
# @param parent [::String]
|
1734
1708
|
# Required. The name of the instance in which to create the restored
|
1735
|
-
# table. This instance must be the
|
1736
|
-
# of the form `projects/<project>/instances/<instance>`.
|
1709
|
+
# table. This instance must be in the same project as the source backup.
|
1710
|
+
# Values are of the form `projects/<project>/instances/<instance>`.
|
1737
1711
|
# @param table_id [::String]
|
1738
1712
|
# Required. The id of the table to create and restore to. This
|
1739
1713
|
# table must not already exist. The `table_id` appended to
|
@@ -2098,7 +2072,7 @@ module Google
|
|
2098
2072
|
config_attr :scope, nil, ::String, ::Array, nil
|
2099
2073
|
config_attr :lib_name, nil, ::String, nil
|
2100
2074
|
config_attr :lib_version, nil, ::String, nil
|
2101
|
-
config_attr(:channel_args, { "grpc.service_config_disable_resolution"=>1 }, ::Hash, nil)
|
2075
|
+
config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil)
|
2102
2076
|
config_attr :interceptors, nil, ::Array, nil
|
2103
2077
|
config_attr :timeout, nil, ::Numeric, nil
|
2104
2078
|
config_attr :metadata, nil, ::Hash, nil
|
@@ -2119,7 +2093,7 @@ module Google
|
|
2119
2093
|
def rpcs
|
2120
2094
|
@rpcs ||= begin
|
2121
2095
|
parent_rpcs = nil
|
2122
|
-
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config
|
2096
|
+
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
|
2123
2097
|
Rpcs.new parent_rpcs
|
2124
2098
|
end
|
2125
2099
|
end
|
@@ -2255,49 +2229,49 @@ module Google
|
|
2255
2229
|
|
2256
2230
|
# @private
|
2257
2231
|
def initialize parent_rpcs = nil
|
2258
|
-
create_table_config = parent_rpcs
|
2232
|
+
create_table_config = parent_rpcs.create_table if parent_rpcs.respond_to? :create_table
|
2259
2233
|
@create_table = ::Gapic::Config::Method.new create_table_config
|
2260
|
-
create_table_from_snapshot_config = parent_rpcs
|
2234
|
+
create_table_from_snapshot_config = parent_rpcs.create_table_from_snapshot if parent_rpcs.respond_to? :create_table_from_snapshot
|
2261
2235
|
@create_table_from_snapshot = ::Gapic::Config::Method.new create_table_from_snapshot_config
|
2262
|
-
list_tables_config = parent_rpcs
|
2236
|
+
list_tables_config = parent_rpcs.list_tables if parent_rpcs.respond_to? :list_tables
|
2263
2237
|
@list_tables = ::Gapic::Config::Method.new list_tables_config
|
2264
|
-
get_table_config = parent_rpcs
|
2238
|
+
get_table_config = parent_rpcs.get_table if parent_rpcs.respond_to? :get_table
|
2265
2239
|
@get_table = ::Gapic::Config::Method.new get_table_config
|
2266
|
-
delete_table_config = parent_rpcs
|
2240
|
+
delete_table_config = parent_rpcs.delete_table if parent_rpcs.respond_to? :delete_table
|
2267
2241
|
@delete_table = ::Gapic::Config::Method.new delete_table_config
|
2268
|
-
modify_column_families_config = parent_rpcs
|
2242
|
+
modify_column_families_config = parent_rpcs.modify_column_families if parent_rpcs.respond_to? :modify_column_families
|
2269
2243
|
@modify_column_families = ::Gapic::Config::Method.new modify_column_families_config
|
2270
|
-
drop_row_range_config = parent_rpcs
|
2244
|
+
drop_row_range_config = parent_rpcs.drop_row_range if parent_rpcs.respond_to? :drop_row_range
|
2271
2245
|
@drop_row_range = ::Gapic::Config::Method.new drop_row_range_config
|
2272
|
-
generate_consistency_token_config = parent_rpcs
|
2246
|
+
generate_consistency_token_config = parent_rpcs.generate_consistency_token if parent_rpcs.respond_to? :generate_consistency_token
|
2273
2247
|
@generate_consistency_token = ::Gapic::Config::Method.new generate_consistency_token_config
|
2274
|
-
check_consistency_config = parent_rpcs
|
2248
|
+
check_consistency_config = parent_rpcs.check_consistency if parent_rpcs.respond_to? :check_consistency
|
2275
2249
|
@check_consistency = ::Gapic::Config::Method.new check_consistency_config
|
2276
|
-
snapshot_table_config = parent_rpcs
|
2250
|
+
snapshot_table_config = parent_rpcs.snapshot_table if parent_rpcs.respond_to? :snapshot_table
|
2277
2251
|
@snapshot_table = ::Gapic::Config::Method.new snapshot_table_config
|
2278
|
-
get_snapshot_config = parent_rpcs
|
2252
|
+
get_snapshot_config = parent_rpcs.get_snapshot if parent_rpcs.respond_to? :get_snapshot
|
2279
2253
|
@get_snapshot = ::Gapic::Config::Method.new get_snapshot_config
|
2280
|
-
list_snapshots_config = parent_rpcs
|
2254
|
+
list_snapshots_config = parent_rpcs.list_snapshots if parent_rpcs.respond_to? :list_snapshots
|
2281
2255
|
@list_snapshots = ::Gapic::Config::Method.new list_snapshots_config
|
2282
|
-
delete_snapshot_config = parent_rpcs
|
2256
|
+
delete_snapshot_config = parent_rpcs.delete_snapshot if parent_rpcs.respond_to? :delete_snapshot
|
2283
2257
|
@delete_snapshot = ::Gapic::Config::Method.new delete_snapshot_config
|
2284
|
-
create_backup_config = parent_rpcs
|
2258
|
+
create_backup_config = parent_rpcs.create_backup if parent_rpcs.respond_to? :create_backup
|
2285
2259
|
@create_backup = ::Gapic::Config::Method.new create_backup_config
|
2286
|
-
get_backup_config = parent_rpcs
|
2260
|
+
get_backup_config = parent_rpcs.get_backup if parent_rpcs.respond_to? :get_backup
|
2287
2261
|
@get_backup = ::Gapic::Config::Method.new get_backup_config
|
2288
|
-
update_backup_config = parent_rpcs
|
2262
|
+
update_backup_config = parent_rpcs.update_backup if parent_rpcs.respond_to? :update_backup
|
2289
2263
|
@update_backup = ::Gapic::Config::Method.new update_backup_config
|
2290
|
-
delete_backup_config = parent_rpcs
|
2264
|
+
delete_backup_config = parent_rpcs.delete_backup if parent_rpcs.respond_to? :delete_backup
|
2291
2265
|
@delete_backup = ::Gapic::Config::Method.new delete_backup_config
|
2292
|
-
list_backups_config = parent_rpcs
|
2266
|
+
list_backups_config = parent_rpcs.list_backups if parent_rpcs.respond_to? :list_backups
|
2293
2267
|
@list_backups = ::Gapic::Config::Method.new list_backups_config
|
2294
|
-
restore_table_config = parent_rpcs
|
2268
|
+
restore_table_config = parent_rpcs.restore_table if parent_rpcs.respond_to? :restore_table
|
2295
2269
|
@restore_table = ::Gapic::Config::Method.new restore_table_config
|
2296
|
-
get_iam_policy_config = parent_rpcs
|
2270
|
+
get_iam_policy_config = parent_rpcs.get_iam_policy if parent_rpcs.respond_to? :get_iam_policy
|
2297
2271
|
@get_iam_policy = ::Gapic::Config::Method.new get_iam_policy_config
|
2298
|
-
set_iam_policy_config = parent_rpcs
|
2272
|
+
set_iam_policy_config = parent_rpcs.set_iam_policy if parent_rpcs.respond_to? :set_iam_policy
|
2299
2273
|
@set_iam_policy = ::Gapic::Config::Method.new set_iam_policy_config
|
2300
|
-
test_iam_permissions_config = parent_rpcs
|
2274
|
+
test_iam_permissions_config = parent_rpcs.test_iam_permissions if parent_rpcs.respond_to? :test_iam_permissions
|
2301
2275
|
@test_iam_permissions = ::Gapic::Config::Method.new test_iam_permissions_config
|
2302
2276
|
|
2303
2277
|
yield self if block_given?
|