google-apis-spanner_v1 0.23.0 → 0.26.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -16,13 +16,13 @@ module Google
16
16
  module Apis
17
17
  module SpannerV1
18
18
  # Version of the google-apis-spanner_v1 gem
19
- GEM_VERSION = "0.23.0"
19
+ GEM_VERSION = "0.26.0"
20
20
 
21
21
  # Version of the code generator used to generate this client
22
22
  GENERATOR_VERSION = "0.4.1"
23
23
 
24
24
  # Revision of the discovery document this client was generated from
25
- REVISION = "20220124"
25
+ REVISION = "20220326"
26
26
  end
27
27
  end
28
28
  end
@@ -88,6 +88,24 @@ module Google
88
88
  include Google::Apis::Core::JsonObjectSupport
89
89
  end
90
90
 
91
+ class CopyBackupEncryptionConfig
92
+ class Representation < Google::Apis::Core::JsonRepresentation; end
93
+
94
+ include Google::Apis::Core::JsonObjectSupport
95
+ end
96
+
97
+ class CopyBackupMetadata
98
+ class Representation < Google::Apis::Core::JsonRepresentation; end
99
+
100
+ include Google::Apis::Core::JsonObjectSupport
101
+ end
102
+
103
+ class CopyBackupRequest
104
+ class Representation < Google::Apis::Core::JsonRepresentation; end
105
+
106
+ include Google::Apis::Core::JsonObjectSupport
107
+ end
108
+
91
109
  class CreateBackupMetadata
92
110
  class Representation < Google::Apis::Core::JsonRepresentation; end
93
111
 
@@ -643,7 +661,9 @@ module Google
643
661
  property :encryption_info, as: 'encryptionInfo', class: Google::Apis::SpannerV1::EncryptionInfo, decorator: Google::Apis::SpannerV1::EncryptionInfo::Representation
644
662
 
645
663
  property :expire_time, as: 'expireTime'
664
+ property :max_expire_time, as: 'maxExpireTime'
646
665
  property :name, as: 'name'
666
+ collection :referencing_backups, as: 'referencingBackups'
647
667
  collection :referencing_databases, as: 'referencingDatabases'
648
668
  property :size_bytes, :numeric_string => true, as: 'sizeBytes'
649
669
  property :state, as: 'state'
@@ -748,6 +768,36 @@ module Google
748
768
  end
749
769
  end
750
770
 
771
+ class CopyBackupEncryptionConfig
772
+ # @private
773
+ class Representation < Google::Apis::Core::JsonRepresentation
774
+ property :encryption_type, as: 'encryptionType'
775
+ property :kms_key_name, as: 'kmsKeyName'
776
+ end
777
+ end
778
+
779
+ class CopyBackupMetadata
780
+ # @private
781
+ class Representation < Google::Apis::Core::JsonRepresentation
782
+ property :cancel_time, as: 'cancelTime'
783
+ property :name, as: 'name'
784
+ property :progress, as: 'progress', class: Google::Apis::SpannerV1::OperationProgress, decorator: Google::Apis::SpannerV1::OperationProgress::Representation
785
+
786
+ property :source_backup, as: 'sourceBackup'
787
+ end
788
+ end
789
+
790
+ class CopyBackupRequest
791
+ # @private
792
+ class Representation < Google::Apis::Core::JsonRepresentation
793
+ property :backup_id, as: 'backupId'
794
+ property :encryption_config, as: 'encryptionConfig', class: Google::Apis::SpannerV1::CopyBackupEncryptionConfig, decorator: Google::Apis::SpannerV1::CopyBackupEncryptionConfig::Representation
795
+
796
+ property :expire_time, as: 'expireTime'
797
+ property :source_backup, as: 'sourceBackup'
798
+ end
799
+ end
800
+
751
801
  class CreateBackupMetadata
752
802
  # @private
753
803
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -983,6 +1033,7 @@ module Google
983
1033
  # @private
984
1034
  class Representation < Google::Apis::Core::JsonRepresentation
985
1035
  property :config, as: 'config'
1036
+ property :create_time, as: 'createTime'
986
1037
  property :display_name, as: 'displayName'
987
1038
  collection :endpoint_uris, as: 'endpointUris'
988
1039
  hash :labels, as: 'labels'
@@ -990,6 +1041,7 @@ module Google
990
1041
  property :node_count, as: 'nodeCount'
991
1042
  property :processing_units, as: 'processingUnits'
992
1043
  property :state, as: 'state'
1044
+ property :update_time, as: 'updateTime'
993
1045
  end
994
1046
  end
995
1047
 
@@ -483,22 +483,38 @@ module Google
483
483
  # true. * `metadata.@type` - the type of metadata. For example, the type string
484
484
  # for CreateBackupMetadata is `type.googleapis.com/google.spanner.admin.database.
485
485
  # v1.CreateBackupMetadata`. * `metadata.` - any field in metadata.value. `
486
- # metadata.type_url` must be specified if filtering on metadata fields. * `error`
487
- # - Error associated with the long-running operation. * `response.@type` - the
488
- # type of response. * `response.` - any field in response.value. You can combine
489
- # multiple expressions by enclosing each expression in parentheses. By default,
490
- # expressions are combined with AND logic, but you can specify AND, OR, and NOT
491
- # logic explicitly. Here are a few examples: * `done:true` - The operation is
492
- # complete. * `(metadata.@type=type.googleapis.com/google.spanner.admin.database.
493
- # v1.CreateBackupMetadata) AND` \ `metadata.database:prod` - Returns operations
494
- # where: * The operation's metadata type is CreateBackupMetadata. * The database
495
- # the backup was taken from has a name containing the string "prod". * `(
486
+ # metadata.@type` must be specified first if filtering on metadata fields. * `
487
+ # error` - Error associated with the long-running operation. * `response.@type` -
488
+ # the type of response. * `response.` - any field in response.value. You can
489
+ # combine multiple expressions by enclosing each expression in parentheses. By
490
+ # default, expressions are combined with AND logic, but you can specify AND, OR,
491
+ # and NOT logic explicitly. Here are a few examples: * `done:true` - The
492
+ # operation is complete. * `(metadata.@type=type.googleapis.com/google.spanner.
493
+ # admin.database.v1.CreateBackupMetadata) AND` \ `metadata.database:prod` -
494
+ # Returns operations where: * The operation's metadata type is
495
+ # CreateBackupMetadata. * The database the backup was taken from has a name
496
+ # containing the string "prod". * `(metadata.@type=type.googleapis.com/google.
497
+ # spanner.admin.database.v1.CreateBackupMetadata) AND` \ `(metadata.name:howl)
498
+ # AND` \ `(metadata.progress.start_time < \"2018-03-28T14:50:00Z\") AND` \ `(
499
+ # error:*)` - Returns operations where: * The operation's metadata type is
500
+ # CreateBackupMetadata. * The backup name contains the string "howl". * The
501
+ # operation started before 2018-03-28T14:50:00Z. * The operation resulted in an
502
+ # error. * `(metadata.@type=type.googleapis.com/google.spanner.admin.database.v1.
503
+ # CopyBackupMetadata) AND` \ `(metadata.source_backup:test) AND` \ `(metadata.
504
+ # progress.start_time < \"2022-01-18T14:50:00Z\") AND` \ `(error:*)` - Returns
505
+ # operations where: * The operation's metadata type is CopyBackupMetadata. * The
506
+ # source backup of the copied backup name contains the string "test". * The
507
+ # operation started before 2022-01-18T14:50:00Z. * The operation resulted in an
508
+ # error. * `((metadata.@type=type.googleapis.com/google.spanner.admin.database.
509
+ # v1.CreateBackupMetadata) AND` \ `(metadata.database:test_db)) OR` \ `((
496
510
  # metadata.@type=type.googleapis.com/google.spanner.admin.database.v1.
497
- # CreateBackupMetadata) AND` \ `(metadata.name:howl) AND` \ `(metadata.progress.
498
- # start_time < \"2018-03-28T14:50:00Z\") AND` \ `(error:*)` - Returns operations
499
- # where: * The operation's metadata type is CreateBackupMetadata. * The backup
500
- # name contains the string "howl". * The operation started before 2018-03-28T14:
501
- # 50:00Z. * The operation resulted in an error.
511
+ # CopyBackupMetadata) AND` \ `(metadata.source_backup:test_bkp)) AND` \ `(error:*
512
+ # )` - Returns operations where: * The operation's metadata matches either of
513
+ # criteria: * The operation's metadata type is CreateBackupMetadata AND the
514
+ # database the backup was taken from has name containing string "test_db" * The
515
+ # operation's metadata type is CopyBackupMetadata AND the backup the backup was
516
+ # copied from has name containing string "test_bkp" * The operation resulted in
517
+ # an error.
502
518
  # @param [Fixnum] page_size
503
519
  # Number of operations to be returned in the response. If 0 or less, defaults to
504
520
  # the server's maximum allowed page size.
@@ -535,6 +551,46 @@ module Google
535
551
  execute_or_queue_command(command, &block)
536
552
  end
537
553
 
554
+ # Starts copying a Cloud Spanner Backup. The returned backup long-running
555
+ # operation will have a name of the format `projects//instances//backups//
556
+ # operations/` and can be used to track copying of the backup. The operation is
557
+ # associated with the destination backup. The metadata field type is
558
+ # CopyBackupMetadata. The response field type is Backup, if successful.
559
+ # Cancelling the returned operation will stop the copying and delete the backup.
560
+ # Concurrent CopyBackup requests can run on the same source backup.
561
+ # @param [String] parent
562
+ # Required. The name of the destination instance that will contain the backup
563
+ # copy. Values are of the form: `projects//instances/`.
564
+ # @param [Google::Apis::SpannerV1::CopyBackupRequest] copy_backup_request_object
565
+ # @param [String] fields
566
+ # Selector specifying which fields to include in a partial response.
567
+ # @param [String] quota_user
568
+ # Available to use for quota purposes for server-side applications. Can be any
569
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
570
+ # @param [Google::Apis::RequestOptions] options
571
+ # Request-specific options
572
+ #
573
+ # @yield [result, err] Result & error if block supplied
574
+ # @yieldparam result [Google::Apis::SpannerV1::Operation] parsed result object
575
+ # @yieldparam err [StandardError] error object if request failed
576
+ #
577
+ # @return [Google::Apis::SpannerV1::Operation]
578
+ #
579
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
580
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
581
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
582
+ def copy_backup(parent, copy_backup_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
583
+ command = make_simple_command(:post, 'v1/{+parent}/backups:copy', options)
584
+ command.request_representation = Google::Apis::SpannerV1::CopyBackupRequest::Representation
585
+ command.request_object = copy_backup_request_object
586
+ command.response_representation = Google::Apis::SpannerV1::Operation::Representation
587
+ command.response_class = Google::Apis::SpannerV1::Operation
588
+ command.params['parent'] = parent unless parent.nil?
589
+ command.query['fields'] = fields unless fields.nil?
590
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
591
+ execute_or_queue_command(command, &block)
592
+ end
593
+
538
594
  # Starts creating a new Cloud Spanner Backup. The returned backup long-running
539
595
  # operation will have a name of the format `projects//instances//backups//
540
596
  # operations/` and can be used to track creation of the backup. The metadata
@@ -1044,7 +1100,8 @@ module Google
1044
1100
  # true. * `metadata.@type` - the type of metadata. For example, the type string
1045
1101
  # for RestoreDatabaseMetadata is `type.googleapis.com/google.spanner.admin.
1046
1102
  # database.v1.RestoreDatabaseMetadata`. * `metadata.` - any field in metadata.
1047
- # value. * `error` - Error associated with the long-running operation. * `
1103
+ # value. `metadata.@type` must be specified first, if filtering on metadata
1104
+ # fields. * `error` - Error associated with the long-running operation. * `
1048
1105
  # response.@type` - the type of response. * `response.` - any field in response.
1049
1106
  # value. You can combine multiple expressions by enclosing each expression in
1050
1107
  # parentheses. By default, expressions are combined with AND logic. However, you
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-apis-spanner_v1
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.23.0
4
+ version: 0.26.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-02-07 00:00:00.000000000 Z
11
+ date: 2022-04-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-apis-core
@@ -58,7 +58,7 @@ licenses:
58
58
  metadata:
59
59
  bug_tracker_uri: https://github.com/googleapis/google-api-ruby-client/issues
60
60
  changelog_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-spanner_v1/CHANGELOG.md
61
- documentation_uri: https://googleapis.dev/ruby/google-apis-spanner_v1/v0.23.0
61
+ documentation_uri: https://googleapis.dev/ruby/google-apis-spanner_v1/v0.26.0
62
62
  source_code_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-spanner_v1
63
63
  post_install_message:
64
64
  rdoc_options: []