google-apis-cloudasset_v1 0.7.0 → 0.8.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 29b2fb0fff69b8ef5b76dc3a6ade6c0c49ca8779d6e191738232eb56feba6ec2
4
- data.tar.gz: 613c440f2f00a9f061523c9ab1ab0b11d4988cb2a1252e7e63bab43c4074c3ea
3
+ metadata.gz: 450f9a28366fecd8b3eaaef7a700e380a0aa4b68a378c1c6c2576f741be3487d
4
+ data.tar.gz: 709ebd03deafa5a6393e41ad30df6c4d3296b0cccab8d76a6a67f3ec70bd8962
5
5
  SHA512:
6
- metadata.gz: 35446a89ac501a688bae7c75819a94bd60ad7f5e4ff36c790cf442d955e386ab59ee2d8a752a8cfd1e5baa371644e6145d87b143d5d2d4c916578325376b62a1
7
- data.tar.gz: 586b19cd1f9b1af34a1b491a3e4c9981018fa11f82c1231ec54f7167de554abe366464f05647e35a28680857a3cdc3906f24a26eb6fd96c47ffa8e6db2433869
6
+ metadata.gz: 524b7f5de245377fcbcf8a585a1b4eaf9efc9e8e8b84d8f1a702d8d7ba34a1d0f19b6149265c266ce80221ef9a8b68f367518f41c8d7997847e474774d94c179
7
+ data.tar.gz: 61889f0d53670fd0d7493fdfe80a795b206f86293b158fb94b5441c3aff1a3845532b54976fc712bc68275fc2d5afcb8d4a9824db65e0843fb11ffbb1aaceb91
data/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Release history for google-apis-cloudasset_v1
2
2
 
3
+ ### v0.8.0 (2021-05-20)
4
+
5
+ * Regenerated from discovery document revision 20210518
6
+ * Unspecified changes
7
+
3
8
  ### v0.7.0 (2021-05-12)
4
9
 
5
10
  * Regenerated from discovery document revision 20210507
@@ -123,6 +123,26 @@ module Google
123
123
  end
124
124
  end
125
125
 
126
+ # The response message for resource move analysis.
127
+ class AnalyzeMoveResponse
128
+ include Google::Apis::Core::Hashable
129
+
130
+ # The list of analyses returned from performing the intended resource move
131
+ # analysis. The analysis is grouped by different Cloud services.
132
+ # Corresponds to the JSON property `moveAnalysis`
133
+ # @return [Array<Google::Apis::CloudassetV1::MoveAnalysis>]
134
+ attr_accessor :move_analysis
135
+
136
+ def initialize(**args)
137
+ update!(**args)
138
+ end
139
+
140
+ # Update properties of this object
141
+ def update!(**args)
142
+ @move_analysis = args[:move_analysis] if args.key?(:move_analysis)
143
+ end
144
+ end
145
+
126
146
  # An asset in Google Cloud. An asset can be any resource in the Google Cloud [
127
147
  # resource hierarchy](https://cloud.google.com/resource-manager/docs/cloud-
128
148
  # platform-resource-hierarchy), a resource outside the Google Cloud resource
@@ -2985,6 +3005,90 @@ module Google
2985
3005
  end
2986
3006
  end
2987
3007
 
3008
+ # A message to group the analysis information.
3009
+ class MoveAnalysis
3010
+ include Google::Apis::Core::Hashable
3011
+
3012
+ # An analysis result including blockers and warnings.
3013
+ # Corresponds to the JSON property `analysis`
3014
+ # @return [Google::Apis::CloudassetV1::MoveAnalysisResult]
3015
+ attr_accessor :analysis
3016
+
3017
+ # The user friendly display name of the analysis. E.g. IAM, Organization Policy
3018
+ # etc.
3019
+ # Corresponds to the JSON property `displayName`
3020
+ # @return [String]
3021
+ attr_accessor :display_name
3022
+
3023
+ # The `Status` type defines a logical error model that is suitable for different
3024
+ # programming environments, including REST APIs and RPC APIs. It is used by [
3025
+ # gRPC](https://github.com/grpc). Each `Status` message contains three pieces of
3026
+ # data: error code, error message, and error details. You can find out more
3027
+ # about this error model and how to work with it in the [API Design Guide](https:
3028
+ # //cloud.google.com/apis/design/errors).
3029
+ # Corresponds to the JSON property `error`
3030
+ # @return [Google::Apis::CloudassetV1::Status]
3031
+ attr_accessor :error
3032
+
3033
+ def initialize(**args)
3034
+ update!(**args)
3035
+ end
3036
+
3037
+ # Update properties of this object
3038
+ def update!(**args)
3039
+ @analysis = args[:analysis] if args.key?(:analysis)
3040
+ @display_name = args[:display_name] if args.key?(:display_name)
3041
+ @error = args[:error] if args.key?(:error)
3042
+ end
3043
+ end
3044
+
3045
+ # An analysis result including blockers and warnings.
3046
+ class MoveAnalysisResult
3047
+ include Google::Apis::Core::Hashable
3048
+
3049
+ # Blocking information that would prevent the target resource from moving to the
3050
+ # specified destination at runtime.
3051
+ # Corresponds to the JSON property `blockers`
3052
+ # @return [Array<Google::Apis::CloudassetV1::MoveImpact>]
3053
+ attr_accessor :blockers
3054
+
3055
+ # Warning information indicating that moving the target resource to the
3056
+ # specified destination might be unsafe. This can include important policy
3057
+ # information and configuration changes, but will not block moves at runtime.
3058
+ # Corresponds to the JSON property `warnings`
3059
+ # @return [Array<Google::Apis::CloudassetV1::MoveImpact>]
3060
+ attr_accessor :warnings
3061
+
3062
+ def initialize(**args)
3063
+ update!(**args)
3064
+ end
3065
+
3066
+ # Update properties of this object
3067
+ def update!(**args)
3068
+ @blockers = args[:blockers] if args.key?(:blockers)
3069
+ @warnings = args[:warnings] if args.key?(:warnings)
3070
+ end
3071
+ end
3072
+
3073
+ # A message to group impacts of moving the target resource.
3074
+ class MoveImpact
3075
+ include Google::Apis::Core::Hashable
3076
+
3077
+ # User friendly impact detail in a free form message.
3078
+ # Corresponds to the JSON property `detail`
3079
+ # @return [String]
3080
+ attr_accessor :detail
3081
+
3082
+ def initialize(**args)
3083
+ update!(**args)
3084
+ end
3085
+
3086
+ # Update properties of this object
3087
+ def update!(**args)
3088
+ @detail = args[:detail] if args.key?(:detail)
3089
+ end
3090
+ end
3091
+
2988
3092
  # This resource represents a long-running operation that is the result of a
2989
3093
  # network API call.
2990
3094
  class Operation
@@ -16,13 +16,13 @@ module Google
16
16
  module Apis
17
17
  module CloudassetV1
18
18
  # Version of the google-apis-cloudasset_v1 gem
19
- GEM_VERSION = "0.7.0"
19
+ GEM_VERSION = "0.8.0"
20
20
 
21
21
  # Version of the code generator used to generate this client
22
22
  GENERATOR_VERSION = "0.2.0"
23
23
 
24
24
  # Revision of the discovery document this client was generated from
25
- REVISION = "20210507"
25
+ REVISION = "20210518"
26
26
  end
27
27
  end
28
28
  end
@@ -46,6 +46,12 @@ module Google
46
46
  include Google::Apis::Core::JsonObjectSupport
47
47
  end
48
48
 
49
+ class AnalyzeMoveResponse
50
+ class Representation < Google::Apis::Core::JsonRepresentation; end
51
+
52
+ include Google::Apis::Core::JsonObjectSupport
53
+ end
54
+
49
55
  class Asset
50
56
  class Representation < Google::Apis::Core::JsonRepresentation; end
51
57
 
@@ -424,6 +430,24 @@ module Google
424
430
  include Google::Apis::Core::JsonObjectSupport
425
431
  end
426
432
 
433
+ class MoveAnalysis
434
+ class Representation < Google::Apis::Core::JsonRepresentation; end
435
+
436
+ include Google::Apis::Core::JsonObjectSupport
437
+ end
438
+
439
+ class MoveAnalysisResult
440
+ class Representation < Google::Apis::Core::JsonRepresentation; end
441
+
442
+ include Google::Apis::Core::JsonObjectSupport
443
+ end
444
+
445
+ class MoveImpact
446
+ class Representation < Google::Apis::Core::JsonRepresentation; end
447
+
448
+ include Google::Apis::Core::JsonObjectSupport
449
+ end
450
+
427
451
  class Operation
428
452
  class Representation < Google::Apis::Core::JsonRepresentation; end
429
453
 
@@ -597,6 +621,14 @@ module Google
597
621
  end
598
622
  end
599
623
 
624
+ class AnalyzeMoveResponse
625
+ # @private
626
+ class Representation < Google::Apis::Core::JsonRepresentation
627
+ collection :move_analysis, as: 'moveAnalysis', class: Google::Apis::CloudassetV1::MoveAnalysis, decorator: Google::Apis::CloudassetV1::MoveAnalysis::Representation
628
+
629
+ end
630
+ end
631
+
600
632
  class Asset
601
633
  # @private
602
634
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -1257,6 +1289,34 @@ module Google
1257
1289
  end
1258
1290
  end
1259
1291
 
1292
+ class MoveAnalysis
1293
+ # @private
1294
+ class Representation < Google::Apis::Core::JsonRepresentation
1295
+ property :analysis, as: 'analysis', class: Google::Apis::CloudassetV1::MoveAnalysisResult, decorator: Google::Apis::CloudassetV1::MoveAnalysisResult::Representation
1296
+
1297
+ property :display_name, as: 'displayName'
1298
+ property :error, as: 'error', class: Google::Apis::CloudassetV1::Status, decorator: Google::Apis::CloudassetV1::Status::Representation
1299
+
1300
+ end
1301
+ end
1302
+
1303
+ class MoveAnalysisResult
1304
+ # @private
1305
+ class Representation < Google::Apis::Core::JsonRepresentation
1306
+ collection :blockers, as: 'blockers', class: Google::Apis::CloudassetV1::MoveImpact, decorator: Google::Apis::CloudassetV1::MoveImpact::Representation
1307
+
1308
+ collection :warnings, as: 'warnings', class: Google::Apis::CloudassetV1::MoveImpact, decorator: Google::Apis::CloudassetV1::MoveImpact::Representation
1309
+
1310
+ end
1311
+ end
1312
+
1313
+ class MoveImpact
1314
+ # @private
1315
+ class Representation < Google::Apis::Core::JsonRepresentation
1316
+ property :detail, as: 'detail'
1317
+ end
1318
+ end
1319
+
1260
1320
  class Operation
1261
1321
  # @private
1262
1322
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -54,7 +54,7 @@ module Google
54
54
  # @param [String] parent
55
55
  # Required. Name of the organization or project the assets belong to. Format: "
56
56
  # organizations/[organization-number]" (such as "organizations/123"), "projects/[
57
- # project-number]" (such as "projects/my-project-id"), or "projects/[project-id]"
57
+ # project-id]" (such as "projects/my-project-id"), or "projects/[project-number]"
58
58
  # (such as "projects/12345").
59
59
  # @param [Array<String>, String] asset_types
60
60
  # A list of asset types to take a snapshot for. For example: "compute.googleapis.
@@ -493,6 +493,53 @@ module Google
493
493
  execute_or_queue_command(command, &block)
494
494
  end
495
495
 
496
+ # Analyze moving a resource to a specified destination without kicking off the
497
+ # actual move. The analysis is best effort depending on the user's permissions
498
+ # of viewing different hierarchical policies and configurations. The policies
499
+ # and configuration are subject to change before the actual resource migration
500
+ # takes place.
501
+ # @param [String] resource
502
+ # Required. Name of the resource to perform the analysis against. Only GCP
503
+ # Project are supported as of today. Hence, this can only be Project ID (such as
504
+ # "projects/my-project-id") or a Project Number (such as "projects/12345").
505
+ # @param [String] destination_parent
506
+ # Required. Name of the GCP Folder or Organization to reparent the target
507
+ # resource. The analysis will be performed against hypothetically moving the
508
+ # resource to this specified desitination parent. This can only be a Folder
509
+ # number (such as "folders/123") or an Organization number (such as "
510
+ # organizations/123").
511
+ # @param [String] view
512
+ # Analysis view indicating what information should be included in the analysis
513
+ # response. If unspecified, the default view is FULL.
514
+ # @param [String] fields
515
+ # Selector specifying which fields to include in a partial response.
516
+ # @param [String] quota_user
517
+ # Available to use for quota purposes for server-side applications. Can be any
518
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
519
+ # @param [Google::Apis::RequestOptions] options
520
+ # Request-specific options
521
+ #
522
+ # @yield [result, err] Result & error if block supplied
523
+ # @yieldparam result [Google::Apis::CloudassetV1::AnalyzeMoveResponse] parsed result object
524
+ # @yieldparam err [StandardError] error object if request failed
525
+ #
526
+ # @return [Google::Apis::CloudassetV1::AnalyzeMoveResponse]
527
+ #
528
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
529
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
530
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
531
+ def analyze_move(resource, destination_parent: nil, view: nil, fields: nil, quota_user: nil, options: nil, &block)
532
+ command = make_simple_command(:get, 'v1/{+resource}:analyzeMove', options)
533
+ command.response_representation = Google::Apis::CloudassetV1::AnalyzeMoveResponse::Representation
534
+ command.response_class = Google::Apis::CloudassetV1::AnalyzeMoveResponse
535
+ command.params['resource'] = resource unless resource.nil?
536
+ command.query['destinationParent'] = destination_parent unless destination_parent.nil?
537
+ command.query['view'] = view unless view.nil?
538
+ command.query['fields'] = fields unless fields.nil?
539
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
540
+ execute_or_queue_command(command, &block)
541
+ end
542
+
496
543
  # Batch gets the update history of assets that overlap a time window. For
497
544
  # IAM_POLICY content, this API outputs history when the asset and its attached
498
545
  # IAM POLICY both exist. This can create gaps in the output history. Otherwise,
@@ -697,13 +744,15 @@ module Google
697
744
  # expression syntax. If the regular expression does not match any supported
698
745
  # asset type, an INVALID_ARGUMENT error will be returned.
699
746
  # @param [String] order_by
700
- # Optional. A comma separated list of fields specifying the sorting order of the
747
+ # Optional. A comma-separated list of fields specifying the sorting order of the
701
748
  # results. The default order is ascending. Add " DESC" after the field name to
702
749
  # indicate descending order. Redundant space characters are ignored. Example: "
703
- # location DESC, name". Only string fields in the response are sortable,
704
- # including `name`, `displayName`, `description`, `location`. All the other
705
- # fields such as repeated fields (e.g., `networkTags`), map fields (e.g., `
706
- # labels`) and struct fields (e.g., `additionalAttributes`) are not supported.
750
+ # location DESC, name". Only singular primitive fields in the response are
751
+ # sortable: * name * assetType * project * displayName * description * location *
752
+ # kmsKey * createTime * updateTime * state * parentFullResourceName *
753
+ # parentAssetType All the other fields such as repeated fields (e.g., `
754
+ # networkTags`), map fields (e.g., `labels`) and struct fields (e.g., `
755
+ # additionalAttributes`) are not supported.
707
756
  # @param [Fixnum] page_size
708
757
  # Optional. The page size for search result pagination. Page size is capped at
709
758
  # 500 even if a larger value is given. If set to zero, server will pick an
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-apis-cloudasset_v1
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0
4
+ version: 0.8.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: 2021-05-18 00:00:00.000000000 Z
11
+ date: 2021-05-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-apis-core
@@ -52,7 +52,7 @@ licenses:
52
52
  metadata:
53
53
  bug_tracker_uri: https://github.com/googleapis/google-api-ruby-client/issues
54
54
  changelog_uri: https://github.com/googleapis/google-api-ruby-client/tree/master/generated/google-apis-cloudasset_v1/CHANGELOG.md
55
- documentation_uri: https://googleapis.dev/ruby/google-apis-cloudasset_v1/v0.7.0
55
+ documentation_uri: https://googleapis.dev/ruby/google-apis-cloudasset_v1/v0.8.0
56
56
  source_code_uri: https://github.com/googleapis/google-api-ruby-client/tree/master/generated/google-apis-cloudasset_v1
57
57
  post_install_message:
58
58
  rdoc_options: []