google-cloud-asset-v1 0.20.1 → 0.21.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: c06b554d19850b8923937a7b76e2713fd41c855d0c7e85737930564c668b5784
4
- data.tar.gz: 87deccb72bb8eeeabc00feb919f455a27a171af2e31e745fa997ecb201b81222
3
+ metadata.gz: 3707e5c254ca43502c0169aaf0948734bc5d801fdb0754abbec34f17787cb5c3
4
+ data.tar.gz: 7e404e7cbcdb10c94c7f62321eaf88fcee4745fbbc330a345861d94126e76241
5
5
  SHA512:
6
- metadata.gz: 35e758724c4667474c013a2484300d790ee0b15ca24577781f7c0d126bb63d0eaa818d5fae2b0d64ca70c3fa47ad54e754ed22cd8d2efccef402ec61aa4a144b
7
- data.tar.gz: 6047743a05bca031e51615548b83e9416a96b86a397515c60f3d81cb5bb307ccefb9899db2ac1f8857719b9b46d631277d402e418ec3564fdb0e4f47ed851e90
6
+ metadata.gz: f486ec177ea1c1557db69e775bb0ba8cca6f0a0e01a5ceba28b9920fd362a6c040c4c741ec08bd41ddfef3e2cac7e99a61e40d0efffaec531eb0225bf0237557
7
+ data.tar.gz: c6c6c1144eec85735c6345698175eb499677dea87549207d55c5075202067853b6f60b4031950f3911b17f1e9a98ec791c9d35c8f8bafd9160d8822c940b56a7
@@ -112,6 +112,11 @@ module Google
112
112
 
113
113
  default_config.rpcs.analyze_iam_policy_longrunning.timeout = 60.0
114
114
 
115
+ default_config.rpcs.query_assets.timeout = 200.0
116
+ default_config.rpcs.query_assets.retry_policy = {
117
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [14]
118
+ }
119
+
115
120
  default_config.rpcs.batch_get_effective_iam_policies.timeout = 300.0
116
121
  default_config.rpcs.batch_get_effective_iam_policies.retry_policy = {
117
122
  initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [14]
@@ -1856,6 +1861,158 @@ module Google
1856
1861
  raise ::Google::Cloud::Error.from_error(e)
1857
1862
  end
1858
1863
 
1864
+ ##
1865
+ # Issue a job that queries assets using a SQL statement compatible with
1866
+ # [BigQuery Standard
1867
+ # SQL](http://cloud/bigquery/docs/reference/standard-sql/enabling-standard-sql).
1868
+ #
1869
+ # If the query execution finishes within timeout and there's no pagination,
1870
+ # the full query results will be returned in the `QueryAssetsResponse`.
1871
+ #
1872
+ # Otherwise, full query results can be obtained by issuing extra requests
1873
+ # with the `job_reference` from the a previous `QueryAssets` call.
1874
+ #
1875
+ # Note, the query result has approximately 10 GB limitation enforced by
1876
+ # BigQuery
1877
+ # https://cloud.google.com/bigquery/docs/best-practices-performance-output,
1878
+ # queries return larger results will result in errors.
1879
+ #
1880
+ # @overload query_assets(request, options = nil)
1881
+ # Pass arguments to `query_assets` via a request object, either of type
1882
+ # {::Google::Cloud::Asset::V1::QueryAssetsRequest} or an equivalent Hash.
1883
+ #
1884
+ # @param request [::Google::Cloud::Asset::V1::QueryAssetsRequest, ::Hash]
1885
+ # A request object representing the call parameters. Required. To specify no
1886
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1887
+ # @param options [::Gapic::CallOptions, ::Hash]
1888
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
1889
+ #
1890
+ # @overload query_assets(parent: nil, statement: nil, job_reference: nil, page_size: nil, page_token: nil, timeout: nil, read_time_window: nil, read_time: nil, output_config: nil)
1891
+ # Pass arguments to `query_assets` via keyword arguments. Note that at
1892
+ # least one keyword argument is required. To specify no parameters, or to keep all
1893
+ # the default parameter values, pass an empty Hash as a request object (see above).
1894
+ #
1895
+ # @param parent [::String]
1896
+ # Required. The relative name of the root asset. This can only be an
1897
+ # organization number (such as "organizations/123"), a project ID (such as
1898
+ # "projects/my-project-id"), or a project number (such as "projects/12345"),
1899
+ # or a folder number (such as "folders/123").
1900
+ #
1901
+ # Only assets belonging to the `parent` will be returned.
1902
+ # @param statement [::String]
1903
+ # Optional. A SQL statement that's compatible with [BigQuery Standard
1904
+ # SQL](http://cloud/bigquery/docs/reference/standard-sql/enabling-standard-sql).
1905
+ # @param job_reference [::String]
1906
+ # Optional. Reference to the query job, which is from the
1907
+ # `QueryAssetsResponse` of previous `QueryAssets` call.
1908
+ # @param page_size [::Integer]
1909
+ # Optional. The maximum number of rows to return in the results. Responses
1910
+ # are limited to 10 MB and 1000 rows.
1911
+ #
1912
+ # By default, the maximum row count is 1000. When the byte or row count limit
1913
+ # is reached, the rest of the query results will be paginated.
1914
+ #
1915
+ # The field will be ignored when [output_config] is specified.
1916
+ # @param page_token [::String]
1917
+ # Optional. A page token received from previous `QueryAssets`.
1918
+ #
1919
+ # The field will be ignored when [output_config] is specified.
1920
+ # @param timeout [::Google::Protobuf::Duration, ::Hash]
1921
+ # Optional. Specifies the maximum amount of time that the client is willing
1922
+ # to wait for the query to complete. By default, this limit is 5 min for the
1923
+ # first query, and 1 minute for the following queries. If the query is
1924
+ # complete, the `done` field in the `QueryAssetsResponse` is true, otherwise
1925
+ # false.
1926
+ #
1927
+ # Like BigQuery [jobs.query
1928
+ # API](https://cloud.google.com/bigquery/docs/reference/rest/v2/jobs/query#queryrequest)
1929
+ # The call is not guaranteed to wait for the specified timeout; it typically
1930
+ # returns after around 200 seconds (200,000 milliseconds), even if the query
1931
+ # is not complete.
1932
+ #
1933
+ # The field will be ignored when [output_config] is specified.
1934
+ # @param read_time_window [::Google::Cloud::Asset::V1::TimeWindow, ::Hash]
1935
+ # Optional. [start_time] is required. [start_time] must be less than
1936
+ # [end_time] Defaults [end_time] to now if [start_time] is set and
1937
+ # [end_time] isn't. Maximum permitted time range is 7 days.
1938
+ # @param read_time [::Google::Protobuf::Timestamp, ::Hash]
1939
+ # Optional. Queries cloud assets as they appeared at the specified point in
1940
+ # time.
1941
+ # @param output_config [::Google::Cloud::Asset::V1::QueryAssetsOutputConfig, ::Hash]
1942
+ # Optional. Destination where the query results will be saved.
1943
+ #
1944
+ # When this field is specified, the query results won't be saved in the
1945
+ # [QueryAssetsResponse.query_result]. Instead
1946
+ # [QueryAssetsResponse.output_config] will be set.
1947
+ #
1948
+ # Meanwhile, [QueryAssetsResponse.job_reference] will be set and can be used
1949
+ # to check the status of the query job when passed to a following
1950
+ # [QueryAssets] API call.
1951
+ #
1952
+ # @yield [response, operation] Access the result along with the RPC operation
1953
+ # @yieldparam response [::Google::Cloud::Asset::V1::QueryAssetsResponse]
1954
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
1955
+ #
1956
+ # @return [::Google::Cloud::Asset::V1::QueryAssetsResponse]
1957
+ #
1958
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
1959
+ #
1960
+ # @example Basic example
1961
+ # require "google/cloud/asset/v1"
1962
+ #
1963
+ # # Create a client object. The client can be reused for multiple calls.
1964
+ # client = Google::Cloud::Asset::V1::AssetService::Client.new
1965
+ #
1966
+ # # Create a request. To set request fields, pass in keyword arguments.
1967
+ # request = Google::Cloud::Asset::V1::QueryAssetsRequest.new
1968
+ #
1969
+ # # Call the query_assets method.
1970
+ # result = client.query_assets request
1971
+ #
1972
+ # # The returned object is of type Google::Cloud::Asset::V1::QueryAssetsResponse.
1973
+ # p result
1974
+ #
1975
+ def query_assets request, options = nil
1976
+ raise ::ArgumentError, "request must be provided" if request.nil?
1977
+
1978
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Asset::V1::QueryAssetsRequest
1979
+
1980
+ # Converts hash and nil to an options object
1981
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1982
+
1983
+ # Customize the options with defaults
1984
+ metadata = @config.rpcs.query_assets.metadata.to_h
1985
+
1986
+ # Set x-goog-api-client and x-goog-user-project headers
1987
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1988
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1989
+ gapic_version: ::Google::Cloud::Asset::V1::VERSION
1990
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1991
+
1992
+ header_params = {}
1993
+ if request.parent
1994
+ header_params["parent"] = request.parent
1995
+ end
1996
+
1997
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
1998
+ metadata[:"x-goog-request-params"] ||= request_params_header
1999
+
2000
+ options.apply_defaults timeout: @config.rpcs.query_assets.timeout,
2001
+ metadata: metadata,
2002
+ retry_policy: @config.rpcs.query_assets.retry_policy
2003
+
2004
+ options.apply_defaults timeout: @config.timeout,
2005
+ metadata: @config.metadata,
2006
+ retry_policy: @config.retry_policy
2007
+
2008
+ @asset_service_stub.call_rpc :query_assets, request, options: options do |response, operation|
2009
+ yield response, operation if block_given?
2010
+ return response
2011
+ end
2012
+ rescue ::GRPC::BadStatus => e
2013
+ raise ::Google::Cloud::Error.from_error(e)
2014
+ end
2015
+
1859
2016
  ##
1860
2017
  # Creates a saved query in a parent project/folder/organization.
1861
2018
  #
@@ -2646,6 +2803,11 @@ module Google
2646
2803
  #
2647
2804
  attr_reader :analyze_move
2648
2805
  ##
2806
+ # RPC-specific configuration for `query_assets`
2807
+ # @return [::Gapic::Config::Method]
2808
+ #
2809
+ attr_reader :query_assets
2810
+ ##
2649
2811
  # RPC-specific configuration for `create_saved_query`
2650
2812
  # @return [::Gapic::Config::Method]
2651
2813
  #
@@ -2704,6 +2866,8 @@ module Google
2704
2866
  @analyze_iam_policy_longrunning = ::Gapic::Config::Method.new analyze_iam_policy_longrunning_config
2705
2867
  analyze_move_config = parent_rpcs.analyze_move if parent_rpcs.respond_to? :analyze_move
2706
2868
  @analyze_move = ::Gapic::Config::Method.new analyze_move_config
2869
+ query_assets_config = parent_rpcs.query_assets if parent_rpcs.respond_to? :query_assets
2870
+ @query_assets = ::Gapic::Config::Method.new query_assets_config
2707
2871
  create_saved_query_config = parent_rpcs.create_saved_query if parent_rpcs.respond_to? :create_saved_query
2708
2872
  @create_saved_query = ::Gapic::Config::Method.new create_saved_query_config
2709
2873
  get_saved_query_config = parent_rpcs.get_saved_query if parent_rpcs.respond_to? :get_saved_query
@@ -13,6 +13,7 @@ require 'google/longrunning/operations_pb'
13
13
  require 'google/protobuf/duration_pb'
14
14
  require 'google/protobuf/empty_pb'
15
15
  require 'google/protobuf/field_mask_pb'
16
+ require 'google/protobuf/struct_pb'
16
17
  require 'google/protobuf/timestamp_pb'
17
18
  require 'google/rpc/status_pb'
18
19
  require 'google/type/expr_pb'
@@ -297,6 +298,53 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
297
298
  add_message "google.cloud.asset.v1.MoveImpact" do
298
299
  optional :detail, :string, 1
299
300
  end
301
+ add_message "google.cloud.asset.v1.QueryAssetsOutputConfig" do
302
+ optional :bigquery_destination, :message, 1, "google.cloud.asset.v1.QueryAssetsOutputConfig.BigQueryDestination"
303
+ end
304
+ add_message "google.cloud.asset.v1.QueryAssetsOutputConfig.BigQueryDestination" do
305
+ optional :dataset, :string, 1
306
+ optional :table, :string, 2
307
+ optional :write_disposition, :string, 3
308
+ end
309
+ add_message "google.cloud.asset.v1.QueryAssetsRequest" do
310
+ optional :parent, :string, 1
311
+ optional :page_size, :int32, 4
312
+ optional :page_token, :string, 5
313
+ optional :timeout, :message, 6, "google.protobuf.Duration"
314
+ optional :output_config, :message, 9, "google.cloud.asset.v1.QueryAssetsOutputConfig"
315
+ oneof :query do
316
+ optional :statement, :string, 2
317
+ optional :job_reference, :string, 3
318
+ end
319
+ oneof :time do
320
+ optional :read_time_window, :message, 7, "google.cloud.asset.v1.TimeWindow"
321
+ optional :read_time, :message, 8, "google.protobuf.Timestamp"
322
+ end
323
+ end
324
+ add_message "google.cloud.asset.v1.QueryAssetsResponse" do
325
+ optional :job_reference, :string, 1
326
+ optional :done, :bool, 2
327
+ oneof :response do
328
+ optional :error, :message, 3, "google.rpc.Status"
329
+ optional :query_result, :message, 4, "google.cloud.asset.v1.QueryResult"
330
+ optional :output_config, :message, 5, "google.cloud.asset.v1.QueryAssetsOutputConfig"
331
+ end
332
+ end
333
+ add_message "google.cloud.asset.v1.QueryResult" do
334
+ repeated :rows, :message, 1, "google.protobuf.Struct"
335
+ optional :schema, :message, 2, "google.cloud.asset.v1.TableSchema"
336
+ optional :next_page_token, :string, 3
337
+ optional :total_rows, :int64, 4
338
+ end
339
+ add_message "google.cloud.asset.v1.TableSchema" do
340
+ repeated :fields, :message, 1, "google.cloud.asset.v1.TableFieldSchema"
341
+ end
342
+ add_message "google.cloud.asset.v1.TableFieldSchema" do
343
+ optional :field, :string, 1
344
+ optional :type, :string, 2
345
+ optional :mode, :string, 3
346
+ repeated :fields, :message, 4, "google.cloud.asset.v1.TableFieldSchema"
347
+ end
300
348
  add_message "google.cloud.asset.v1.BatchGetEffectiveIamPoliciesRequest" do
301
349
  optional :scope, :string, 1
302
350
  repeated :names, :string, 3
@@ -384,6 +432,13 @@ module Google
384
432
  MoveAnalysis = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.MoveAnalysis").msgclass
385
433
  MoveAnalysisResult = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.MoveAnalysisResult").msgclass
386
434
  MoveImpact = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.MoveImpact").msgclass
435
+ QueryAssetsOutputConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.QueryAssetsOutputConfig").msgclass
436
+ QueryAssetsOutputConfig::BigQueryDestination = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.QueryAssetsOutputConfig.BigQueryDestination").msgclass
437
+ QueryAssetsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.QueryAssetsRequest").msgclass
438
+ QueryAssetsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.QueryAssetsResponse").msgclass
439
+ QueryResult = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.QueryResult").msgclass
440
+ TableSchema = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.TableSchema").msgclass
441
+ TableFieldSchema = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.TableFieldSchema").msgclass
387
442
  BatchGetEffectiveIamPoliciesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.BatchGetEffectiveIamPoliciesRequest").msgclass
388
443
  BatchGetEffectiveIamPoliciesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.BatchGetEffectiveIamPoliciesResponse").msgclass
389
444
  BatchGetEffectiveIamPoliciesResponse::EffectiveIamPolicy = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.asset.v1.BatchGetEffectiveIamPoliciesResponse.EffectiveIamPolicy").msgclass
@@ -97,6 +97,21 @@ module Google
97
97
  # The policies and configuration are subject to change before the actual
98
98
  # resource migration takes place.
99
99
  rpc :AnalyzeMove, ::Google::Cloud::Asset::V1::AnalyzeMoveRequest, ::Google::Cloud::Asset::V1::AnalyzeMoveResponse
100
+ # Issue a job that queries assets using a SQL statement compatible with
101
+ # [BigQuery Standard
102
+ # SQL](http://cloud/bigquery/docs/reference/standard-sql/enabling-standard-sql).
103
+ #
104
+ # If the query execution finishes within timeout and there's no pagination,
105
+ # the full query results will be returned in the `QueryAssetsResponse`.
106
+ #
107
+ # Otherwise, full query results can be obtained by issuing extra requests
108
+ # with the `job_reference` from the a previous `QueryAssets` call.
109
+ #
110
+ # Note, the query result has approximately 10 GB limitation enforced by
111
+ # BigQuery
112
+ # https://cloud.google.com/bigquery/docs/best-practices-performance-output,
113
+ # queries return larger results will result in errors.
114
+ rpc :QueryAssets, ::Google::Cloud::Asset::V1::QueryAssetsRequest, ::Google::Cloud::Asset::V1::QueryAssetsResponse
100
115
  # Creates a saved query in a parent project/folder/organization.
101
116
  rpc :CreateSavedQuery, ::Google::Cloud::Asset::V1::CreateSavedQueryRequest, ::Google::Cloud::Asset::V1::SavedQuery
102
117
  # Gets details about a saved query.
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module Asset
23
23
  module V1
24
- VERSION = "0.20.1"
24
+ VERSION = "0.21.0"
25
25
  end
26
26
  end
27
27
  end
@@ -1583,6 +1583,206 @@ module Google
1583
1583
  extend ::Google::Protobuf::MessageExts::ClassMethods
1584
1584
  end
1585
1585
 
1586
+ # Output configuration query assets.
1587
+ # @!attribute [rw] bigquery_destination
1588
+ # @return [::Google::Cloud::Asset::V1::QueryAssetsOutputConfig::BigQueryDestination]
1589
+ # BigQuery destination where the query results will be saved.
1590
+ class QueryAssetsOutputConfig
1591
+ include ::Google::Protobuf::MessageExts
1592
+ extend ::Google::Protobuf::MessageExts::ClassMethods
1593
+
1594
+ # BigQuery destination.
1595
+ # @!attribute [rw] dataset
1596
+ # @return [::String]
1597
+ # Required. The BigQuery dataset where the query results will be saved. It
1598
+ # has the format of "projects/\\{projectId}/datasets/\\{datasetId}".
1599
+ # @!attribute [rw] table
1600
+ # @return [::String]
1601
+ # Required. The BigQuery table where the query results will be saved. If
1602
+ # this table does not exist, a new table with the given name will be
1603
+ # created.
1604
+ # @!attribute [rw] write_disposition
1605
+ # @return [::String]
1606
+ # Specifies the action that occurs if the destination table or partition
1607
+ # already exists. The following values are supported:
1608
+ #
1609
+ # * WRITE_TRUNCATE: If the table or partition already exists, BigQuery
1610
+ # overwrites the entire table or all the partitions data.
1611
+ # * WRITE_APPEND: If the table or partition already exists, BigQuery
1612
+ # appends the data to the table or the latest partition.
1613
+ # * WRITE_EMPTY: If the table already exists and contains data, an error is
1614
+ # returned.
1615
+ class BigQueryDestination
1616
+ include ::Google::Protobuf::MessageExts
1617
+ extend ::Google::Protobuf::MessageExts::ClassMethods
1618
+ end
1619
+ end
1620
+
1621
+ # QueryAssets request.
1622
+ # @!attribute [rw] parent
1623
+ # @return [::String]
1624
+ # Required. The relative name of the root asset. This can only be an
1625
+ # organization number (such as "organizations/123"), a project ID (such as
1626
+ # "projects/my-project-id"), or a project number (such as "projects/12345"),
1627
+ # or a folder number (such as "folders/123").
1628
+ #
1629
+ # Only assets belonging to the `parent` will be returned.
1630
+ # @!attribute [rw] statement
1631
+ # @return [::String]
1632
+ # Optional. A SQL statement that's compatible with [BigQuery Standard
1633
+ # SQL](http://cloud/bigquery/docs/reference/standard-sql/enabling-standard-sql).
1634
+ # @!attribute [rw] job_reference
1635
+ # @return [::String]
1636
+ # Optional. Reference to the query job, which is from the
1637
+ # `QueryAssetsResponse` of previous `QueryAssets` call.
1638
+ # @!attribute [rw] page_size
1639
+ # @return [::Integer]
1640
+ # Optional. The maximum number of rows to return in the results. Responses
1641
+ # are limited to 10 MB and 1000 rows.
1642
+ #
1643
+ # By default, the maximum row count is 1000. When the byte or row count limit
1644
+ # is reached, the rest of the query results will be paginated.
1645
+ #
1646
+ # The field will be ignored when [output_config] is specified.
1647
+ # @!attribute [rw] page_token
1648
+ # @return [::String]
1649
+ # Optional. A page token received from previous `QueryAssets`.
1650
+ #
1651
+ # The field will be ignored when [output_config] is specified.
1652
+ # @!attribute [rw] timeout
1653
+ # @return [::Google::Protobuf::Duration]
1654
+ # Optional. Specifies the maximum amount of time that the client is willing
1655
+ # to wait for the query to complete. By default, this limit is 5 min for the
1656
+ # first query, and 1 minute for the following queries. If the query is
1657
+ # complete, the `done` field in the `QueryAssetsResponse` is true, otherwise
1658
+ # false.
1659
+ #
1660
+ # Like BigQuery [jobs.query
1661
+ # API](https://cloud.google.com/bigquery/docs/reference/rest/v2/jobs/query#queryrequest)
1662
+ # The call is not guaranteed to wait for the specified timeout; it typically
1663
+ # returns after around 200 seconds (200,000 milliseconds), even if the query
1664
+ # is not complete.
1665
+ #
1666
+ # The field will be ignored when [output_config] is specified.
1667
+ # @!attribute [rw] read_time_window
1668
+ # @return [::Google::Cloud::Asset::V1::TimeWindow]
1669
+ # Optional. [start_time] is required. [start_time] must be less than
1670
+ # [end_time] Defaults [end_time] to now if [start_time] is set and
1671
+ # [end_time] isn't. Maximum permitted time range is 7 days.
1672
+ # @!attribute [rw] read_time
1673
+ # @return [::Google::Protobuf::Timestamp]
1674
+ # Optional. Queries cloud assets as they appeared at the specified point in
1675
+ # time.
1676
+ # @!attribute [rw] output_config
1677
+ # @return [::Google::Cloud::Asset::V1::QueryAssetsOutputConfig]
1678
+ # Optional. Destination where the query results will be saved.
1679
+ #
1680
+ # When this field is specified, the query results won't be saved in the
1681
+ # [QueryAssetsResponse.query_result]. Instead
1682
+ # [QueryAssetsResponse.output_config] will be set.
1683
+ #
1684
+ # Meanwhile, [QueryAssetsResponse.job_reference] will be set and can be used
1685
+ # to check the status of the query job when passed to a following
1686
+ # [QueryAssets] API call.
1687
+ class QueryAssetsRequest
1688
+ include ::Google::Protobuf::MessageExts
1689
+ extend ::Google::Protobuf::MessageExts::ClassMethods
1690
+ end
1691
+
1692
+ # QueryAssets response.
1693
+ # @!attribute [rw] job_reference
1694
+ # @return [::String]
1695
+ # Reference to a query job.
1696
+ # @!attribute [rw] done
1697
+ # @return [::Boolean]
1698
+ # The query response, which can be either an `error` or a valid `response`.
1699
+ #
1700
+ # If `done` == `false` and the query result is being saved in a output, the
1701
+ # output_config field will be set.
1702
+ # If `done` == `true`, exactly one of
1703
+ # `error`, `query_result` or `output_config` will be set.
1704
+ # @!attribute [rw] error
1705
+ # @return [::Google::Rpc::Status]
1706
+ # Error status.
1707
+ # @!attribute [rw] query_result
1708
+ # @return [::Google::Cloud::Asset::V1::QueryResult]
1709
+ # Result of the query.
1710
+ # @!attribute [rw] output_config
1711
+ # @return [::Google::Cloud::Asset::V1::QueryAssetsOutputConfig]
1712
+ # Output configuration which indicates instead of being returned in API
1713
+ # response on the fly, the query result will be saved in a specific output.
1714
+ class QueryAssetsResponse
1715
+ include ::Google::Protobuf::MessageExts
1716
+ extend ::Google::Protobuf::MessageExts::ClassMethods
1717
+ end
1718
+
1719
+ # Execution results of the query.
1720
+ #
1721
+ # The result is formatted as rows represented by BigQuery compatible [schema].
1722
+ # When pagination is necessary, it will contains the page token to retrieve
1723
+ # the results of following pages.
1724
+ # @!attribute [rw] rows
1725
+ # @return [::Array<::Google::Protobuf::Struct>]
1726
+ # Each row hold a query result in the format of `Struct`.
1727
+ # @!attribute [rw] schema
1728
+ # @return [::Google::Cloud::Asset::V1::TableSchema]
1729
+ # Describes the format of the [rows].
1730
+ # @!attribute [rw] next_page_token
1731
+ # @return [::String]
1732
+ # Token to retrieve the next page of the results.
1733
+ # @!attribute [rw] total_rows
1734
+ # @return [::Integer]
1735
+ # Total rows of the whole query results.
1736
+ class QueryResult
1737
+ include ::Google::Protobuf::MessageExts
1738
+ extend ::Google::Protobuf::MessageExts::ClassMethods
1739
+ end
1740
+
1741
+ # BigQuery Compatible table schema.
1742
+ # @!attribute [rw] fields
1743
+ # @return [::Array<::Google::Cloud::Asset::V1::TableFieldSchema>]
1744
+ # Describes the fields in a table.
1745
+ class TableSchema
1746
+ include ::Google::Protobuf::MessageExts
1747
+ extend ::Google::Protobuf::MessageExts::ClassMethods
1748
+ end
1749
+
1750
+ # A field in TableSchema.
1751
+ # @!attribute [rw] field
1752
+ # @return [::String]
1753
+ # The field name. The name must contain only letters (a-z, A-Z),
1754
+ # numbers (0-9), or underscores (_), and must start with a letter or
1755
+ # underscore. The maximum length is 128 characters.
1756
+ # @!attribute [rw] type
1757
+ # @return [::String]
1758
+ # The field data type. Possible values include
1759
+ # * STRING
1760
+ # * BYTES
1761
+ # * INTEGER
1762
+ # * FLOAT
1763
+ # * BOOLEAN
1764
+ # * TIMESTAMP
1765
+ # * DATE
1766
+ # * TIME
1767
+ # * DATETIME
1768
+ # * GEOGRAPHY,
1769
+ # * NUMERIC,
1770
+ # * BIGNUMERIC,
1771
+ # * RECORD
1772
+ # (where RECORD indicates that the field contains a nested schema).
1773
+ # @!attribute [rw] mode
1774
+ # @return [::String]
1775
+ # The field mode. Possible values include NULLABLE, REQUIRED and
1776
+ # REPEATED. The default value is NULLABLE.
1777
+ # @!attribute [rw] fields
1778
+ # @return [::Array<::Google::Cloud::Asset::V1::TableFieldSchema>]
1779
+ # Describes the nested schema fields if the type property is set
1780
+ # to RECORD.
1781
+ class TableFieldSchema
1782
+ include ::Google::Protobuf::MessageExts
1783
+ extend ::Google::Protobuf::MessageExts::ClassMethods
1784
+ end
1785
+
1586
1786
  # A request message for
1587
1787
  # {::Google::Cloud::Asset::V1::AssetService::Client#batch_get_effective_iam_policies AssetService.BatchGetEffectiveIamPolicies}.
1588
1788
  # @!attribute [rw] scope
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-asset-v1
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.20.1
4
+ version: 0.21.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-08-15 00:00:00.000000000 Z
11
+ date: 2022-08-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gapic-common