google-cloud-deploy-v1 0.5.0 → 0.6.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.
@@ -411,9 +411,9 @@ module Google
411
411
  # * (`String`) The path to a service account key file in JSON format
412
412
  # * (`Hash`) A service account key as a Hash
413
413
  # * (`Google::Auth::Credentials`) A googleauth credentials object
414
- # (see the [googleauth docs](https://googleapis.dev/ruby/googleauth/latest/index.html))
414
+ # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
415
415
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
416
- # (see the [signet docs](https://googleapis.dev/ruby/signet/latest/Signet/OAuth2/Client.html))
416
+ # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
417
417
  # * (`nil`) indicating no credentials
418
418
  # @return [::Object]
419
419
  # @!attribute [rw] scope
@@ -610,6 +610,82 @@ module Google
610
610
  result
611
611
  end
612
612
 
613
+ ##
614
+ # Baseline implementation for the advance_rollout REST call
615
+ #
616
+ # @param request_pb [::Google::Cloud::Deploy::V1::AdvanceRolloutRequest]
617
+ # A request object representing the call parameters. Required.
618
+ # @param options [::Gapic::CallOptions]
619
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
620
+ #
621
+ # @yield [result, operation] Access the result along with the TransportOperation object
622
+ # @yieldparam result [::Google::Cloud::Deploy::V1::AdvanceRolloutResponse]
623
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
624
+ #
625
+ # @return [::Google::Cloud::Deploy::V1::AdvanceRolloutResponse]
626
+ # A result object deserialized from the server's reply
627
+ def advance_rollout request_pb, options = nil
628
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
629
+
630
+ verb, uri, query_string_params, body = ServiceStub.transcode_advance_rollout_request request_pb
631
+ query_string_params = if query_string_params.any?
632
+ query_string_params.to_h { |p| p.split("=", 2) }
633
+ else
634
+ {}
635
+ end
636
+
637
+ response = @client_stub.make_http_request(
638
+ verb,
639
+ uri: uri,
640
+ body: body || "",
641
+ params: query_string_params,
642
+ options: options
643
+ )
644
+ operation = ::Gapic::Rest::TransportOperation.new response
645
+ result = ::Google::Cloud::Deploy::V1::AdvanceRolloutResponse.decode_json response.body, ignore_unknown_fields: true
646
+
647
+ yield result, operation if block_given?
648
+ result
649
+ end
650
+
651
+ ##
652
+ # Baseline implementation for the cancel_rollout REST call
653
+ #
654
+ # @param request_pb [::Google::Cloud::Deploy::V1::CancelRolloutRequest]
655
+ # A request object representing the call parameters. Required.
656
+ # @param options [::Gapic::CallOptions]
657
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
658
+ #
659
+ # @yield [result, operation] Access the result along with the TransportOperation object
660
+ # @yieldparam result [::Google::Cloud::Deploy::V1::CancelRolloutResponse]
661
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
662
+ #
663
+ # @return [::Google::Cloud::Deploy::V1::CancelRolloutResponse]
664
+ # A result object deserialized from the server's reply
665
+ def cancel_rollout request_pb, options = nil
666
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
667
+
668
+ verb, uri, query_string_params, body = ServiceStub.transcode_cancel_rollout_request request_pb
669
+ query_string_params = if query_string_params.any?
670
+ query_string_params.to_h { |p| p.split("=", 2) }
671
+ else
672
+ {}
673
+ end
674
+
675
+ response = @client_stub.make_http_request(
676
+ verb,
677
+ uri: uri,
678
+ body: body || "",
679
+ params: query_string_params,
680
+ options: options
681
+ )
682
+ operation = ::Gapic::Rest::TransportOperation.new response
683
+ result = ::Google::Cloud::Deploy::V1::CancelRolloutResponse.decode_json response.body, ignore_unknown_fields: true
684
+
685
+ yield result, operation if block_given?
686
+ result
687
+ end
688
+
613
689
  ##
614
690
  # Baseline implementation for the list_rollouts REST call
615
691
  #
@@ -724,6 +800,44 @@ module Google
724
800
  result
725
801
  end
726
802
 
803
+ ##
804
+ # Baseline implementation for the ignore_job REST call
805
+ #
806
+ # @param request_pb [::Google::Cloud::Deploy::V1::IgnoreJobRequest]
807
+ # A request object representing the call parameters. Required.
808
+ # @param options [::Gapic::CallOptions]
809
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
810
+ #
811
+ # @yield [result, operation] Access the result along with the TransportOperation object
812
+ # @yieldparam result [::Google::Cloud::Deploy::V1::IgnoreJobResponse]
813
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
814
+ #
815
+ # @return [::Google::Cloud::Deploy::V1::IgnoreJobResponse]
816
+ # A result object deserialized from the server's reply
817
+ def ignore_job request_pb, options = nil
818
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
819
+
820
+ verb, uri, query_string_params, body = ServiceStub.transcode_ignore_job_request request_pb
821
+ query_string_params = if query_string_params.any?
822
+ query_string_params.to_h { |p| p.split("=", 2) }
823
+ else
824
+ {}
825
+ end
826
+
827
+ response = @client_stub.make_http_request(
828
+ verb,
829
+ uri: uri,
830
+ body: body || "",
831
+ params: query_string_params,
832
+ options: options
833
+ )
834
+ operation = ::Gapic::Rest::TransportOperation.new response
835
+ result = ::Google::Cloud::Deploy::V1::IgnoreJobResponse.decode_json response.body, ignore_unknown_fields: true
836
+
837
+ yield result, operation if block_given?
838
+ result
839
+ end
840
+
727
841
  ##
728
842
  # Baseline implementation for the retry_job REST call
729
843
  #
@@ -838,6 +952,44 @@ module Google
838
952
  result
839
953
  end
840
954
 
955
+ ##
956
+ # Baseline implementation for the terminate_job_run REST call
957
+ #
958
+ # @param request_pb [::Google::Cloud::Deploy::V1::TerminateJobRunRequest]
959
+ # A request object representing the call parameters. Required.
960
+ # @param options [::Gapic::CallOptions]
961
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
962
+ #
963
+ # @yield [result, operation] Access the result along with the TransportOperation object
964
+ # @yieldparam result [::Google::Cloud::Deploy::V1::TerminateJobRunResponse]
965
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
966
+ #
967
+ # @return [::Google::Cloud::Deploy::V1::TerminateJobRunResponse]
968
+ # A result object deserialized from the server's reply
969
+ def terminate_job_run request_pb, options = nil
970
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
971
+
972
+ verb, uri, query_string_params, body = ServiceStub.transcode_terminate_job_run_request request_pb
973
+ query_string_params = if query_string_params.any?
974
+ query_string_params.to_h { |p| p.split("=", 2) }
975
+ else
976
+ {}
977
+ end
978
+
979
+ response = @client_stub.make_http_request(
980
+ verb,
981
+ uri: uri,
982
+ body: body || "",
983
+ params: query_string_params,
984
+ options: options
985
+ )
986
+ operation = ::Gapic::Rest::TransportOperation.new response
987
+ result = ::Google::Cloud::Deploy::V1::TerminateJobRunResponse.decode_json response.body, ignore_unknown_fields: true
988
+
989
+ yield result, operation if block_given?
990
+ result
991
+ end
992
+
841
993
  ##
842
994
  # Baseline implementation for the get_config REST call
843
995
  #
@@ -1198,6 +1350,50 @@ module Google
1198
1350
  transcoder.transcode request_pb
1199
1351
  end
1200
1352
 
1353
+ ##
1354
+ # @private
1355
+ #
1356
+ # GRPC transcoding helper method for the advance_rollout REST call
1357
+ #
1358
+ # @param request_pb [::Google::Cloud::Deploy::V1::AdvanceRolloutRequest]
1359
+ # A request object representing the call parameters. Required.
1360
+ # @return [Array(String, [String, nil], Hash{String => String})]
1361
+ # Uri, Body, Query string parameters
1362
+ def self.transcode_advance_rollout_request request_pb
1363
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1364
+ .with_bindings(
1365
+ uri_method: :post,
1366
+ uri_template: "/v1/{name}:advance",
1367
+ body: "*",
1368
+ matches: [
1369
+ ["name", %r{^projects/[^/]+/locations/[^/]+/deliveryPipelines/[^/]+/releases/[^/]+/rollouts/[^/]+/?$}, false]
1370
+ ]
1371
+ )
1372
+ transcoder.transcode request_pb
1373
+ end
1374
+
1375
+ ##
1376
+ # @private
1377
+ #
1378
+ # GRPC transcoding helper method for the cancel_rollout REST call
1379
+ #
1380
+ # @param request_pb [::Google::Cloud::Deploy::V1::CancelRolloutRequest]
1381
+ # A request object representing the call parameters. Required.
1382
+ # @return [Array(String, [String, nil], Hash{String => String})]
1383
+ # Uri, Body, Query string parameters
1384
+ def self.transcode_cancel_rollout_request request_pb
1385
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1386
+ .with_bindings(
1387
+ uri_method: :post,
1388
+ uri_template: "/v1/{name}:cancel",
1389
+ body: "*",
1390
+ matches: [
1391
+ ["name", %r{^projects/[^/]+/locations/[^/]+/deliveryPipelines/[^/]+/releases/[^/]+/rollouts/[^/]+/?$}, false]
1392
+ ]
1393
+ )
1394
+ transcoder.transcode request_pb
1395
+ end
1396
+
1201
1397
  ##
1202
1398
  # @private
1203
1399
  #
@@ -1262,6 +1458,28 @@ module Google
1262
1458
  transcoder.transcode request_pb
1263
1459
  end
1264
1460
 
1461
+ ##
1462
+ # @private
1463
+ #
1464
+ # GRPC transcoding helper method for the ignore_job REST call
1465
+ #
1466
+ # @param request_pb [::Google::Cloud::Deploy::V1::IgnoreJobRequest]
1467
+ # A request object representing the call parameters. Required.
1468
+ # @return [Array(String, [String, nil], Hash{String => String})]
1469
+ # Uri, Body, Query string parameters
1470
+ def self.transcode_ignore_job_request request_pb
1471
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1472
+ .with_bindings(
1473
+ uri_method: :post,
1474
+ uri_template: "/v1/{rollout}:ignoreJob",
1475
+ body: "*",
1476
+ matches: [
1477
+ ["rollout", %r{^projects/[^/]+/locations/[^/]+/deliveryPipelines/[^/]+/releases/[^/]+/rollouts/[^/]+/?$}, false]
1478
+ ]
1479
+ )
1480
+ transcoder.transcode request_pb
1481
+ end
1482
+
1265
1483
  ##
1266
1484
  # @private
1267
1485
  #
@@ -1326,6 +1544,28 @@ module Google
1326
1544
  transcoder.transcode request_pb
1327
1545
  end
1328
1546
 
1547
+ ##
1548
+ # @private
1549
+ #
1550
+ # GRPC transcoding helper method for the terminate_job_run REST call
1551
+ #
1552
+ # @param request_pb [::Google::Cloud::Deploy::V1::TerminateJobRunRequest]
1553
+ # A request object representing the call parameters. Required.
1554
+ # @return [Array(String, [String, nil], Hash{String => String})]
1555
+ # Uri, Body, Query string parameters
1556
+ def self.transcode_terminate_job_run_request request_pb
1557
+ transcoder = Gapic::Rest::GrpcTranscoder.new
1558
+ .with_bindings(
1559
+ uri_method: :post,
1560
+ uri_template: "/v1/{name}:terminate",
1561
+ body: "*",
1562
+ matches: [
1563
+ ["name", %r{^projects/[^/]+/locations/[^/]+/deliveryPipelines/[^/]+/releases/[^/]+/rollouts/[^/]+/jobRuns/[^/]+/?$}, false]
1564
+ ]
1565
+ )
1566
+ transcoder.transcode request_pb
1567
+ end
1568
+
1329
1569
  ##
1330
1570
  # @private
1331
1571
  #