google-cloud-capacity_planner-v1beta 0.2.0 → 0.3.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/AUTHENTICATION.md +4 -4
- data/README.md +4 -4
- data/lib/google/cloud/capacity_planner/v1beta/rest.rb +1 -2
- data/lib/google/cloud/capacity_planner/v1beta/usage_service/client.rb +11 -11
- data/lib/google/cloud/capacity_planner/v1beta/usage_service/rest/client.rb +11 -11
- data/lib/google/cloud/capacity_planner/v1beta/version.rb +1 -1
- data/lib/google/cloud/capacity_planner/v1beta.rb +2 -3
- data/lib/google/cloud/capacityplanner/v1beta/usage_service_pb.rb +1 -1
- data/proto_docs/google/cloud/capacityplanner/v1beta/usage_service.rb +11 -11
- metadata +1 -11
- data/lib/google/cloud/capacity_planner/v1beta/capacity_planning_service/client.rb +0 -686
- data/lib/google/cloud/capacity_planner/v1beta/capacity_planning_service/credentials.rb +0 -48
- data/lib/google/cloud/capacity_planner/v1beta/capacity_planning_service/paths.rb +0 -64
- data/lib/google/cloud/capacity_planner/v1beta/capacity_planning_service/rest/client.rb +0 -639
- data/lib/google/cloud/capacity_planner/v1beta/capacity_planning_service/rest/service_stub.rb +0 -279
- data/lib/google/cloud/capacity_planner/v1beta/capacity_planning_service/rest.rb +0 -54
- data/lib/google/cloud/capacity_planner/v1beta/capacity_planning_service.rb +0 -57
- data/lib/google/cloud/capacityplanner/v1beta/capacity_planning_service_pb.rb +0 -73
- data/lib/google/cloud/capacityplanner/v1beta/capacity_planning_service_services_pb.rb +0 -54
- data/proto_docs/google/cloud/capacityplanner/v1beta/capacity_planning_service.rb +0 -374
data/lib/google/cloud/capacity_planner/v1beta/capacity_planning_service/rest/service_stub.rb
DELETED
@@ -1,279 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
# Copyright 2025 Google LLC
|
4
|
-
#
|
5
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
-
# you may not use this file except in compliance with the License.
|
7
|
-
# You may obtain a copy of the License at
|
8
|
-
#
|
9
|
-
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
-
#
|
11
|
-
# Unless required by applicable law or agreed to in writing, software
|
12
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
-
# See the License for the specific language governing permissions and
|
15
|
-
# limitations under the License.
|
16
|
-
|
17
|
-
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
-
|
19
|
-
require "google/cloud/capacityplanner/v1beta/capacity_planning_service_pb"
|
20
|
-
|
21
|
-
module Google
|
22
|
-
module Cloud
|
23
|
-
module CapacityPlanner
|
24
|
-
module V1beta
|
25
|
-
module CapacityPlanningService
|
26
|
-
module Rest
|
27
|
-
##
|
28
|
-
# REST service stub for the CapacityPlanningService service.
|
29
|
-
# Service stub contains baseline method implementations
|
30
|
-
# including transcoding, making the REST call, and deserialing the response.
|
31
|
-
#
|
32
|
-
class ServiceStub
|
33
|
-
# @private
|
34
|
-
def initialize endpoint:, endpoint_template:, universe_domain:, credentials:, logger:
|
35
|
-
# These require statements are intentionally placed here to initialize
|
36
|
-
# the REST modules only when it's required.
|
37
|
-
require "gapic/rest"
|
38
|
-
|
39
|
-
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
|
40
|
-
endpoint_template: endpoint_template,
|
41
|
-
universe_domain: universe_domain,
|
42
|
-
credentials: credentials,
|
43
|
-
numeric_enums: true,
|
44
|
-
service_name: self.class,
|
45
|
-
raise_faraday_errors: false,
|
46
|
-
logger: logger
|
47
|
-
end
|
48
|
-
|
49
|
-
##
|
50
|
-
# The effective universe domain
|
51
|
-
#
|
52
|
-
# @return [String]
|
53
|
-
#
|
54
|
-
def universe_domain
|
55
|
-
@client_stub.universe_domain
|
56
|
-
end
|
57
|
-
|
58
|
-
##
|
59
|
-
# The effective endpoint
|
60
|
-
#
|
61
|
-
# @return [String]
|
62
|
-
#
|
63
|
-
def endpoint
|
64
|
-
@client_stub.endpoint
|
65
|
-
end
|
66
|
-
|
67
|
-
##
|
68
|
-
# The logger used for request/response debug logging.
|
69
|
-
#
|
70
|
-
# @return [Logger]
|
71
|
-
#
|
72
|
-
def logger stub: false
|
73
|
-
stub ? @client_stub.stub_logger : @client_stub.logger
|
74
|
-
end
|
75
|
-
|
76
|
-
##
|
77
|
-
# Baseline implementation for the get_capacity_plan REST call
|
78
|
-
#
|
79
|
-
# @param request_pb [::Google::Cloud::CapacityPlanner::V1beta::GetCapacityPlanRequest]
|
80
|
-
# A request object representing the call parameters. Required.
|
81
|
-
# @param options [::Gapic::CallOptions]
|
82
|
-
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
83
|
-
#
|
84
|
-
# @yield [result, operation] Access the result along with the TransportOperation object
|
85
|
-
# @yieldparam result [::Google::Cloud::CapacityPlanner::V1beta::CapacityPlan]
|
86
|
-
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
87
|
-
#
|
88
|
-
# @return [::Google::Cloud::CapacityPlanner::V1beta::CapacityPlan]
|
89
|
-
# A result object deserialized from the server's reply
|
90
|
-
def get_capacity_plan request_pb, options = nil
|
91
|
-
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
92
|
-
|
93
|
-
verb, uri, query_string_params, body = ServiceStub.transcode_get_capacity_plan_request request_pb
|
94
|
-
query_string_params = if query_string_params.any?
|
95
|
-
query_string_params.to_h { |p| p.split "=", 2 }
|
96
|
-
else
|
97
|
-
{}
|
98
|
-
end
|
99
|
-
|
100
|
-
response = @client_stub.make_http_request(
|
101
|
-
verb,
|
102
|
-
uri: uri,
|
103
|
-
body: body || "",
|
104
|
-
params: query_string_params,
|
105
|
-
method_name: "get_capacity_plan",
|
106
|
-
options: options
|
107
|
-
)
|
108
|
-
operation = ::Gapic::Rest::TransportOperation.new response
|
109
|
-
result = ::Google::Cloud::CapacityPlanner::V1beta::CapacityPlan.decode_json response.body, ignore_unknown_fields: true
|
110
|
-
catch :response do
|
111
|
-
yield result, operation if block_given?
|
112
|
-
result
|
113
|
-
end
|
114
|
-
end
|
115
|
-
|
116
|
-
##
|
117
|
-
# Baseline implementation for the query_capacity_plans REST call
|
118
|
-
#
|
119
|
-
# @param request_pb [::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlansRequest]
|
120
|
-
# A request object representing the call parameters. Required.
|
121
|
-
# @param options [::Gapic::CallOptions]
|
122
|
-
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
123
|
-
#
|
124
|
-
# @yield [result, operation] Access the result along with the TransportOperation object
|
125
|
-
# @yieldparam result [::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlansResponse]
|
126
|
-
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
127
|
-
#
|
128
|
-
# @return [::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlansResponse]
|
129
|
-
# A result object deserialized from the server's reply
|
130
|
-
def query_capacity_plans request_pb, options = nil
|
131
|
-
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
132
|
-
|
133
|
-
verb, uri, query_string_params, body = ServiceStub.transcode_query_capacity_plans_request request_pb
|
134
|
-
query_string_params = if query_string_params.any?
|
135
|
-
query_string_params.to_h { |p| p.split "=", 2 }
|
136
|
-
else
|
137
|
-
{}
|
138
|
-
end
|
139
|
-
|
140
|
-
response = @client_stub.make_http_request(
|
141
|
-
verb,
|
142
|
-
uri: uri,
|
143
|
-
body: body || "",
|
144
|
-
params: query_string_params,
|
145
|
-
method_name: "query_capacity_plans",
|
146
|
-
options: options
|
147
|
-
)
|
148
|
-
operation = ::Gapic::Rest::TransportOperation.new response
|
149
|
-
result = ::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlansResponse.decode_json response.body, ignore_unknown_fields: true
|
150
|
-
catch :response do
|
151
|
-
yield result, operation if block_given?
|
152
|
-
result
|
153
|
-
end
|
154
|
-
end
|
155
|
-
|
156
|
-
##
|
157
|
-
# Baseline implementation for the query_capacity_plan_insights REST call
|
158
|
-
#
|
159
|
-
# @param request_pb [::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlanInsightsRequest]
|
160
|
-
# A request object representing the call parameters. Required.
|
161
|
-
# @param options [::Gapic::CallOptions]
|
162
|
-
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
163
|
-
#
|
164
|
-
# @yield [result, operation] Access the result along with the TransportOperation object
|
165
|
-
# @yieldparam result [::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlanInsightsResponse]
|
166
|
-
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
167
|
-
#
|
168
|
-
# @return [::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlanInsightsResponse]
|
169
|
-
# A result object deserialized from the server's reply
|
170
|
-
def query_capacity_plan_insights request_pb, options = nil
|
171
|
-
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
172
|
-
|
173
|
-
verb, uri, query_string_params, body = ServiceStub.transcode_query_capacity_plan_insights_request request_pb
|
174
|
-
query_string_params = if query_string_params.any?
|
175
|
-
query_string_params.to_h { |p| p.split "=", 2 }
|
176
|
-
else
|
177
|
-
{}
|
178
|
-
end
|
179
|
-
|
180
|
-
response = @client_stub.make_http_request(
|
181
|
-
verb,
|
182
|
-
uri: uri,
|
183
|
-
body: body || "",
|
184
|
-
params: query_string_params,
|
185
|
-
method_name: "query_capacity_plan_insights",
|
186
|
-
options: options
|
187
|
-
)
|
188
|
-
operation = ::Gapic::Rest::TransportOperation.new response
|
189
|
-
result = ::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlanInsightsResponse.decode_json response.body, ignore_unknown_fields: true
|
190
|
-
catch :response do
|
191
|
-
yield result, operation if block_given?
|
192
|
-
result
|
193
|
-
end
|
194
|
-
end
|
195
|
-
|
196
|
-
##
|
197
|
-
# @private
|
198
|
-
#
|
199
|
-
# GRPC transcoding helper method for the get_capacity_plan REST call
|
200
|
-
#
|
201
|
-
# @param request_pb [::Google::Cloud::CapacityPlanner::V1beta::GetCapacityPlanRequest]
|
202
|
-
# A request object representing the call parameters. Required.
|
203
|
-
# @return [Array(String, [String, nil], Hash{String => String})]
|
204
|
-
# Uri, Body, Query string parameters
|
205
|
-
def self.transcode_get_capacity_plan_request request_pb
|
206
|
-
transcoder = Gapic::Rest::GrpcTranscoder.new
|
207
|
-
.with_bindings(
|
208
|
-
uri_method: :get,
|
209
|
-
uri_template: "/v1beta/{name}",
|
210
|
-
matches: [
|
211
|
-
["name", %r{^projects/[^/]+/capacityPlans/[^/]+/?$}, false]
|
212
|
-
]
|
213
|
-
)
|
214
|
-
transcoder.transcode request_pb
|
215
|
-
end
|
216
|
-
|
217
|
-
##
|
218
|
-
# @private
|
219
|
-
#
|
220
|
-
# GRPC transcoding helper method for the query_capacity_plans REST call
|
221
|
-
#
|
222
|
-
# @param request_pb [::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlansRequest]
|
223
|
-
# A request object representing the call parameters. Required.
|
224
|
-
# @return [Array(String, [String, nil], Hash{String => String})]
|
225
|
-
# Uri, Body, Query string parameters
|
226
|
-
def self.transcode_query_capacity_plans_request request_pb
|
227
|
-
transcoder = Gapic::Rest::GrpcTranscoder.new
|
228
|
-
.with_bindings(
|
229
|
-
uri_method: :get,
|
230
|
-
uri_template: "/v1beta/{parent}/capacityPlans:query",
|
231
|
-
matches: [
|
232
|
-
["parent", %r{^organizations/[^/]+/?$}, false]
|
233
|
-
]
|
234
|
-
)
|
235
|
-
.with_bindings(
|
236
|
-
uri_method: :get,
|
237
|
-
uri_template: "/v1beta/{parent}/capacityPlans:query",
|
238
|
-
matches: [
|
239
|
-
["parent", %r{^folders/[^/]+/?$}, false]
|
240
|
-
]
|
241
|
-
)
|
242
|
-
.with_bindings(
|
243
|
-
uri_method: :get,
|
244
|
-
uri_template: "/v1beta/{parent}/capacityPlans:query",
|
245
|
-
matches: [
|
246
|
-
["parent", %r{^projects/[^/]+/?$}, false]
|
247
|
-
]
|
248
|
-
)
|
249
|
-
transcoder.transcode request_pb
|
250
|
-
end
|
251
|
-
|
252
|
-
##
|
253
|
-
# @private
|
254
|
-
#
|
255
|
-
# GRPC transcoding helper method for the query_capacity_plan_insights REST call
|
256
|
-
#
|
257
|
-
# @param request_pb [::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlanInsightsRequest]
|
258
|
-
# A request object representing the call parameters. Required.
|
259
|
-
# @return [Array(String, [String, nil], Hash{String => String})]
|
260
|
-
# Uri, Body, Query string parameters
|
261
|
-
def self.transcode_query_capacity_plan_insights_request request_pb
|
262
|
-
transcoder = Gapic::Rest::GrpcTranscoder.new
|
263
|
-
.with_bindings(
|
264
|
-
uri_method: :post,
|
265
|
-
uri_template: "/v1beta/{parent}/capacityPlanInsights:query",
|
266
|
-
body: "*",
|
267
|
-
matches: [
|
268
|
-
["parent", %r{^projects/[^/]+/?$}, false]
|
269
|
-
]
|
270
|
-
)
|
271
|
-
transcoder.transcode request_pb
|
272
|
-
end
|
273
|
-
end
|
274
|
-
end
|
275
|
-
end
|
276
|
-
end
|
277
|
-
end
|
278
|
-
end
|
279
|
-
end
|
@@ -1,54 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
# Copyright 2025 Google LLC
|
4
|
-
#
|
5
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
-
# you may not use this file except in compliance with the License.
|
7
|
-
# You may obtain a copy of the License at
|
8
|
-
#
|
9
|
-
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
-
#
|
11
|
-
# Unless required by applicable law or agreed to in writing, software
|
12
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
-
# See the License for the specific language governing permissions and
|
15
|
-
# limitations under the License.
|
16
|
-
|
17
|
-
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
-
|
19
|
-
require "gapic/rest"
|
20
|
-
require "gapic/config"
|
21
|
-
require "gapic/config/method"
|
22
|
-
|
23
|
-
require "google/cloud/capacity_planner/v1beta/version"
|
24
|
-
|
25
|
-
require "google/cloud/capacity_planner/v1beta/capacity_planning_service/credentials"
|
26
|
-
require "google/cloud/capacity_planner/v1beta/capacity_planning_service/paths"
|
27
|
-
require "google/cloud/capacity_planner/v1beta/capacity_planning_service/rest/client"
|
28
|
-
|
29
|
-
module Google
|
30
|
-
module Cloud
|
31
|
-
module CapacityPlanner
|
32
|
-
module V1beta
|
33
|
-
##
|
34
|
-
# This API allows users to plan for GCP capacity associated with their
|
35
|
-
# projects. Users can request additional capacity for GCP resources such as
|
36
|
-
# VMs, PDs, etc.
|
37
|
-
#
|
38
|
-
# To load this service and instantiate a REST client:
|
39
|
-
#
|
40
|
-
# require "google/cloud/capacity_planner/v1beta/capacity_planning_service/rest"
|
41
|
-
# client = ::Google::Cloud::CapacityPlanner::V1beta::CapacityPlanningService::Rest::Client.new
|
42
|
-
#
|
43
|
-
module CapacityPlanningService
|
44
|
-
# Client for the REST transport
|
45
|
-
module Rest
|
46
|
-
end
|
47
|
-
end
|
48
|
-
end
|
49
|
-
end
|
50
|
-
end
|
51
|
-
end
|
52
|
-
|
53
|
-
helper_path = ::File.join __dir__, "rest", "helpers.rb"
|
54
|
-
require "google/cloud/capacity_planner/v1beta/capacity_planning_service/rest/helpers" if ::File.file? helper_path
|
@@ -1,57 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
# Copyright 2025 Google LLC
|
4
|
-
#
|
5
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
-
# you may not use this file except in compliance with the License.
|
7
|
-
# You may obtain a copy of the License at
|
8
|
-
#
|
9
|
-
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
-
#
|
11
|
-
# Unless required by applicable law or agreed to in writing, software
|
12
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
-
# See the License for the specific language governing permissions and
|
15
|
-
# limitations under the License.
|
16
|
-
|
17
|
-
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
-
|
19
|
-
require "gapic/common"
|
20
|
-
require "gapic/config"
|
21
|
-
require "gapic/config/method"
|
22
|
-
|
23
|
-
require "google/cloud/capacity_planner/v1beta/version"
|
24
|
-
|
25
|
-
require "google/cloud/capacity_planner/v1beta/capacity_planning_service/credentials"
|
26
|
-
require "google/cloud/capacity_planner/v1beta/capacity_planning_service/paths"
|
27
|
-
require "google/cloud/capacity_planner/v1beta/capacity_planning_service/client"
|
28
|
-
require "google/cloud/capacity_planner/v1beta/capacity_planning_service/rest"
|
29
|
-
|
30
|
-
module Google
|
31
|
-
module Cloud
|
32
|
-
module CapacityPlanner
|
33
|
-
module V1beta
|
34
|
-
##
|
35
|
-
# This API allows users to plan for GCP capacity associated with their
|
36
|
-
# projects. Users can request additional capacity for GCP resources such as
|
37
|
-
# VMs, PDs, etc.
|
38
|
-
#
|
39
|
-
# @example Load this service and instantiate a gRPC client
|
40
|
-
#
|
41
|
-
# require "google/cloud/capacity_planner/v1beta/capacity_planning_service"
|
42
|
-
# client = ::Google::Cloud::CapacityPlanner::V1beta::CapacityPlanningService::Client.new
|
43
|
-
#
|
44
|
-
# @example Load this service and instantiate a REST client
|
45
|
-
#
|
46
|
-
# require "google/cloud/capacity_planner/v1beta/capacity_planning_service/rest"
|
47
|
-
# client = ::Google::Cloud::CapacityPlanner::V1beta::CapacityPlanningService::Rest::Client.new
|
48
|
-
#
|
49
|
-
module CapacityPlanningService
|
50
|
-
end
|
51
|
-
end
|
52
|
-
end
|
53
|
-
end
|
54
|
-
end
|
55
|
-
|
56
|
-
helper_path = ::File.join __dir__, "capacity_planning_service", "helpers.rb"
|
57
|
-
require "google/cloud/capacity_planner/v1beta/capacity_planning_service/helpers" if ::File.file? helper_path
|
@@ -1,73 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
3
|
-
# source: google/cloud/capacityplanner/v1beta/capacity_planning_service.proto
|
4
|
-
|
5
|
-
require 'google/protobuf'
|
6
|
-
|
7
|
-
require 'google/api/annotations_pb'
|
8
|
-
require 'google/api/client_pb'
|
9
|
-
require 'google/api/field_behavior_pb'
|
10
|
-
require 'google/api/resource_pb'
|
11
|
-
require 'google/cloud/capacityplanner/v1beta/location_pb'
|
12
|
-
require 'google/cloud/capacityplanner/v1beta/resource_pb'
|
13
|
-
require 'google/protobuf/timestamp_pb'
|
14
|
-
|
15
|
-
|
16
|
-
descriptor_data = "\nCgoogle/cloud/capacityplanner/v1beta/capacity_planning_service.proto\x12#google.cloud.capacityplanner.v1beta\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a\x32google/cloud/capacityplanner/v1beta/location.proto\x1a\x32google/cloud/capacityplanner/v1beta/resource.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"[\n\x16GetCapacityPlanRequest\x12\x41\n\x04name\x18\x01 \x01(\tB3\xe0\x41\x02\xfa\x41-\n+capacityplanner.googleapis.com/CapacityPlan\"\xa8\x01\n\x19QueryCapacityPlansRequest\x12\x43\n\x06parent\x18\x01 \x01(\tB3\xe0\x41\x02\xfa\x41-\x12+capacityplanner.googleapis.com/CapacityPlan\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08location\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\x80\x01\n\x1aQueryCapacityPlansResponse\x12I\n\x0e\x63\x61pacity_plans\x18\x01 \x03(\x0b\x32\x31.google.cloud.capacityplanner.v1beta.CapacityPlan\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"\x95\x01\n QueryCapacityPlanInsightsRequest\x12\x13\n\x06parent\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12\\\n\x15\x63\x61pacity_plan_filters\x18\x02 \x01(\x0b\x32\x38.google.cloud.capacityplanner.v1beta.CapacityPlanFiltersB\x03\xe0\x41\x02\"\x86\x01\n!QueryCapacityPlanInsightsResponse\x12\x61\n\x1d\x61ggregated_capacity_plan_view\x18\x01 \x01(\x0b\x32\x35.google.cloud.capacityplanner.v1beta.CapacityPlanViewB\x03\xe0\x41\x01\"\xcd\x01\n\x13\x43\x61pacityPlanFilters\x12G\n\x04keys\x18\x01 \x03(\x0b\x32\x34.google.cloud.capacityplanner.v1beta.CapacityPlanKeyB\x03\xe0\x41\x02\x12N\n\x0e\x63\x61pacity_types\x18\x02 \x03(\x0e\x32\x31.google.cloud.capacityplanner.v1beta.CapacityTypeB\x03\xe0\x41\x02\x12\x1d\n\x10\x63\x61pacity_plan_id\x18\x03 \x01(\tB\x03\xe0\x41\x01\"\x8f\x02\n\x0f\x43\x61pacityPlanKey\x12W\n\x12resource_container\x18\x01 \x01(\x0b\x32\x36.google.cloud.capacityplanner.v1beta.ResourceContainerB\x03\xe0\x41\x02\x12P\n\x0fresource_id_key\x18\x02 \x01(\x0b\x32\x32.google.cloud.capacityplanner.v1beta.ResourceIdKeyB\x03\xe0\x41\x02\x12Q\n\x0blocation_id\x18\x03 \x01(\x0b\x32\x37.google.cloud.capacityplanner.v1beta.LocationIdentifierB\x03\xe0\x41\x02\"\xaf\x01\n\x10\x43\x61pacityPlanView\x12\x46\n\x03key\x18\x01 \x01(\x0b\x32\x34.google.cloud.capacityplanner.v1beta.CapacityPlanKeyB\x03\xe0\x41\x02\x12S\n\x11time_series_views\x18\x02 \x03(\x0b\x32\x33.google.cloud.capacityplanner.v1beta.TimeSeriesViewB\x03\xe0\x41\x02\"\xa5\x01\n\x0eTimeSeriesView\x12\x44\n\x04type\x18\x01 \x01(\x0e\x32\x31.google.cloud.capacityplanner.v1beta.CapacityTypeB\x03\xe0\x41\x02\x12M\n\x0e\x63\x61pacity_value\x18\x02 \x01(\x0b\x32\x30.google.cloud.capacityplanner.v1beta.DemandValueB\x03\xe0\x41\x02\"\xec\x04\n\x0c\x43\x61pacityPlan\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12Z\n\x18\x63\x61pacity_demand_metadata\x18\x02 \x01(\x0b\x32\x33.google.cloud.capacityplanner.v1beta.DemandMetadataB\x03\xe0\x41\x01\x12P\n\x0fservice_demands\x18\x03 \x03(\x0b\x32\x32.google.cloud.capacityplanner.v1beta.ServiceDemandB\x03\xe0\x41\x02\x12@\n\x08reporter\x18\x04 \x01(\x0b\x32).google.cloud.capacityplanner.v1beta.UserB\x03\xe0\x41\x03\x12>\n\x05state\x18\x05 \x01(\x0e\x32*.google.cloud.capacityplanner.v1beta.StateB\x03\xe0\x41\x03\x12\x34\n\x0b\x63reate_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x18\n\x0b\x64\x65scription\x18\x08 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05title\x18\t \x01(\tB\x03\xe0\x41\x01:\x7f\xea\x41|\n+capacityplanner.googleapis.com/CapacityPlan\x12\x30projects/{project}/capacityPlans/{capacity_plan}*\rcapacityPlans2\x0c\x63\x61pacityPlan\"h\n\x0e\x44\x65mandMetadata\x12V\n\x12\x64\x65mand_preferences\x18\x01 \x03(\x0b\x32\x35.google.cloud.capacityplanner.v1beta.DemandPreferenceB\x03\xe0\x41\x01\"n\n\x10\x44\x65mandPreference\x12\x1a\n\rpreference_id\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12>\n\x05value\x18\x02 \x01(\x0b\x32*.google.cloud.capacityplanner.v1beta.ValueB\x03\xe0\x41\x02\"\xcc\x01\n\rServiceDemand\x12\x14\n\x07service\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12Q\n\x0f\x64\x65mand_metadata\x18\x02 \x01(\x0b\x32\x33.google.cloud.capacityplanner.v1beta.DemandMetadataB\x03\xe0\x41\x01\x12R\n\x10resource_demands\x18\x03 \x03(\x0b\x32\x33.google.cloud.capacityplanner.v1beta.ResourceDemandB\x03\xe0\x41\x02\"\x8f\x06\n\x0eResourceDemand\x12\x0f\n\x02id\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12W\n\x12resource_container\x18\x02 \x01(\x0b\x32\x36.google.cloud.capacityplanner.v1beta.ResourceContainerB\x03\xe0\x41\x02\x12Q\n\x0bresource_id\x18\x03 \x01(\x0b\x32\x37.google.cloud.capacityplanner.v1beta.ResourceIdentifierB\x03\xe0\x41\x02\x12Q\n\x0blocation_id\x18\x04 \x01(\x0b\x32\x37.google.cloud.capacityplanner.v1beta.LocationIdentifierB\x03\xe0\x41\x02\x12>\n\x05state\x18\x05 \x01(\x0e\x32*.google.cloud.capacityplanner.v1beta.StateB\x03\xe0\x41\x03\x12@\n\x08reporter\x18\x06 \x01(\x0b\x32).google.cloud.capacityplanner.v1beta.UserB\x03\xe0\x41\x03\x12\x34\n\x0b\x63reate_time\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12M\n\rdemand_values\x18\t \x01(\x0b\x32\x31.google.cloud.capacityplanner.v1beta.DemandValuesB\x03\xe0\x41\x02\x12Q\n\x0f\x64\x65mand_metadata\x18\n \x01(\x0b\x32\x33.google.cloud.capacityplanner.v1beta.DemandMetadataB\x03\xe0\x41\x01\x12]\n\x16\x63hild_resource_demands\x18\x0b \x03(\x0b\x32\x38.google.cloud.capacityplanner.v1beta.ChildResourceDemandB\x03\xe0\x41\x01\"\x1a\n\x04User\x12\x12\n\x05\x65mail\x18\x01 \x01(\tB\x03\xe0\x41\x02\"U\n\x0c\x44\x65mandValues\x12\x45\n\x06values\x18\x01 \x03(\x0b\x32\x30.google.cloud.capacityplanner.v1beta.DemandValueB\x03\xe0\x41\x02\"\xa8\x01\n\x0b\x44\x65mandValue\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12H\n\x0btime_values\x18\x02 \x03(\x0b\x32..google.cloud.capacityplanner.v1beta.TimeValueB\x03\xe0\x41\x02\x12<\n\x04unit\x18\x03 \x01(\x0e\x32).google.cloud.capacityplanner.v1beta.UnitB\x03\xe0\x41\x02\"]\n\tTimeValue\x12-\n\x04time\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02\x12\x17\n\x05value\x18\x02 \x01(\x01\x42\x03\xe0\x41\x02H\x00\x88\x01\x01\x42\x08\n\x06_value\"\x8a\x02\n\x13\x43hildResourceDemand\x12Q\n\x0bresource_id\x18\x01 \x01(\x0b\x32\x37.google.cloud.capacityplanner.v1beta.ResourceIdentifierB\x03\xe0\x41\x02\x12M\n\rdemand_values\x18\x02 \x01(\x0b\x32\x31.google.cloud.capacityplanner.v1beta.DemandValuesB\x03\xe0\x41\x02\x12Q\n\x0f\x64\x65mand_metadata\x18\x03 \x01(\x0b\x32\x33.google.cloud.capacityplanner.v1beta.DemandMetadataB\x03\xe0\x41\x01*\xb1\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x12\n\x0ePENDING_REVIEW\x10\x01\x12\r\n\tIN_REVIEW\x10\x03\x12\x18\n\x14\x41PPROVED_PROVISIONAL\x10\x08\x12\x0c\n\x08OBSOLETE\x10\x05\x12\x17\n\x13\x43\x41NNOT_BE_FULFILLED\x10\x07\x12\x19\n\x15ON_HOLD_CONTACT_SALES\x10\t\x12\x12\n\x0eIN_FULFILLMENT\x10\n*\x97\x01\n\x0c\x43\x61pacityType\x12\x19\n\x15\x43\x41PACITY_TYPE_UNKNOWN\x10\x00\x12!\n\x1d\x43\x41PACITY_TYPE_INORGANIC_DRAFT\x10\x01\x12#\n\x1f\x43\x41PACITY_TYPE_INORGANIC_PENDING\x10\x02\x12$\n CAPACITY_TYPE_INORGANIC_APPROVED\x10\x03\x32\xb9\x07\n\x17\x43\x61pacityPlanningService\x12\xbb\x01\n\x0fGetCapacityPlan\x12;.google.cloud.capacityplanner.v1beta.GetCapacityPlanRequest\x1a\x31.google.cloud.capacityplanner.v1beta.CapacityPlan\"8\xda\x41\x04name\x82\xd3\xe4\x93\x02+\x12)/v1beta/{name=projects/*/capacityPlans/*}\x12\xc3\x02\n\x12QueryCapacityPlans\x12>.google.cloud.capacityplanner.v1beta.QueryCapacityPlansRequest\x1a?.google.cloud.capacityplanner.v1beta.QueryCapacityPlansResponse\"\xab\x01\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x9b\x01\x12\x34/v1beta/{parent=organizations/*}/capacityPlans:queryZ0\x12./v1beta/{parent=folders/*}/capacityPlans:queryZ1\x12//v1beta/{parent=projects/*}/capacityPlans:query\x12\x8c\x02\n\x19QueryCapacityPlanInsights\x12\x45.google.cloud.capacityplanner.v1beta.QueryCapacityPlanInsightsRequest\x1a\x46.google.cloud.capacityplanner.v1beta.QueryCapacityPlanInsightsResponse\"`\xda\x41\x1cparent,capacity_plan_filters\x82\xd3\xe4\x93\x02;\"6/v1beta/{parent=projects/*}/capacityPlanInsights:query:\x01*\x1a\x8a\x01\xca\x41\x1e\x63\x61pacityplanner.googleapis.com\xd2\x41\x66https://www.googleapis.com/auth/cloud-platform,https://www.googleapis.com/auth/devstorage.full_controlB\x91\x02\n\'com.google.cloud.capacityplanner.v1betaB\x1c\x43\x61pacityPlanningServiceProtoP\x01ZQcloud.google.com/go/capacityplanner/apiv1beta/capacityplannerpb;capacityplannerpb\xaa\x02#Google.Cloud.CapacityPlanner.V1Beta\xca\x02#Google\\Cloud\\CapacityPlanner\\V1beta\xea\x02&Google::Cloud::CapacityPlanner::V1betab\x06proto3"
|
17
|
-
|
18
|
-
pool = Google::Protobuf::DescriptorPool.generated_pool
|
19
|
-
|
20
|
-
begin
|
21
|
-
pool.add_serialized_file(descriptor_data)
|
22
|
-
rescue TypeError
|
23
|
-
# Compatibility code: will be removed in the next major version.
|
24
|
-
require 'google/protobuf/descriptor_pb'
|
25
|
-
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
26
|
-
parsed.clear_dependency
|
27
|
-
serialized = parsed.class.encode(parsed)
|
28
|
-
file = pool.add_serialized_file(serialized)
|
29
|
-
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
30
|
-
imports = [
|
31
|
-
["google.cloud.capacityplanner.v1beta.ResourceContainer", "google/cloud/capacityplanner/v1beta/resource.proto"],
|
32
|
-
["google.cloud.capacityplanner.v1beta.LocationIdentifier", "google/cloud/capacityplanner/v1beta/location.proto"],
|
33
|
-
["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"],
|
34
|
-
]
|
35
|
-
imports.each do |type_name, expected_filename|
|
36
|
-
import_file = pool.lookup(type_name).file_descriptor
|
37
|
-
if import_file.name != expected_filename
|
38
|
-
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
39
|
-
end
|
40
|
-
end
|
41
|
-
warn "Each proto file must use a consistent fully-qualified name."
|
42
|
-
warn "This will become an error in the next major version."
|
43
|
-
end
|
44
|
-
|
45
|
-
module Google
|
46
|
-
module Cloud
|
47
|
-
module CapacityPlanner
|
48
|
-
module V1beta
|
49
|
-
GetCapacityPlanRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.GetCapacityPlanRequest").msgclass
|
50
|
-
QueryCapacityPlansRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.QueryCapacityPlansRequest").msgclass
|
51
|
-
QueryCapacityPlansResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.QueryCapacityPlansResponse").msgclass
|
52
|
-
QueryCapacityPlanInsightsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.QueryCapacityPlanInsightsRequest").msgclass
|
53
|
-
QueryCapacityPlanInsightsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.QueryCapacityPlanInsightsResponse").msgclass
|
54
|
-
CapacityPlanFilters = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.CapacityPlanFilters").msgclass
|
55
|
-
CapacityPlanKey = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.CapacityPlanKey").msgclass
|
56
|
-
CapacityPlanView = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.CapacityPlanView").msgclass
|
57
|
-
TimeSeriesView = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.TimeSeriesView").msgclass
|
58
|
-
CapacityPlan = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.CapacityPlan").msgclass
|
59
|
-
DemandMetadata = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.DemandMetadata").msgclass
|
60
|
-
DemandPreference = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.DemandPreference").msgclass
|
61
|
-
ServiceDemand = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.ServiceDemand").msgclass
|
62
|
-
ResourceDemand = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.ResourceDemand").msgclass
|
63
|
-
User = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.User").msgclass
|
64
|
-
DemandValues = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.DemandValues").msgclass
|
65
|
-
DemandValue = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.DemandValue").msgclass
|
66
|
-
TimeValue = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.TimeValue").msgclass
|
67
|
-
ChildResourceDemand = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.ChildResourceDemand").msgclass
|
68
|
-
State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.State").enummodule
|
69
|
-
CapacityType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.capacityplanner.v1beta.CapacityType").enummodule
|
70
|
-
end
|
71
|
-
end
|
72
|
-
end
|
73
|
-
end
|
@@ -1,54 +0,0 @@
|
|
1
|
-
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
-
# Source: google/cloud/capacityplanner/v1beta/capacity_planning_service.proto for package 'Google.Cloud.CapacityPlanner.V1beta'
|
3
|
-
# Original file comments:
|
4
|
-
# Copyright 2025 Google LLC
|
5
|
-
#
|
6
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
7
|
-
# you may not use this file except in compliance with the License.
|
8
|
-
# You may obtain a copy of the License at
|
9
|
-
#
|
10
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
11
|
-
#
|
12
|
-
# Unless required by applicable law or agreed to in writing, software
|
13
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
14
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
15
|
-
# See the License for the specific language governing permissions and
|
16
|
-
# limitations under the License.
|
17
|
-
#
|
18
|
-
|
19
|
-
require 'grpc'
|
20
|
-
require 'google/cloud/capacityplanner/v1beta/capacity_planning_service_pb'
|
21
|
-
|
22
|
-
module Google
|
23
|
-
module Cloud
|
24
|
-
module CapacityPlanner
|
25
|
-
module V1beta
|
26
|
-
module CapacityPlanningService
|
27
|
-
# This API allows users to plan for GCP capacity associated with their
|
28
|
-
# projects. Users can request additional capacity for GCP resources such as
|
29
|
-
# VMs, PDs, etc.
|
30
|
-
class Service
|
31
|
-
|
32
|
-
include ::GRPC::GenericService
|
33
|
-
|
34
|
-
self.marshal_class_method = :encode
|
35
|
-
self.unmarshal_class_method = :decode
|
36
|
-
self.service_name = 'google.cloud.capacityplanner.v1beta.CapacityPlanningService'
|
37
|
-
|
38
|
-
# Returns information about the capacity plan.
|
39
|
-
rpc :GetCapacityPlan, ::Google::Cloud::CapacityPlanner::V1beta::GetCapacityPlanRequest, ::Google::Cloud::CapacityPlanner::V1beta::CapacityPlan
|
40
|
-
# Returns a list of the capacity plans that are in the parent parameter and
|
41
|
-
# match your specified filters.
|
42
|
-
# (The maximum list length is limited by the pageSize parameter.)
|
43
|
-
rpc :QueryCapacityPlans, ::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlansRequest, ::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlansResponse
|
44
|
-
# Query capacity plan insights that are in the parent parameter and match
|
45
|
-
# your specified filters.
|
46
|
-
rpc :QueryCapacityPlanInsights, ::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlanInsightsRequest, ::Google::Cloud::CapacityPlanner::V1beta::QueryCapacityPlanInsightsResponse
|
47
|
-
end
|
48
|
-
|
49
|
-
Stub = Service.rpc_stub_class
|
50
|
-
end
|
51
|
-
end
|
52
|
-
end
|
53
|
-
end
|
54
|
-
end
|