google-api-client 0.9.8 → 0.9.20

Sign up to get free protection for your applications and to get access to all the features.
Files changed (238) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +37 -0
  3. data/Gemfile +9 -1
  4. data/README.md +10 -2
  5. data/api_names.yaml +63 -110
  6. data/generated/google/apis/adexchangebuyer2_v2beta1.rb +35 -0
  7. data/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb +298 -0
  8. data/generated/google/apis/adexchangebuyer2_v2beta1/representations.rb +122 -0
  9. data/generated/google/apis/adexchangebuyer2_v2beta1/service.rb +458 -0
  10. data/generated/google/apis/adexchangebuyer_v1_4.rb +1 -1
  11. data/generated/google/apis/adexchangebuyer_v1_4/classes.rb +260 -13
  12. data/generated/google/apis/adexchangebuyer_v1_4/representations.rb +81 -0
  13. data/generated/google/apis/adexchangebuyer_v1_4/service.rb +60 -8
  14. data/generated/google/apis/adexchangeseller_v2_0.rb +2 -3
  15. data/generated/google/apis/adexchangeseller_v2_0/service.rb +1 -2
  16. data/generated/google/apis/admin_directory_v1.rb +1 -1
  17. data/generated/google/apis/admin_directory_v1/classes.rb +86 -0
  18. data/generated/google/apis/admin_directory_v1/representations.rb +24 -0
  19. data/generated/google/apis/admin_directory_v1/service.rb +41 -2
  20. data/generated/google/apis/admin_reports_v1.rb +3 -3
  21. data/generated/google/apis/admin_reports_v1/service.rb +2 -2
  22. data/generated/google/apis/adsense_v1_4.rb +1 -1
  23. data/generated/google/apis/adsense_v1_4/classes.rb +1 -1
  24. data/generated/google/apis/adsensehost_v4_1.rb +1 -1
  25. data/generated/google/apis/adsensehost_v4_1/classes.rb +1 -2
  26. data/generated/google/apis/analytics_v3.rb +1 -1
  27. data/generated/google/apis/analytics_v3/classes.rb +379 -3
  28. data/generated/google/apis/analytics_v3/representations.rb +136 -0
  29. data/generated/google/apis/analytics_v3/service.rb +217 -0
  30. data/generated/google/apis/analyticsreporting_v4.rb +1 -1
  31. data/generated/google/apis/analyticsreporting_v4/classes.rb +50 -22
  32. data/generated/google/apis/androidenterprise_v1.rb +1 -1
  33. data/generated/google/apis/androidenterprise_v1/classes.rb +813 -49
  34. data/generated/google/apis/androidenterprise_v1/representations.rb +336 -0
  35. data/generated/google/apis/androidenterprise_v1/service.rb +1234 -145
  36. data/generated/google/apis/androidpublisher_v2.rb +1 -1
  37. data/generated/google/apis/androidpublisher_v2/classes.rb +47 -8
  38. data/generated/google/apis/androidpublisher_v2/representations.rb +27 -0
  39. data/generated/google/apis/androidpublisher_v2/service.rb +55 -0
  40. data/generated/google/apis/appengine_v1beta5.rb +7 -1
  41. data/generated/google/apis/appengine_v1beta5/classes.rb +516 -313
  42. data/generated/google/apis/appengine_v1beta5/representations.rb +115 -22
  43. data/generated/google/apis/appengine_v1beta5/service.rb +329 -33
  44. data/generated/google/apis/appsactivity_v1.rb +1 -1
  45. data/generated/google/apis/appsactivity_v1/classes.rb +7 -0
  46. data/generated/google/apis/appsactivity_v1/representations.rb +1 -0
  47. data/generated/google/apis/appstate_v1.rb +1 -1
  48. data/generated/google/apis/bigquery_v2.rb +1 -1
  49. data/generated/google/apis/bigquery_v2/classes.rb +277 -20
  50. data/generated/google/apis/bigquery_v2/representations.rb +86 -0
  51. data/generated/google/apis/bigquery_v2/service.rb +8 -2
  52. data/generated/google/apis/books_v1.rb +2 -2
  53. data/generated/google/apis/books_v1/classes.rb +79 -1
  54. data/generated/google/apis/books_v1/representations.rb +34 -0
  55. data/generated/google/apis/books_v1/service.rb +7 -3
  56. data/generated/google/apis/calendar_v3.rb +1 -1
  57. data/generated/google/apis/civicinfo_v2.rb +3 -2
  58. data/generated/google/apis/civicinfo_v2/classes.rb +377 -5
  59. data/generated/google/apis/civicinfo_v2/representations.rb +149 -0
  60. data/generated/google/apis/civicinfo_v2/service.rb +27 -6
  61. data/generated/google/apis/classroom_v1.rb +1 -1
  62. data/generated/google/apis/classroom_v1/classes.rb +183 -37
  63. data/generated/google/apis/classroom_v1/representations.rb +74 -9
  64. data/generated/google/apis/classroom_v1/service.rb +403 -38
  65. data/generated/google/apis/cloudbuild_v1.rb +1 -1
  66. data/generated/google/apis/cloudbuild_v1/classes.rb +381 -17
  67. data/generated/google/apis/cloudbuild_v1/representations.rb +137 -2
  68. data/generated/google/apis/cloudbuild_v1/service.rb +174 -1
  69. data/generated/google/apis/clouddebugger_v2.rb +3 -6
  70. data/generated/google/apis/clouddebugger_v2/service.rb +4 -4
  71. data/generated/google/apis/cloudmonitoring_v2beta2.rb +1 -1
  72. data/generated/google/apis/cloudresourcemanager_v1.rb +1 -1
  73. data/generated/google/apis/cloudresourcemanager_v1/classes.rb +502 -111
  74. data/generated/google/apis/cloudresourcemanager_v1/representations.rb +162 -24
  75. data/generated/google/apis/cloudresourcemanager_v1/service.rb +274 -30
  76. data/generated/google/apis/cloudresourcemanager_v1beta1.rb +1 -1
  77. data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +121 -9
  78. data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +46 -0
  79. data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +71 -58
  80. data/generated/google/apis/compute_beta.rb +1 -1
  81. data/generated/google/apis/compute_beta/classes.rb +2299 -434
  82. data/generated/google/apis/compute_beta/representations.rb +752 -33
  83. data/generated/google/apis/compute_beta/service.rb +6067 -3153
  84. data/generated/google/apis/compute_v1.rb +1 -1
  85. data/generated/google/apis/compute_v1/classes.rb +1681 -207
  86. data/generated/google/apis/compute_v1/representations.rb +552 -0
  87. data/generated/google/apis/compute_v1/service.rb +2797 -1171
  88. data/generated/google/apis/content_v2.rb +1 -1
  89. data/generated/google/apis/content_v2/classes.rb +757 -1
  90. data/generated/google/apis/content_v2/representations.rb +337 -0
  91. data/generated/google/apis/content_v2/service.rb +244 -0
  92. data/generated/google/apis/dataflow_v1b3.rb +38 -0
  93. data/generated/google/apis/dataflow_v1b3/classes.rb +4053 -0
  94. data/generated/google/apis/dataflow_v1b3/representations.rb +1736 -0
  95. data/generated/google/apis/dataflow_v1b3/service.rb +875 -0
  96. data/generated/google/apis/dataproc_v1.rb +2 -2
  97. data/generated/google/apis/dataproc_v1/classes.rb +213 -68
  98. data/generated/google/apis/dataproc_v1/representations.rb +38 -0
  99. data/generated/google/apis/dataproc_v1/service.rb +78 -48
  100. data/generated/google/apis/datastore_v1.rb +38 -0
  101. data/generated/google/apis/datastore_v1/classes.rb +1284 -0
  102. data/generated/google/apis/datastore_v1/representations.rb +572 -0
  103. data/generated/google/apis/datastore_v1/service.rb +259 -0
  104. data/generated/google/apis/datastore_v1beta3.rb +38 -0
  105. data/generated/google/apis/datastore_v1beta3/classes.rb +1284 -0
  106. data/generated/google/apis/datastore_v1beta3/representations.rb +572 -0
  107. data/generated/google/apis/datastore_v1beta3/service.rb +259 -0
  108. data/generated/google/apis/deploymentmanager_v2.rb +1 -1
  109. data/generated/google/apis/deploymentmanager_v2/classes.rb +384 -2
  110. data/generated/google/apis/deploymentmanager_v2/representations.rb +161 -0
  111. data/generated/google/apis/deploymentmanager_v2/service.rb +217 -55
  112. data/generated/google/apis/dfareporting_v2_5.rb +40 -0
  113. data/generated/google/apis/dfareporting_v2_5/classes.rb +11225 -0
  114. data/generated/google/apis/dfareporting_v2_5/representations.rb +3982 -0
  115. data/generated/google/apis/dfareporting_v2_5/service.rb +8755 -0
  116. data/generated/google/apis/dfareporting_v2_6.rb +40 -0
  117. data/generated/google/apis/dfareporting_v2_6/classes.rb +11586 -0
  118. data/generated/google/apis/dfareporting_v2_6/representations.rb +4119 -0
  119. data/generated/google/apis/dfareporting_v2_6/service.rb +9025 -0
  120. data/generated/google/apis/dns_v1.rb +1 -1
  121. data/generated/google/apis/dns_v1/classes.rb +1 -1
  122. data/generated/google/apis/doubleclickbidmanager_v1.rb +1 -1
  123. data/generated/google/apis/doubleclickbidmanager_v1/classes.rb +79 -86
  124. data/generated/google/apis/doubleclickbidmanager_v1/representations.rb +25 -28
  125. data/generated/google/apis/doubleclickbidmanager_v1/service.rb +10 -8
  126. data/generated/google/apis/doubleclicksearch_v2.rb +1 -1
  127. data/generated/google/apis/drive_v2.rb +1 -1
  128. data/generated/google/apis/drive_v2/classes.rb +27 -3
  129. data/generated/google/apis/drive_v2/representations.rb +4 -0
  130. data/generated/google/apis/drive_v2/service.rb +16 -3
  131. data/generated/google/apis/drive_v3.rb +1 -1
  132. data/generated/google/apis/drive_v3/classes.rb +50 -16
  133. data/generated/google/apis/drive_v3/representations.rb +4 -0
  134. data/generated/google/apis/drive_v3/service.rb +12 -2
  135. data/generated/google/apis/fitness_v1.rb +8 -2
  136. data/generated/google/apis/fitness_v1/classes.rb +64 -6
  137. data/generated/google/apis/fitness_v1/representations.rb +20 -0
  138. data/generated/google/apis/fitness_v1/service.rb +17 -18
  139. data/generated/google/apis/fusiontables_v2.rb +1 -1
  140. data/generated/google/apis/fusiontables_v2/classes.rb +4 -3
  141. data/generated/google/apis/games_configuration_v1configuration.rb +1 -1
  142. data/generated/google/apis/games_management_v1management.rb +1 -1
  143. data/generated/google/apis/games_v1.rb +1 -1
  144. data/generated/google/apis/genomics_v1.rb +2 -4
  145. data/generated/google/apis/genomics_v1/classes.rb +143 -34
  146. data/generated/google/apis/genomics_v1/representations.rb +48 -11
  147. data/generated/google/apis/genomics_v1/service.rb +35 -37
  148. data/generated/google/apis/gmail_v1.rb +10 -1
  149. data/generated/google/apis/gmail_v1/classes.rb +542 -4
  150. data/generated/google/apis/gmail_v1/representations.rb +213 -0
  151. data/generated/google/apis/gmail_v1/service.rb +898 -1
  152. data/generated/google/apis/groupssettings_v1.rb +1 -1
  153. data/generated/google/apis/groupssettings_v1/classes.rb +12 -0
  154. data/generated/google/apis/groupssettings_v1/representations.rb +2 -0
  155. data/generated/google/apis/iam_v1.rb +2 -2
  156. data/generated/google/apis/iam_v1/classes.rb +181 -206
  157. data/generated/google/apis/iam_v1/representations.rb +36 -45
  158. data/generated/google/apis/iam_v1/service.rb +101 -67
  159. data/generated/google/apis/identitytoolkit_v3.rb +4 -1
  160. data/generated/google/apis/identitytoolkit_v3/classes.rb +171 -1
  161. data/generated/google/apis/identitytoolkit_v3/representations.rb +26 -0
  162. data/generated/google/apis/language_v1beta1.rb +36 -0
  163. data/generated/google/apis/language_v1beta1/classes.rb +599 -0
  164. data/generated/google/apis/language_v1beta1/representations.rb +289 -0
  165. data/generated/google/apis/language_v1beta1/service.rb +152 -0
  166. data/generated/google/apis/logging_v2beta1.rb +6 -6
  167. data/generated/google/apis/logging_v2beta1/classes.rb +760 -731
  168. data/generated/google/apis/logging_v2beta1/representations.rb +136 -147
  169. data/generated/google/apis/logging_v2beta1/service.rb +290 -209
  170. data/generated/google/apis/mirror_v1.rb +2 -2
  171. data/generated/google/apis/mirror_v1/service.rb +1 -1
  172. data/generated/google/apis/monitoring_v3.rb +45 -0
  173. data/generated/google/apis/monitoring_v3/classes.rb +1337 -0
  174. data/generated/google/apis/monitoring_v3/representations.rb +516 -0
  175. data/generated/google/apis/monitoring_v3/service.rb +711 -0
  176. data/generated/google/apis/oauth2_v2.rb +1 -1
  177. data/generated/google/apis/pagespeedonline_v2.rb +1 -1
  178. data/generated/google/apis/plus_domains_v1.rb +1 -1
  179. data/generated/google/apis/plus_v1.rb +1 -1
  180. data/generated/google/apis/pubsub_v1.rb +1 -1
  181. data/generated/google/apis/pubsub_v1/classes.rb +10 -9
  182. data/generated/google/apis/pubsub_v1/service.rb +128 -27
  183. data/generated/google/apis/qpx_express_v1.rb +1 -1
  184. data/generated/google/apis/qpx_express_v1/classes.rb +6 -0
  185. data/generated/google/apis/qpx_express_v1/representations.rb +1 -0
  186. data/generated/google/apis/replicapool_v1beta2.rb +1 -1
  187. data/generated/google/apis/replicapoolupdater_v1beta1.rb +4 -2
  188. data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +3 -1
  189. data/generated/google/apis/script_v1.rb +1 -1
  190. data/generated/google/apis/script_v1/classes.rb +6 -0
  191. data/generated/google/apis/script_v1/representations.rb +1 -0
  192. data/generated/google/apis/sheets_v4.rb +1 -1
  193. data/generated/google/apis/sheets_v4/classes.rb +910 -89
  194. data/generated/google/apis/sheets_v4/representations.rb +194 -10
  195. data/generated/google/apis/sheets_v4/service.rb +216 -49
  196. data/generated/google/apis/slides_v1.rb +49 -0
  197. data/generated/google/apis/slides_v1/classes.rb +3926 -0
  198. data/generated/google/apis/slides_v1/representations.rb +1722 -0
  199. data/generated/google/apis/slides_v1/service.rb +202 -0
  200. data/generated/google/apis/speech_v1beta1.rb +34 -0
  201. data/generated/google/apis/speech_v1beta1/classes.rb +511 -0
  202. data/generated/google/apis/speech_v1beta1/representations.rb +218 -0
  203. data/generated/google/apis/speech_v1beta1/service.rb +271 -0
  204. data/generated/google/apis/sqladmin_v1beta4.rb +1 -1
  205. data/generated/google/apis/sqladmin_v1beta4/classes.rb +32 -8
  206. data/generated/google/apis/sqladmin_v1beta4/representations.rb +3 -0
  207. data/generated/google/apis/sqladmin_v1beta4/service.rb +42 -0
  208. data/generated/google/apis/storage_v1.rb +1 -1
  209. data/generated/google/apis/storage_v1/classes.rb +43 -18
  210. data/generated/google/apis/storage_v1/representations.rb +4 -1
  211. data/generated/google/apis/storage_v1/service.rb +5 -2
  212. data/generated/google/apis/translate_v2.rb +2 -2
  213. data/generated/google/apis/translate_v2/service.rb +1 -1
  214. data/generated/google/apis/vision_v1.rb +1 -1
  215. data/generated/google/apis/vision_v1/classes.rb +12 -11
  216. data/generated/google/apis/youtube_analytics_v1.rb +1 -1
  217. data/generated/google/apis/youtube_partner_v1.rb +1 -1
  218. data/generated/google/apis/youtube_partner_v1/classes.rb +6 -0
  219. data/generated/google/apis/youtube_partner_v1/representations.rb +2 -0
  220. data/generated/google/apis/youtube_partner_v1/service.rb +15 -3
  221. data/generated/google/apis/youtube_v3.rb +1 -1
  222. data/generated/google/apis/youtube_v3/classes.rb +183 -21
  223. data/generated/google/apis/youtube_v3/representations.rb +85 -4
  224. data/generated/google/apis/youtube_v3/service.rb +41 -5
  225. data/generated/google/apis/youtubereporting_v1.rb +1 -1
  226. data/google-api-client.gemspec +2 -1
  227. data/lib/google/apis/core/api_command.rb +4 -0
  228. data/lib/google/apis/core/base_service.rb +10 -4
  229. data/lib/google/apis/core/download.rb +7 -2
  230. data/lib/google/apis/core/http_command.rb +5 -1
  231. data/lib/google/apis/core/upload.rb +7 -1
  232. data/lib/google/apis/errors.rb +2 -2
  233. data/lib/google/apis/generator/annotator.rb +6 -0
  234. data/lib/google/apis/version.rb +1 -1
  235. data/samples/cli/lib/samples/bigquery.rb +101 -0
  236. data/samples/cli/lib/samples/sheets.rb +61 -0
  237. data/sync.rb +71 -0
  238. metadata +55 -13
@@ -22,70 +22,84 @@ module Google
22
22
  module Apis
23
23
  module LoggingV2beta1
24
24
 
25
- # A generic empty message that you can re-use to avoid defining duplicated empty
26
- # messages in your APIs. A typical example is to use it as the request or the
27
- # response type of an API method. For instance: service Foo ` rpc Bar(google.
28
- # protobuf.Empty) returns (google.protobuf.Empty); ` The JSON representation for
29
- # `Empty` is empty JSON object ````.
30
- class Empty
25
+ # Result returned from `ListLogEntries`.
26
+ class ListLogEntriesResponse
31
27
  include Google::Apis::Core::Hashable
32
28
 
29
+ # A list of log entries.
30
+ # Corresponds to the JSON property `entries`
31
+ # @return [Array<Google::Apis::LoggingV2beta1::LogEntry>]
32
+ attr_accessor :entries
33
+
34
+ # If there might be more results than appear in this response, then
35
+ # `nextPageToken` is included. To get the next set of results, call this
36
+ # method again using the value of `nextPageToken` as `pageToken`.
37
+ # Corresponds to the JSON property `nextPageToken`
38
+ # @return [String]
39
+ attr_accessor :next_page_token
40
+
33
41
  def initialize(**args)
34
42
  update!(**args)
35
43
  end
36
44
 
37
45
  # Update properties of this object
38
46
  def update!(**args)
47
+ @entries = args[:entries] if args.key?(:entries)
48
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
39
49
  end
40
50
  end
41
51
 
42
- # The parameters to WriteLogEntries.
43
- class WriteLogEntriesRequest
52
+ # Result returned from `ListSinks`.
53
+ class ListSinksResponse
44
54
  include Google::Apis::Core::Hashable
45
55
 
46
- # Optional. A default log resource name for those log entries in `entries` that
47
- # do not specify their own `logName`. Example: `"projects/my-project/logs/syslog"
48
- # `. See LogEntry.
49
- # Corresponds to the JSON property `logName`
56
+ # If there might be more results than appear in this response, then
57
+ # `nextPageToken` is included. To get the next set of results, call the same
58
+ # method again using the value of `nextPageToken` as `pageToken`.
59
+ # Corresponds to the JSON property `nextPageToken`
50
60
  # @return [String]
51
- attr_accessor :log_name
61
+ attr_accessor :next_page_token
52
62
 
53
- # An object representing a resource that can be used for monitoring, logging,
54
- # billing, or other purposes. Examples include virtual machine instances,
55
- # databases, and storage devices such as disks. The `type` field identifies a
56
- # MonitoredResourceDescriptor object that describes the resource's schema.
57
- # Information in the `labels` field identifies the actual resource and its
58
- # attributes according to the schema. For example, a particular Compute Engine
59
- # VM instance could be represented by the following object, because the
60
- # MonitoredResourceDescriptor for `"gce_instance"` has labels `"instance_id"`
61
- # and `"zone"`: ` "type": "gce_instance", "labels": ` "instance_id": "my-
62
- # instance", "zone": "us-central1-a" ``
63
- # Corresponds to the JSON property `resource`
64
- # @return [Google::Apis::LoggingV2beta1::MonitoredResource]
65
- attr_accessor :resource
63
+ # A list of sinks.
64
+ # Corresponds to the JSON property `sinks`
65
+ # @return [Array<Google::Apis::LoggingV2beta1::LogSink>]
66
+ attr_accessor :sinks
66
67
 
67
- # Optional. User-defined `key:value` items that are added to the `labels` field
68
- # of each log entry in `entries`, except when a log entry specifies its own `key:
69
- # value` item with the same key. Example: `` "size": "large", "color":"red" ``
70
- # Corresponds to the JSON property `labels`
71
- # @return [Hash<String,String>]
72
- attr_accessor :labels
68
+ def initialize(**args)
69
+ update!(**args)
70
+ end
73
71
 
74
- # Required. The log entries to write. The log entries must have values for all
75
- # required fields.
76
- # Corresponds to the JSON property `entries`
77
- # @return [Array<Google::Apis::LoggingV2beta1::LogEntry>]
78
- attr_accessor :entries
72
+ # Update properties of this object
73
+ def update!(**args)
74
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
75
+ @sinks = args[:sinks] if args.key?(:sinks)
76
+ end
77
+ end
79
78
 
80
- # Optional. Whether valid entries should be written even if some other entries
81
- # fail due to INVALID_ARGUMENT or PERMISSION_DENIED errors. If any entry is not
82
- # written, the response status will be the error associated with one of the
83
- # failed entries and include error details in the form of
84
- # WriteLogEntriesPartialErrors.
85
- # Corresponds to the JSON property `partialSuccess`
86
- # @return [Boolean]
87
- attr_accessor :partial_success
88
- alias_method :partial_success?, :partial_success
79
+ # Specifies a location in a source code file.
80
+ class SourceLocation
81
+ include Google::Apis::Core::Hashable
82
+
83
+ # Source file name. Depending on the runtime environment, this might be a
84
+ # simple name or a fully-qualified name.
85
+ # Corresponds to the JSON property `file`
86
+ # @return [String]
87
+ attr_accessor :file
88
+
89
+ # Human-readable name of the function or method being invoked, with optional
90
+ # context such as the class or package name. This information is used in
91
+ # contexts such as the logs viewer, where a file and line number are less
92
+ # meaningful. The format can vary by language. For example:
93
+ # `qual.if.ied.Class.method` (Java), `dir/package.func` (Go), `function`
94
+ # (Python).
95
+ # Corresponds to the JSON property `functionName`
96
+ # @return [String]
97
+ attr_accessor :function_name
98
+
99
+ # Line within the source file.
100
+ # Corresponds to the JSON property `line`
101
+ # @return [String]
102
+ attr_accessor :line
89
103
 
90
104
  def initialize(**args)
91
105
  update!(**args)
@@ -93,40 +107,81 @@ module Google
93
107
 
94
108
  # Update properties of this object
95
109
  def update!(**args)
96
- @log_name = args[:log_name] if args.key?(:log_name)
97
- @resource = args[:resource] if args.key?(:resource)
98
- @labels = args[:labels] if args.key?(:labels)
99
- @entries = args[:entries] if args.key?(:entries)
100
- @partial_success = args[:partial_success] if args.key?(:partial_success)
110
+ @file = args[:file] if args.key?(:file)
111
+ @function_name = args[:function_name] if args.key?(:function_name)
112
+ @line = args[:line] if args.key?(:line)
101
113
  end
102
114
  end
103
115
 
104
- # An object representing a resource that can be used for monitoring, logging,
105
- # billing, or other purposes. Examples include virtual machine instances,
106
- # databases, and storage devices such as disks. The `type` field identifies a
107
- # MonitoredResourceDescriptor object that describes the resource's schema.
108
- # Information in the `labels` field identifies the actual resource and its
109
- # attributes according to the schema. For example, a particular Compute Engine
110
- # VM instance could be represented by the following object, because the
111
- # MonitoredResourceDescriptor for `"gce_instance"` has labels `"instance_id"`
112
- # and `"zone"`: ` "type": "gce_instance", "labels": ` "instance_id": "my-
113
- # instance", "zone": "us-central1-a" ``
114
- class MonitoredResource
116
+ # Describes a sink used to export log entries outside of Stackdriver Logging.
117
+ # A logs filter controls which log entries are exported. Sinks can have a
118
+ # start time and an end time; these can be used to place log entries from an
119
+ # exact time range into a particular destination. If both `start_time` and
120
+ # `end_time` are present, then `start_time` must be less than `end_time`.
121
+ class LogSink
115
122
  include Google::Apis::Core::Hashable
116
123
 
117
- # Required. The monitored resource type. This field must match the `type` field
118
- # of a MonitoredResourceDescriptor object. For example, the type of a Cloud SQL
119
- # database is `"cloudsql_database"`.
120
- # Corresponds to the JSON property `type`
124
+ # Required. The export destination. See
125
+ # [Exporting Logs With Sinks](/logging/docs/api/tasks/exporting-logs).
126
+ # Examples:
127
+ # "storage.googleapis.com/my-gcs-bucket"
128
+ # "bigquery.googleapis.com/projects/my-project-id/datasets/my-dataset"
129
+ # "pubsub.googleapis.com/projects/my-project/topics/my-topic"
130
+ # Corresponds to the JSON property `destination`
121
131
  # @return [String]
122
- attr_accessor :type
132
+ attr_accessor :destination
123
133
 
124
- # Required. Values for all of the labels listed in the associated monitored
125
- # resource descriptor. For example, Cloud SQL databases use the labels `"
126
- # database_id"` and `"zone"`.
127
- # Corresponds to the JSON property `labels`
128
- # @return [Hash<String,String>]
129
- attr_accessor :labels
134
+ # Optional. An [advanced logs filter](/logging/docs/view/advanced_filters).
135
+ # Only log entries matching the filter are exported. The filter
136
+ # must be consistent with the log entry format specified by the
137
+ # `outputVersionFormat` parameter, regardless of the format of the
138
+ # log entry that was originally written to Stackdriver Logging.
139
+ # Example filter (V2 format):
140
+ # logName=projects/my-projectid/logs/syslog AND severity>=ERROR
141
+ # The maximum length of the filter is 20000 characters.
142
+ # Corresponds to the JSON property `filter`
143
+ # @return [String]
144
+ attr_accessor :filter
145
+
146
+ # Optional. Time at which this sink will stop exporting log entries. If this
147
+ # value is present, then log entries are exported only if `entry.timestamp` <
148
+ # `end_time`.
149
+ # Corresponds to the JSON property `endTime`
150
+ # @return [String]
151
+ attr_accessor :end_time
152
+
153
+ # Required. The client-assigned sink identifier, unique within the
154
+ # project. Example: `"my-syslog-errors-to-pubsub"`. Sink identifiers are
155
+ # limited to 1000 characters and can include only the following characters:
156
+ # `A-Z`, `a-z`, `0-9`, and the special characters `_-.`. The maximum length
157
+ # of the name is 100 characters.
158
+ # Corresponds to the JSON property `name`
159
+ # @return [String]
160
+ attr_accessor :name
161
+
162
+ # Optional. The time at which this sink will begin exporting log entries. If
163
+ # this value is present, then log entries are exported only if `start_time`
164
+ # <=`entry.timestamp`.
165
+ # Corresponds to the JSON property `startTime`
166
+ # @return [String]
167
+ attr_accessor :start_time
168
+
169
+ # Optional. The log entry version to use for this sink's exported log
170
+ # entries. This version does not have to correspond to the version of the
171
+ # log entry that was written to Stackdriver Logging. If omitted, the
172
+ # v2 format is used.
173
+ # Corresponds to the JSON property `outputVersionFormat`
174
+ # @return [String]
175
+ attr_accessor :output_version_format
176
+
177
+ # Output only. An IAM identity&mdash;a service account or group&mdash;that
178
+ # will write exported log entries to the destination on behalf of Stackdriver
179
+ # Logging. You must grant this identity write-access to the destination.
180
+ # Consult the destination service's documentation to determine the exact role
181
+ # that must be granted.
182
+ # Corresponds to the JSON property `writerIdentity`
183
+ # @return [String]
184
+ attr_accessor :writer_identity
130
185
 
131
186
  def initialize(**args)
132
187
  update!(**args)
@@ -134,8 +189,62 @@ module Google
134
189
 
135
190
  # Update properties of this object
136
191
  def update!(**args)
137
- @type = args[:type] if args.key?(:type)
138
- @labels = args[:labels] if args.key?(:labels)
192
+ @destination = args[:destination] if args.key?(:destination)
193
+ @filter = args[:filter] if args.key?(:filter)
194
+ @end_time = args[:end_time] if args.key?(:end_time)
195
+ @name = args[:name] if args.key?(:name)
196
+ @start_time = args[:start_time] if args.key?(:start_time)
197
+ @output_version_format = args[:output_version_format] if args.key?(:output_version_format)
198
+ @writer_identity = args[:writer_identity] if args.key?(:writer_identity)
199
+ end
200
+ end
201
+
202
+ # Describes a logs-based metric. The value of the metric is the
203
+ # number of log entries that match a logs filter.
204
+ class LogMetric
205
+ include Google::Apis::Core::Hashable
206
+
207
+ # Optional. A description of this metric, which is used in documentation.
208
+ # Corresponds to the JSON property `description`
209
+ # @return [String]
210
+ attr_accessor :description
211
+
212
+ # Required. An [advanced logs filter](/logging/docs/view/advanced_filters).
213
+ # Example: `"resource.type=gae_app AND severity>=ERROR"`.
214
+ # The maximum length of the filter is 20000 characters.
215
+ # Corresponds to the JSON property `filter`
216
+ # @return [String]
217
+ attr_accessor :filter
218
+
219
+ # Required. The client-assigned metric identifier. Example:
220
+ # `"severe_errors"`. Metric identifiers are limited to 100
221
+ # characters and can include only the following characters: `A-Z`,
222
+ # `a-z`, `0-9`, and the special characters `_-.,+!*',()%/`. The
223
+ # forward-slash character (`/`) denotes a hierarchy of name pieces,
224
+ # and it cannot be the first character of the name. The '%' character
225
+ # is used to URL encode unsafe and reserved characters and must be
226
+ # followed by two hexadecimal digits according to RFC 1738.
227
+ # Corresponds to the JSON property `name`
228
+ # @return [String]
229
+ attr_accessor :name
230
+
231
+ # Output only. The API version that created or updated this metric.
232
+ # The version also dictates the syntax of the filter expression. When a value
233
+ # for this field is missing, the default value of V2 should be assumed.
234
+ # Corresponds to the JSON property `version`
235
+ # @return [String]
236
+ attr_accessor :version
237
+
238
+ def initialize(**args)
239
+ update!(**args)
240
+ end
241
+
242
+ # Update properties of this object
243
+ def update!(**args)
244
+ @description = args[:description] if args.key?(:description)
245
+ @filter = args[:filter] if args.key?(:filter)
246
+ @name = args[:name] if args.key?(:name)
247
+ @version = args[:version] if args.key?(:version)
139
248
  end
140
249
  end
141
250
 
@@ -143,82 +252,90 @@ module Google
143
252
  class LogEntry
144
253
  include Google::Apis::Core::Hashable
145
254
 
146
- # Required. The resource name of the log to which this log entry belongs. The
147
- # format of the name is `"projects/
148
- # /logs/"`. Examples: `"projects/my-projectid/logs/syslog"`, `"projects/
149
- # 1234567890/logs/library.googleapis.com%2Fbook_log"`. The log ID part of
150
- # resource name must be less than 512 characters long and can only include the
151
- # following characters: upper and lower case alphanumeric characters: [A-Za-z0-9]
152
- # ; and punctuation characters: forward-slash, underscore, hyphen, and period.
255
+ # The log entry payload, represented as a Unicode string (UTF-8).
256
+ # Corresponds to the JSON property `textPayload`
257
+ # @return [String]
258
+ attr_accessor :text_payload
259
+
260
+ # A common proto for logging HTTP requests. Only contains semantics
261
+ # defined by the HTTP specification. Product-specific logging
262
+ # information MUST be defined in a separate message.
263
+ # Corresponds to the JSON property `httpRequest`
264
+ # @return [Google::Apis::LoggingV2beta1::HttpRequest]
265
+ attr_accessor :http_request
266
+
267
+ # The log entry payload, represented as a structure that
268
+ # is expressed as a JSON object.
269
+ # Corresponds to the JSON property `jsonPayload`
270
+ # @return [Hash<String,Object>]
271
+ attr_accessor :json_payload
272
+
273
+ # Optional. A set of user-defined (key, value) data that provides additional
274
+ # information about the log entry.
275
+ # Corresponds to the JSON property `labels`
276
+ # @return [Hash<String,String>]
277
+ attr_accessor :labels
278
+
279
+ # Required. The resource name of the log to which this log entry
280
+ # belongs. The format of the name is
281
+ # `"projects/<project-id>/logs/<log-id>"`. Examples:
282
+ # `"projects/my-projectid/logs/syslog"`,
283
+ # `"projects/my-projectid/logs/library.googleapis.com%2Fbook_log"`.
284
+ # The log ID part of resource name must be less than 512 characters
285
+ # long and can only include the following characters: upper and
286
+ # lower case alphanumeric characters: [A-Za-z0-9]; and punctuation
287
+ # characters: forward-slash, underscore, hyphen, and period.
153
288
  # Forward-slash (`/`) characters in the log ID must be URL-encoded.
154
289
  # Corresponds to the JSON property `logName`
155
290
  # @return [String]
156
291
  attr_accessor :log_name
157
292
 
293
+ # Optional. The severity of the log entry. The default value is
294
+ # `LogSeverity.DEFAULT`.
295
+ # Corresponds to the JSON property `severity`
296
+ # @return [String]
297
+ attr_accessor :severity
298
+
158
299
  # An object representing a resource that can be used for monitoring, logging,
159
300
  # billing, or other purposes. Examples include virtual machine instances,
160
301
  # databases, and storage devices such as disks. The `type` field identifies a
161
- # MonitoredResourceDescriptor object that describes the resource's schema.
162
- # Information in the `labels` field identifies the actual resource and its
163
- # attributes according to the schema. For example, a particular Compute Engine
164
- # VM instance could be represented by the following object, because the
165
- # MonitoredResourceDescriptor for `"gce_instance"` has labels `"instance_id"`
166
- # and `"zone"`: ` "type": "gce_instance", "labels": ` "instance_id": "my-
167
- # instance", "zone": "us-central1-a" ``
302
+ # MonitoredResourceDescriptor object that describes the resource's
303
+ # schema. Information in the `labels` field identifies the actual resource and
304
+ # its attributes according to the schema. For example, a particular Compute
305
+ # Engine VM instance could be represented by the following object, because the
306
+ # MonitoredResourceDescriptor for `"gce_instance"` has labels
307
+ # `"instance_id"` and `"zone"`:
308
+ # ` "type": "gce_instance",
309
+ # "labels": ` "instance_id": "12345678901234",
310
+ # "zone": "us-central1-a" ``
168
311
  # Corresponds to the JSON property `resource`
169
312
  # @return [Google::Apis::LoggingV2beta1::MonitoredResource]
170
313
  attr_accessor :resource
171
314
 
172
- # The log entry payload, represented as a protocol buffer. You can only use `
173
- # protoPayload` values that belong to a set of approved types.
315
+ # The log entry payload, represented as a protocol buffer. Some
316
+ # Google Cloud Platform services use this field for their log
317
+ # entry payloads.
174
318
  # Corresponds to the JSON property `protoPayload`
175
319
  # @return [Hash<String,Object>]
176
320
  attr_accessor :proto_payload
177
321
 
178
- # The log entry payload, represented as a Unicode string (UTF-8).
179
- # Corresponds to the JSON property `textPayload`
180
- # @return [String]
181
- attr_accessor :text_payload
182
-
183
- # The log entry payload, represented as a structure that is expressed as a JSON
184
- # object.
185
- # Corresponds to the JSON property `jsonPayload`
186
- # @return [Hash<String,Object>]
187
- attr_accessor :json_payload
188
-
189
- # Optional. The time the event described by the log entry occurred. If omitted,
190
- # Cloud Logging will use the time the log entry is written.
322
+ # Optional. The time the event described by the log entry occurred. If
323
+ # omitted, Stackdriver Logging will use the time the log entry is received.
191
324
  # Corresponds to the JSON property `timestamp`
192
325
  # @return [String]
193
326
  attr_accessor :timestamp
194
327
 
195
- # Optional. The severity of the log entry. The default value is `LogSeverity.
196
- # DEFAULT`.
197
- # Corresponds to the JSON property `severity`
198
- # @return [String]
199
- attr_accessor :severity
200
-
201
- # Optional. A unique ID for the log entry. If you provide this field, the
202
- # logging service considers other log entries in the same log with the same ID
203
- # as duplicates which can be removed. If omitted, Cloud Logging will generate a
204
- # unique ID for this log entry.
328
+ # Optional. A unique ID for the log entry. If you provide this
329
+ # field, the logging service considers other log entries in the
330
+ # same project with the same ID as duplicates which can be removed. If
331
+ # omitted, Stackdriver Logging will generate a unique ID for this
332
+ # log entry.
205
333
  # Corresponds to the JSON property `insertId`
206
334
  # @return [String]
207
335
  attr_accessor :insert_id
208
336
 
209
- # A common proto for logging HTTP requests.
210
- # Corresponds to the JSON property `httpRequest`
211
- # @return [Google::Apis::LoggingV2beta1::HttpRequest]
212
- attr_accessor :http_request
213
-
214
- # Optional. A set of user-defined (key, value) data that provides additional
215
- # information about the log entry.
216
- # Corresponds to the JSON property `labels`
217
- # @return [Hash<String,String>]
218
- attr_accessor :labels
219
-
220
- # Additional information about a potentially long-running operation with which a
221
- # log entry is associated.
337
+ # Additional information about a potentially long-running operation with which
338
+ # a log entry is associated.
222
339
  # Corresponds to the JSON property `operation`
223
340
  # @return [Google::Apis::LoggingV2beta1::LogEntryOperation]
224
341
  attr_accessor :operation
@@ -229,94 +346,73 @@ module Google
229
346
 
230
347
  # Update properties of this object
231
348
  def update!(**args)
349
+ @text_payload = args[:text_payload] if args.key?(:text_payload)
350
+ @http_request = args[:http_request] if args.key?(:http_request)
351
+ @json_payload = args[:json_payload] if args.key?(:json_payload)
352
+ @labels = args[:labels] if args.key?(:labels)
232
353
  @log_name = args[:log_name] if args.key?(:log_name)
354
+ @severity = args[:severity] if args.key?(:severity)
233
355
  @resource = args[:resource] if args.key?(:resource)
234
356
  @proto_payload = args[:proto_payload] if args.key?(:proto_payload)
235
- @text_payload = args[:text_payload] if args.key?(:text_payload)
236
- @json_payload = args[:json_payload] if args.key?(:json_payload)
237
357
  @timestamp = args[:timestamp] if args.key?(:timestamp)
238
- @severity = args[:severity] if args.key?(:severity)
239
358
  @insert_id = args[:insert_id] if args.key?(:insert_id)
240
- @http_request = args[:http_request] if args.key?(:http_request)
241
- @labels = args[:labels] if args.key?(:labels)
242
359
  @operation = args[:operation] if args.key?(:operation)
243
360
  end
244
361
  end
245
362
 
246
- # A common proto for logging HTTP requests.
247
- class HttpRequest
363
+ # Application log line emitted while processing a request.
364
+ class LogLine
248
365
  include Google::Apis::Core::Hashable
249
366
 
250
- # The request method. Examples: `"GET"`, `"HEAD"`, `"PUT"`, `"POST"`.
251
- # Corresponds to the JSON property `requestMethod`
252
- # @return [String]
253
- attr_accessor :request_method
254
-
255
- # The scheme (http, https), the host name, the path and the query portion of the
256
- # URL that was requested. Example: `"http://example.com/some/info?color=red"`.
257
- # Corresponds to the JSON property `requestUrl`
367
+ # Approximate time when this log entry was made.
368
+ # Corresponds to the JSON property `time`
258
369
  # @return [String]
259
- attr_accessor :request_url
370
+ attr_accessor :time
260
371
 
261
- # The size of the HTTP request message in bytes, including the request headers
262
- # and the request body.
263
- # Corresponds to the JSON property `requestSize`
372
+ # Severity of this log entry.
373
+ # Corresponds to the JSON property `severity`
264
374
  # @return [String]
265
- attr_accessor :request_size
375
+ attr_accessor :severity
266
376
 
267
- # The response code indicating the status of response. Examples: 200, 404.
268
- # Corresponds to the JSON property `status`
269
- # @return [Fixnum]
270
- attr_accessor :status
377
+ # Specifies a location in a source code file.
378
+ # Corresponds to the JSON property `sourceLocation`
379
+ # @return [Google::Apis::LoggingV2beta1::SourceLocation]
380
+ attr_accessor :source_location
271
381
 
272
- # The size of the HTTP response message sent back to the client, in bytes,
273
- # including the response headers and the response body.
274
- # Corresponds to the JSON property `responseSize`
382
+ # App-provided log message.
383
+ # Corresponds to the JSON property `logMessage`
275
384
  # @return [String]
276
- attr_accessor :response_size
385
+ attr_accessor :log_message
277
386
 
278
- # The user agent sent by the client. Example: `"Mozilla/4.0 (compatible; MSIE 6.
279
- # 0; Windows 98; Q312461; .NET CLR 1.0.3705)"`.
280
- # Corresponds to the JSON property `userAgent`
281
- # @return [String]
282
- attr_accessor :user_agent
387
+ def initialize(**args)
388
+ update!(**args)
389
+ end
283
390
 
284
- # The IP address (IPv4 or IPv6) of the client that issued the HTTP request.
285
- # Examples: `"192.168.1.1"`, `"FE80::0202:B3FF:FE1E:8329"`.
286
- # Corresponds to the JSON property `remoteIp`
287
- # @return [String]
288
- attr_accessor :remote_ip
391
+ # Update properties of this object
392
+ def update!(**args)
393
+ @time = args[:time] if args.key?(:time)
394
+ @severity = args[:severity] if args.key?(:severity)
395
+ @source_location = args[:source_location] if args.key?(:source_location)
396
+ @log_message = args[:log_message] if args.key?(:log_message)
397
+ end
398
+ end
289
399
 
290
- # The referer URL of the request, as defined in [HTTP/1.1 Header Field
291
- # Definitions](http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html).
292
- # Corresponds to the JSON property `referer`
293
- # @return [String]
294
- attr_accessor :referer
295
-
296
- # Whether or not a cache lookup was attempted.
297
- # Corresponds to the JSON property `cacheLookup`
298
- # @return [Boolean]
299
- attr_accessor :cache_lookup
300
- alias_method :cache_lookup?, :cache_lookup
301
-
302
- # Whether or not an entity was served from cache (with or without validation).
303
- # Corresponds to the JSON property `cacheHit`
304
- # @return [Boolean]
305
- attr_accessor :cache_hit
306
- alias_method :cache_hit?, :cache_hit
400
+ # A reference to a particular snapshot of the source tree used to build and
401
+ # deploy an application.
402
+ class SourceReference
403
+ include Google::Apis::Core::Hashable
307
404
 
308
- # Whether or not the response was validated with the origin server before being
309
- # served from cache. This field is only meaningful if `cache_hit` is True.
310
- # Corresponds to the JSON property `cacheValidatedWithOriginServer`
311
- # @return [Boolean]
312
- attr_accessor :cache_validated_with_origin_server
313
- alias_method :cache_validated_with_origin_server?, :cache_validated_with_origin_server
405
+ # Optional. A URI string identifying the repository.
406
+ # Example: "https://github.com/GoogleCloudPlatform/kubernetes.git"
407
+ # Corresponds to the JSON property `repository`
408
+ # @return [String]
409
+ attr_accessor :repository
314
410
 
315
- # The number of HTTP response bytes inserted into cache. Set only when a cache
316
- # fill was attempted.
317
- # Corresponds to the JSON property `cacheFillBytes`
411
+ # The canonical and persistent identifier of the deployed revision.
412
+ # Example (git): "0035781c50ec7aa23385dc841529ce8a4b70db1b"
413
+ # Corresponds to the JSON property `revisionId`
318
414
  # @return [String]
319
- attr_accessor :cache_fill_bytes
415
+ attr_accessor :revision_id
320
416
 
321
417
  def initialize(**args)
322
418
  update!(**args)
@@ -324,67 +420,39 @@ module Google
324
420
 
325
421
  # Update properties of this object
326
422
  def update!(**args)
327
- @request_method = args[:request_method] if args.key?(:request_method)
328
- @request_url = args[:request_url] if args.key?(:request_url)
329
- @request_size = args[:request_size] if args.key?(:request_size)
330
- @status = args[:status] if args.key?(:status)
331
- @response_size = args[:response_size] if args.key?(:response_size)
332
- @user_agent = args[:user_agent] if args.key?(:user_agent)
333
- @remote_ip = args[:remote_ip] if args.key?(:remote_ip)
334
- @referer = args[:referer] if args.key?(:referer)
335
- @cache_lookup = args[:cache_lookup] if args.key?(:cache_lookup)
336
- @cache_hit = args[:cache_hit] if args.key?(:cache_hit)
337
- @cache_validated_with_origin_server = args[:cache_validated_with_origin_server] if args.key?(:cache_validated_with_origin_server)
338
- @cache_fill_bytes = args[:cache_fill_bytes] if args.key?(:cache_fill_bytes)
423
+ @repository = args[:repository] if args.key?(:repository)
424
+ @revision_id = args[:revision_id] if args.key?(:revision_id)
339
425
  end
340
426
  end
341
427
 
342
- # Additional information about a potentially long-running operation with which a
343
- # log entry is associated.
344
- class LogEntryOperation
428
+ # An object representing a resource that can be used for monitoring, logging,
429
+ # billing, or other purposes. Examples include virtual machine instances,
430
+ # databases, and storage devices such as disks. The `type` field identifies a
431
+ # MonitoredResourceDescriptor object that describes the resource's
432
+ # schema. Information in the `labels` field identifies the actual resource and
433
+ # its attributes according to the schema. For example, a particular Compute
434
+ # Engine VM instance could be represented by the following object, because the
435
+ # MonitoredResourceDescriptor for `"gce_instance"` has labels
436
+ # `"instance_id"` and `"zone"`:
437
+ # ` "type": "gce_instance",
438
+ # "labels": ` "instance_id": "12345678901234",
439
+ # "zone": "us-central1-a" ``
440
+ class MonitoredResource
345
441
  include Google::Apis::Core::Hashable
346
442
 
347
- # Required. An arbitrary operation identifier. Log entries with the same
348
- # identifier are assumed to be part of the same operation.
349
- # Corresponds to the JSON property `id`
350
- # @return [String]
351
- attr_accessor :id
443
+ # Required. Values for all of the labels listed in the associated monitored
444
+ # resource descriptor. For example, Cloud SQL databases use the labels
445
+ # `"database_id"` and `"zone"`.
446
+ # Corresponds to the JSON property `labels`
447
+ # @return [Hash<String,String>]
448
+ attr_accessor :labels
352
449
 
353
- # Required. An arbitrary producer identifier. The combination of `id` and `
354
- # producer` must be globally unique. Examples for `producer`: `"MyDivision.
355
- # MyBigCompany.com"`, "github.com/MyProject/MyApplication"`.
356
- # Corresponds to the JSON property `producer`
450
+ # Required. The monitored resource type. This field must match
451
+ # the `type` field of a MonitoredResourceDescriptor object. For
452
+ # example, the type of a Cloud SQL database is `"cloudsql_database"`.
453
+ # Corresponds to the JSON property `type`
357
454
  # @return [String]
358
- attr_accessor :producer
359
-
360
- # Optional. Set this to True if this is the first log entry in the operation.
361
- # Corresponds to the JSON property `first`
362
- # @return [Boolean]
363
- attr_accessor :first
364
- alias_method :first?, :first
365
-
366
- # Optional. Set this to True if this is the last log entry in the operation.
367
- # Corresponds to the JSON property `last`
368
- # @return [Boolean]
369
- attr_accessor :last
370
- alias_method :last?, :last
371
-
372
- def initialize(**args)
373
- update!(**args)
374
- end
375
-
376
- # Update properties of this object
377
- def update!(**args)
378
- @id = args[:id] if args.key?(:id)
379
- @producer = args[:producer] if args.key?(:producer)
380
- @first = args[:first] if args.key?(:first)
381
- @last = args[:last] if args.key?(:last)
382
- end
383
- end
384
-
385
- # Result returned from WriteLogEntries. empty
386
- class WriteLogEntriesResponse
387
- include Google::Apis::Core::Hashable
455
+ attr_accessor :type
388
456
 
389
457
  def initialize(**args)
390
458
  update!(**args)
@@ -392,97 +460,68 @@ module Google
392
460
 
393
461
  # Update properties of this object
394
462
  def update!(**args)
463
+ @labels = args[:labels] if args.key?(:labels)
464
+ @type = args[:type] if args.key?(:type)
395
465
  end
396
466
  end
397
467
 
398
- # The parameters to `ListLogEntries`.
399
- class ListLogEntriesRequest
468
+ # The parameters to WriteLogEntries.
469
+ class WriteLogEntriesRequest
400
470
  include Google::Apis::Core::Hashable
401
471
 
402
- # Required. One or more project IDs or project numbers from which to retrieve
403
- # log entries. Examples of a project ID: `"my-project-1A"`, `"1234567890"`.
404
- # Corresponds to the JSON property `projectIds`
405
- # @return [Array<String>]
406
- attr_accessor :project_ids
407
-
408
- # Optional. An [advanced logs filter](/logging/docs/view/advanced_filters). The
409
- # filter is compared against all log entries in the projects specified by `
410
- # projectIds`. Only entries that match the filter are retrieved. An empty filter
411
- # matches all log entries.
412
- # Corresponds to the JSON property `filter`
413
- # @return [String]
414
- attr_accessor :filter
415
-
416
- # Optional. How the results should be sorted. Presently, the only permitted
417
- # values are `"timestamp asc"` (default) and `"timestamp desc"`. The first
418
- # option returns entries in order of increasing values of `LogEntry.timestamp` (
419
- # oldest first), and the second option returns entries in order of decreasing
420
- # timestamps (newest first). Entries with equal timestamps are returned in order
421
- # of `LogEntry.insertId`.
422
- # Corresponds to the JSON property `orderBy`
423
- # @return [String]
424
- attr_accessor :order_by
472
+ # Optional. Default labels that are added to the `labels` field of all log
473
+ # entries in `entries`. If a log entry already has a label with the same key
474
+ # as a label in this parameter, then the log entry's label is not changed.
475
+ # See LogEntry.
476
+ # Corresponds to the JSON property `labels`
477
+ # @return [Hash<String,String>]
478
+ attr_accessor :labels
425
479
 
426
- # Optional. The maximum number of results to return from this request. You must
427
- # check for presence of `nextPageToken` to determine if additional results are
428
- # available, which you can retrieve by passing the `nextPageToken` value as the `
429
- # pageToken` parameter in the next request.
430
- # Corresponds to the JSON property `pageSize`
431
- # @return [Fixnum]
432
- attr_accessor :page_size
480
+ # Required. The log entries to write. Values supplied for the fields
481
+ # `log_name`, `resource`, and `labels` in this `entries.write` request are
482
+ # added to those log entries that do not provide their own values for the
483
+ # fields.
484
+ # To improve throughput and to avoid exceeding the
485
+ # [quota limit](/logging/quota-policy) for calls to `entries.write`,
486
+ # you should write multiple log entries at once rather than
487
+ # calling this method for each individual log entry.
488
+ # Corresponds to the JSON property `entries`
489
+ # @return [Array<Google::Apis::LoggingV2beta1::LogEntry>]
490
+ attr_accessor :entries
433
491
 
434
- # Optional. If the `pageToken` parameter is supplied, then the next page of
435
- # results is retrieved. The `pageToken` parameter must be set to the value of
436
- # the `nextPageToken` from the previous response. The values of `projectIds`, `
437
- # filter`, and `orderBy` must be the same as in the previous request.
438
- # Corresponds to the JSON property `pageToken`
492
+ # Optional. A default log resource name that is assigned to all log entries
493
+ # in `entries` that do not specify a value for `log_name`. Example:
494
+ # `"projects/my-project/logs/syslog"`. See
495
+ # LogEntry.
496
+ # Corresponds to the JSON property `logName`
439
497
  # @return [String]
440
- attr_accessor :page_token
498
+ attr_accessor :log_name
441
499
 
442
- # Optional. If true, read access to all projects is not required and results
443
- # will be returned for the subset of projects for which read access is permitted
444
- # (empty subset is permitted).
500
+ # Optional. Whether valid entries should be written even if some other
501
+ # entries fail due to INVALID_ARGUMENT or PERMISSION_DENIED errors. If any
502
+ # entry is not written, the response status will be the error associated
503
+ # with one of the failed entries and include error details in the form of
504
+ # WriteLogEntriesPartialErrors.
445
505
  # Corresponds to the JSON property `partialSuccess`
446
506
  # @return [Boolean]
447
507
  attr_accessor :partial_success
448
508
  alias_method :partial_success?, :partial_success
449
509
 
450
- def initialize(**args)
451
- update!(**args)
452
- end
453
-
454
- # Update properties of this object
455
- def update!(**args)
456
- @project_ids = args[:project_ids] if args.key?(:project_ids)
457
- @filter = args[:filter] if args.key?(:filter)
458
- @order_by = args[:order_by] if args.key?(:order_by)
459
- @page_size = args[:page_size] if args.key?(:page_size)
460
- @page_token = args[:page_token] if args.key?(:page_token)
461
- @partial_success = args[:partial_success] if args.key?(:partial_success)
462
- end
463
- end
464
-
465
- # Result returned from `ListLogEntries`.
466
- class ListLogEntriesResponse
467
- include Google::Apis::Core::Hashable
468
-
469
- # A list of log entries.
470
- # Corresponds to the JSON property `entries`
471
- # @return [Array<Google::Apis::LoggingV2beta1::LogEntry>]
472
- attr_accessor :entries
473
-
474
- # If there are more results than were returned, then `nextPageToken` is included
475
- # in the response. To get the next set of results, call this method again using
476
- # the value of `nextPageToken` as `pageToken`.
477
- # Corresponds to the JSON property `nextPageToken`
478
- # @return [String]
479
- attr_accessor :next_page_token
480
-
481
- # If partial_success is true, contains the project ids that had errors and the
482
- # associated errors.
483
- # Corresponds to the JSON property `projectIdErrors`
484
- # @return [Hash<String,Google::Apis::LoggingV2beta1::Status>]
485
- attr_accessor :project_id_errors
510
+ # An object representing a resource that can be used for monitoring, logging,
511
+ # billing, or other purposes. Examples include virtual machine instances,
512
+ # databases, and storage devices such as disks. The `type` field identifies a
513
+ # MonitoredResourceDescriptor object that describes the resource's
514
+ # schema. Information in the `labels` field identifies the actual resource and
515
+ # its attributes according to the schema. For example, a particular Compute
516
+ # Engine VM instance could be represented by the following object, because the
517
+ # MonitoredResourceDescriptor for `"gce_instance"` has labels
518
+ # `"instance_id"` and `"zone"`:
519
+ # ` "type": "gce_instance",
520
+ # "labels": ` "instance_id": "12345678901234",
521
+ # "zone": "us-central1-a" ``
522
+ # Corresponds to the JSON property `resource`
523
+ # @return [Google::Apis::LoggingV2beta1::MonitoredResource]
524
+ attr_accessor :resource
486
525
 
487
526
  def initialize(**args)
488
527
  update!(**args)
@@ -490,64 +529,32 @@ module Google
490
529
 
491
530
  # Update properties of this object
492
531
  def update!(**args)
532
+ @labels = args[:labels] if args.key?(:labels)
493
533
  @entries = args[:entries] if args.key?(:entries)
494
- @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
495
- @project_id_errors = args[:project_id_errors] if args.key?(:project_id_errors)
534
+ @log_name = args[:log_name] if args.key?(:log_name)
535
+ @partial_success = args[:partial_success] if args.key?(:partial_success)
536
+ @resource = args[:resource] if args.key?(:resource)
496
537
  end
497
538
  end
498
539
 
499
- # The `Status` type defines a logical error model that is suitable for different
500
- # programming environments, including REST APIs and RPC APIs. It is used by [
501
- # gRPC](https://github.com/grpc). The error model is designed to be: - Simple to
502
- # use and understand for most users - Flexible enough to meet unexpected needs #
503
- # Overview The `Status` message contains three pieces of data: error code, error
504
- # message, and error details. The error code should be an enum value of google.
505
- # rpc.Code, but it may accept additional error codes if needed. The error
506
- # message should be a developer-facing English message that helps developers *
507
- # understand* and *resolve* the error. If a localized user-facing error message
508
- # is needed, put the localized message in the error details or localize it in
509
- # the client. The optional error details may contain arbitrary information about
510
- # the error. There is a predefined set of error detail types in the package `
511
- # google.rpc` which can be used for common error conditions. # Language mapping
512
- # The `Status` message is the logical representation of the error model, but it
513
- # is not necessarily the actual wire format. When the `Status` message is
514
- # exposed in different client libraries and different wire protocols, it can be
515
- # mapped differently. For example, it will likely be mapped to some exceptions
516
- # in Java, but more likely mapped to some error codes in C. # Other uses The
517
- # error model and the `Status` message can be used in a variety of environments,
518
- # either with or without APIs, to provide a consistent developer experience
519
- # across different environments. Example uses of this error model include: -
520
- # Partial errors. If a service needs to return partial errors to the client, it
521
- # may embed the `Status` in the normal response to indicate the partial errors. -
522
- # Workflow errors. A typical workflow has multiple steps. Each step may have a `
523
- # Status` message for error reporting purpose. - Batch operations. If a client
524
- # uses batch request and batch response, the `Status` message should be used
525
- # directly inside batch response, one for each error sub-response. -
526
- # Asynchronous operations. If an API call embeds asynchronous operation results
527
- # in its response, the status of those operations should be represented directly
528
- # using the `Status` message. - Logging. If some API errors are stored in logs,
529
- # the message `Status` could be used directly after any stripping needed for
530
- # security/privacy reasons.
531
- class Status
540
+ # A description of a label.
541
+ class LabelDescriptor
532
542
  include Google::Apis::Core::Hashable
533
543
 
534
- # The status code, which should be an enum value of google.rpc.Code.
535
- # Corresponds to the JSON property `code`
536
- # @return [Fixnum]
537
- attr_accessor :code
544
+ # A human-readable description for the label.
545
+ # Corresponds to the JSON property `description`
546
+ # @return [String]
547
+ attr_accessor :description
538
548
 
539
- # A developer-facing error message, which should be in English. Any user-facing
540
- # error message should be localized and sent in the google.rpc.Status.details
541
- # field, or localized by the client.
542
- # Corresponds to the JSON property `message`
549
+ # The type of data that can be assigned to the label.
550
+ # Corresponds to the JSON property `valueType`
543
551
  # @return [String]
544
- attr_accessor :message
552
+ attr_accessor :value_type
545
553
 
546
- # A list of messages that carry the error details. There will be a common set of
547
- # message types for APIs to use.
548
- # Corresponds to the JSON property `details`
549
- # @return [Array<Hash<String,Object>>]
550
- attr_accessor :details
554
+ # The label key.
555
+ # Corresponds to the JSON property `key`
556
+ # @return [String]
557
+ attr_accessor :key
551
558
 
552
559
  def initialize(**args)
553
560
  update!(**args)
@@ -555,24 +562,24 @@ module Google
555
562
 
556
563
  # Update properties of this object
557
564
  def update!(**args)
558
- @code = args[:code] if args.key?(:code)
559
- @message = args[:message] if args.key?(:message)
560
- @details = args[:details] if args.key?(:details)
565
+ @description = args[:description] if args.key?(:description)
566
+ @value_type = args[:value_type] if args.key?(:value_type)
567
+ @key = args[:key] if args.key?(:key)
561
568
  end
562
569
  end
563
570
 
564
- # Result returned from ListMonitoredResourceDescriptors.
565
- class ListMonitoredResourceDescriptorsResponse
571
+ # Result returned from ListLogMetrics.
572
+ class ListLogMetricsResponse
566
573
  include Google::Apis::Core::Hashable
567
574
 
568
- # A list of resource descriptors.
569
- # Corresponds to the JSON property `resourceDescriptors`
570
- # @return [Array<Google::Apis::LoggingV2beta1::MonitoredResourceDescriptor>]
571
- attr_accessor :resource_descriptors
575
+ # A list of logs-based metrics.
576
+ # Corresponds to the JSON property `metrics`
577
+ # @return [Array<Google::Apis::LoggingV2beta1::LogMetric>]
578
+ attr_accessor :metrics
572
579
 
573
- # If there are more results than were returned, then `nextPageToken` is included
574
- # in the response. To get the next set of results, call this method again using
575
- # the value of `nextPageToken` as `pageToken`.
580
+ # If there might be more results than appear in this response, then
581
+ # `nextPageToken` is included. To get the next set of results, call this
582
+ # method again using the value of `nextPageToken` as `pageToken`.
576
583
  # Corresponds to the JSON property `nextPageToken`
577
584
  # @return [String]
578
585
  attr_accessor :next_page_token
@@ -583,45 +590,32 @@ module Google
583
590
 
584
591
  # Update properties of this object
585
592
  def update!(**args)
586
- @resource_descriptors = args[:resource_descriptors] if args.key?(:resource_descriptors)
593
+ @metrics = args[:metrics] if args.key?(:metrics)
587
594
  @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
588
595
  end
589
596
  end
590
597
 
591
- # An object that describes the schema of a MonitoredResource object using a type
592
- # name and a set of labels. For example, the monitored resource descriptor for
593
- # Google Compute Engine VM instances has a type of `"gce_instance"` and
594
- # specifies the use of the labels `"instance_id"` and `"zone"` to identify
595
- # particular VM instances. Different APIs can support different monitored
596
- # resource types. APIs generally provide a `list` method that returns the
597
- # monitored resource descriptors used by the API.
598
+ # An object that describes the schema of a MonitoredResource object using a
599
+ # type name and a set of labels. For example, the monitored resource
600
+ # descriptor for Google Compute Engine VM instances has a type of
601
+ # `"gce_instance"` and specifies the use of the labels `"instance_id"` and
602
+ # `"zone"` to identify particular VM instances.
603
+ # Different APIs can support different monitored resource types. APIs generally
604
+ # provide a `list` method that returns the monitored resource descriptors used
605
+ # by the API.
598
606
  class MonitoredResourceDescriptor
599
607
  include Google::Apis::Core::Hashable
600
608
 
601
- # Optional. The resource name of the monitored resource descriptor: `"projects/`
602
- # project_id`/monitoredResourceDescriptors/`type`"` where `type` is the value of
603
- # the `type` field in this object and `project_id` is a project ID that provides
604
- # API-specific context for accessing the type. APIs that do not use project
605
- # information can use the resource name format `"monitoredResourceDescriptors/`
606
- # type`"`.
607
- # Corresponds to the JSON property `name`
608
- # @return [String]
609
- attr_accessor :name
610
-
611
- # Required. The monitored resource type. For example, the type `"
612
- # cloudsql_database"` represents databases in Google Cloud SQL.
613
- # Corresponds to the JSON property `type`
614
- # @return [String]
615
- attr_accessor :type
616
-
617
609
  # Optional. A concise name for the monitored resource type that might be
618
- # displayed in user interfaces. For example, `"Google Cloud SQL Database"`.
610
+ # displayed in user interfaces. It should be a Title Cased Noun Phrase,
611
+ # without any article or other determiners. For example,
612
+ # `"Google Cloud SQL Database"`.
619
613
  # Corresponds to the JSON property `displayName`
620
614
  # @return [String]
621
615
  attr_accessor :display_name
622
616
 
623
- # Optional. A detailed description of the monitored resource type that might be
624
- # used in documentation.
617
+ # Optional. A detailed description of the monitored resource type that might
618
+ # be used in documentation.
625
619
  # Corresponds to the JSON property `description`
626
620
  # @return [String]
627
621
  attr_accessor :description
@@ -633,38 +627,22 @@ module Google
633
627
  # @return [Array<Google::Apis::LoggingV2beta1::LabelDescriptor>]
634
628
  attr_accessor :labels
635
629
 
636
- def initialize(**args)
637
- update!(**args)
638
- end
639
-
640
- # Update properties of this object
641
- def update!(**args)
642
- @name = args[:name] if args.key?(:name)
643
- @type = args[:type] if args.key?(:type)
644
- @display_name = args[:display_name] if args.key?(:display_name)
645
- @description = args[:description] if args.key?(:description)
646
- @labels = args[:labels] if args.key?(:labels)
647
- end
648
- end
649
-
650
- # A description of a label.
651
- class LabelDescriptor
652
- include Google::Apis::Core::Hashable
653
-
654
- # The label key.
655
- # Corresponds to the JSON property `key`
656
- # @return [String]
657
- attr_accessor :key
658
-
659
- # The type of data that can be assigned to the label.
660
- # Corresponds to the JSON property `valueType`
630
+ # Required. The monitored resource type. For example, the type
631
+ # `"cloudsql_database"` represents databases in Google Cloud SQL.
632
+ # The maximum length of this value is 256 characters.
633
+ # Corresponds to the JSON property `type`
661
634
  # @return [String]
662
- attr_accessor :value_type
635
+ attr_accessor :type
663
636
 
664
- # A human-readable description for the label.
665
- # Corresponds to the JSON property `description`
637
+ # Optional. The resource name of the monitored resource descriptor:
638
+ # `"projects/`project_id`/monitoredResourceDescriptors/`type`"` where
639
+ # `type` is the value of the `type` field in this object and
640
+ # `project_id` is a project ID that provides API-specific context for
641
+ # accessing the type. APIs that do not use project information can use the
642
+ # resource name format `"monitoredResourceDescriptors/`type`"`.
643
+ # Corresponds to the JSON property `name`
666
644
  # @return [String]
667
- attr_accessor :description
645
+ attr_accessor :name
668
646
 
669
647
  def initialize(**args)
670
648
  update!(**args)
@@ -672,74 +650,70 @@ module Google
672
650
 
673
651
  # Update properties of this object
674
652
  def update!(**args)
675
- @key = args[:key] if args.key?(:key)
676
- @value_type = args[:value_type] if args.key?(:value_type)
653
+ @display_name = args[:display_name] if args.key?(:display_name)
677
654
  @description = args[:description] if args.key?(:description)
655
+ @labels = args[:labels] if args.key?(:labels)
656
+ @type = args[:type] if args.key?(:type)
657
+ @name = args[:name] if args.key?(:name)
678
658
  end
679
659
  end
680
660
 
681
- # Result returned from `ListSinks`.
682
- class ListSinksResponse
661
+ # Result returned from ListMonitoredResourceDescriptors.
662
+ class ListMonitoredResourceDescriptorsResponse
683
663
  include Google::Apis::Core::Hashable
684
664
 
685
- # A list of sinks.
686
- # Corresponds to the JSON property `sinks`
687
- # @return [Array<Google::Apis::LoggingV2beta1::LogSink>]
688
- attr_accessor :sinks
689
-
690
- # If there are more results than were returned, then `nextPageToken` is included
691
- # in the response. To get the next set of results, call this method again using
692
- # the value of `nextPageToken` as `pageToken`.
665
+ # If there might be more results than appear in this response, then
666
+ # `nextPageToken` is included. To get the next set of results, call this
667
+ # method again using the value of `nextPageToken` as `pageToken`.
693
668
  # Corresponds to the JSON property `nextPageToken`
694
669
  # @return [String]
695
670
  attr_accessor :next_page_token
696
671
 
672
+ # A list of resource descriptors.
673
+ # Corresponds to the JSON property `resourceDescriptors`
674
+ # @return [Array<Google::Apis::LoggingV2beta1::MonitoredResourceDescriptor>]
675
+ attr_accessor :resource_descriptors
676
+
697
677
  def initialize(**args)
698
678
  update!(**args)
699
679
  end
700
680
 
701
681
  # Update properties of this object
702
682
  def update!(**args)
703
- @sinks = args[:sinks] if args.key?(:sinks)
704
683
  @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
684
+ @resource_descriptors = args[:resource_descriptors] if args.key?(:resource_descriptors)
705
685
  end
706
686
  end
707
687
 
708
- # Describes a sink used to export log entries outside Cloud Logging.
709
- class LogSink
688
+ # Additional information about a potentially long-running operation with which
689
+ # a log entry is associated.
690
+ class LogEntryOperation
710
691
  include Google::Apis::Core::Hashable
711
692
 
712
- # Required. The client-assigned sink identifier. Example: `"my-severe-errors-to-
713
- # pubsub"`. Sink identifiers are limited to 1000 characters and can include only
714
- # the following characters: `A-Z`, `a-z`, `0-9`, and the special characters `_-.`
715
- # .
716
- # Corresponds to the JSON property `name`
693
+ # Optional. An arbitrary producer identifier. The combination of
694
+ # `id` and `producer` must be globally unique. Examples for `producer`:
695
+ # `"MyDivision.MyBigCompany.com"`, `"github.com/MyProject/MyApplication"`.
696
+ # Corresponds to the JSON property `producer`
717
697
  # @return [String]
718
- attr_accessor :name
698
+ attr_accessor :producer
719
699
 
720
- # The export destination. See [Exporting Logs With Sinks](/logging/docs/api/
721
- # tasks/exporting-logs). Examples: `"storage.googleapis.com/a-bucket"`, `"
722
- # bigquery.googleapis.com/projects/a-project-id/datasets/a-dataset"`.
723
- # Corresponds to the JSON property `destination`
724
- # @return [String]
725
- attr_accessor :destination
700
+ # Optional. Set this to True if this is the last log entry in the operation.
701
+ # Corresponds to the JSON property `last`
702
+ # @return [Boolean]
703
+ attr_accessor :last
704
+ alias_method :last?, :last
726
705
 
727
- # An [advanced logs filter](/logging/docs/view/advanced_filters). Only log
728
- # entries matching that filter are exported. The filter must be consistent with
729
- # the log entry format specified by the `outputVersionFormat` parameter,
730
- # regardless of the format of the log entry that was originally written to Cloud
731
- # Logging. Example (V2 format): `"logName=projects/my-projectid/logs/syslog AND
732
- # severity>=ERROR"`.
733
- # Corresponds to the JSON property `filter`
734
- # @return [String]
735
- attr_accessor :filter
706
+ # Optional. Set this to True if this is the first log entry in the operation.
707
+ # Corresponds to the JSON property `first`
708
+ # @return [Boolean]
709
+ attr_accessor :first
710
+ alias_method :first?, :first
736
711
 
737
- # The log entry version to use for this sink's exported log entries. This
738
- # version does not have to correspond to the version of the log entry when it
739
- # was written to Cloud Logging.
740
- # Corresponds to the JSON property `outputVersionFormat`
712
+ # Optional. An arbitrary operation identifier. Log entries with the
713
+ # same identifier are assumed to be part of the same operation.
714
+ # Corresponds to the JSON property `id`
741
715
  # @return [String]
742
- attr_accessor :output_version_format
716
+ attr_accessor :id
743
717
 
744
718
  def initialize(**args)
745
719
  update!(**args)
@@ -747,64 +721,125 @@ module Google
747
721
 
748
722
  # Update properties of this object
749
723
  def update!(**args)
750
- @name = args[:name] if args.key?(:name)
751
- @destination = args[:destination] if args.key?(:destination)
752
- @filter = args[:filter] if args.key?(:filter)
753
- @output_version_format = args[:output_version_format] if args.key?(:output_version_format)
724
+ @producer = args[:producer] if args.key?(:producer)
725
+ @last = args[:last] if args.key?(:last)
726
+ @first = args[:first] if args.key?(:first)
727
+ @id = args[:id] if args.key?(:id)
754
728
  end
755
729
  end
756
730
 
757
- # Result returned from ListLogMetrics.
758
- class ListLogMetricsResponse
731
+ # A generic empty message that you can re-use to avoid defining duplicated
732
+ # empty messages in your APIs. A typical example is to use it as the request
733
+ # or the response type of an API method. For instance:
734
+ # service Foo `
735
+ # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
736
+ # `
737
+ # The JSON representation for `Empty` is empty JSON object ````.
738
+ class Empty
759
739
  include Google::Apis::Core::Hashable
760
740
 
761
- # A list of logs-based metrics.
762
- # Corresponds to the JSON property `metrics`
763
- # @return [Array<Google::Apis::LoggingV2beta1::LogMetric>]
764
- attr_accessor :metrics
765
-
766
- # If there are more results than were returned, then `nextPageToken` is included
767
- # in the response. To get the next set of results, call this method again using
768
- # the value of `nextPageToken` as `pageToken`.
769
- # Corresponds to the JSON property `nextPageToken`
770
- # @return [String]
771
- attr_accessor :next_page_token
772
-
773
741
  def initialize(**args)
774
742
  update!(**args)
775
743
  end
776
744
 
777
745
  # Update properties of this object
778
746
  def update!(**args)
779
- @metrics = args[:metrics] if args.key?(:metrics)
780
- @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
781
747
  end
782
748
  end
783
749
 
784
- # Describes a logs-based metric. The value of the metric is the number of log
785
- # entries that match a logs filter.
786
- class LogMetric
750
+ # A common proto for logging HTTP requests. Only contains semantics
751
+ # defined by the HTTP specification. Product-specific logging
752
+ # information MUST be defined in a separate message.
753
+ class HttpRequest
787
754
  include Google::Apis::Core::Hashable
788
755
 
789
- # Required. The client-assigned metric identifier. Example: `"severe_errors"`.
790
- # Metric identifiers are limited to 1000 characters and can include only the
791
- # following characters: `A-Z`, `a-z`, `0-9`, and the special characters `_-.,+!*'
792
- # ,()%/\`. The forward-slash character (`/`) denotes a hierarchy of name pieces,
793
- # and it cannot be the first character of the name.
794
- # Corresponds to the JSON property `name`
756
+ # Whether or not a cache lookup was attempted.
757
+ # Corresponds to the JSON property `cacheLookup`
758
+ # @return [Boolean]
759
+ attr_accessor :cache_lookup
760
+ alias_method :cache_lookup?, :cache_lookup
761
+
762
+ # The size of the HTTP response message sent back to the client, in bytes,
763
+ # including the response headers and the response body.
764
+ # Corresponds to the JSON property `responseSize`
795
765
  # @return [String]
796
- attr_accessor :name
766
+ attr_accessor :response_size
797
767
 
798
- # A description of this metric, which is used in documentation.
799
- # Corresponds to the JSON property `description`
768
+ # The response code indicating the status of response.
769
+ # Examples: 200, 404.
770
+ # Corresponds to the JSON property `status`
771
+ # @return [Fixnum]
772
+ attr_accessor :status
773
+
774
+ # Whether or not the response was validated with the origin server before
775
+ # being served from cache. This field is only meaningful if `cache_hit` is
776
+ # True.
777
+ # Corresponds to the JSON property `cacheValidatedWithOriginServer`
778
+ # @return [Boolean]
779
+ attr_accessor :cache_validated_with_origin_server
780
+ alias_method :cache_validated_with_origin_server?, :cache_validated_with_origin_server
781
+
782
+ # The referer URL of the request, as defined in
783
+ # [HTTP/1.1 Header Field Definitions](http://www.w3.org/Protocols/rfc2616/
784
+ # rfc2616-sec14.html).
785
+ # Corresponds to the JSON property `referer`
800
786
  # @return [String]
801
- attr_accessor :description
787
+ attr_accessor :referer
802
788
 
803
- # An [advanced logs filter](/logging/docs/view/advanced_filters). Example: `"
804
- # logName:syslog AND severity>=ERROR"`.
805
- # Corresponds to the JSON property `filter`
789
+ # Whether or not an entity was served from cache
790
+ # (with or without validation).
791
+ # Corresponds to the JSON property `cacheHit`
792
+ # @return [Boolean]
793
+ attr_accessor :cache_hit
794
+ alias_method :cache_hit?, :cache_hit
795
+
796
+ # The scheme (http, https), the host name, the path and the query
797
+ # portion of the URL that was requested.
798
+ # Example: `"http://example.com/some/info?color=red"`.
799
+ # Corresponds to the JSON property `requestUrl`
806
800
  # @return [String]
807
- attr_accessor :filter
801
+ attr_accessor :request_url
802
+
803
+ # The request processing latency on the server, from the time the request was
804
+ # received until the response was sent.
805
+ # Corresponds to the JSON property `latency`
806
+ # @return [String]
807
+ attr_accessor :latency
808
+
809
+ # The number of HTTP response bytes inserted into cache. Set only when a
810
+ # cache fill was attempted.
811
+ # Corresponds to the JSON property `cacheFillBytes`
812
+ # @return [String]
813
+ attr_accessor :cache_fill_bytes
814
+
815
+ # The request method. Examples: `"GET"`, `"HEAD"`, `"PUT"`, `"POST"`.
816
+ # Corresponds to the JSON property `requestMethod`
817
+ # @return [String]
818
+ attr_accessor :request_method
819
+
820
+ # The IP address (IPv4 or IPv6) of the client that issued the HTTP
821
+ # request. Examples: `"192.168.1.1"`, `"FE80::0202:B3FF:FE1E:8329"`.
822
+ # Corresponds to the JSON property `remoteIp`
823
+ # @return [String]
824
+ attr_accessor :remote_ip
825
+
826
+ # The IP address (IPv4 or IPv6) of the origin server that the request was
827
+ # sent to.
828
+ # Corresponds to the JSON property `serverIp`
829
+ # @return [String]
830
+ attr_accessor :server_ip
831
+
832
+ # The user agent sent by the client. Example:
833
+ # `"Mozilla/4.0 (compatible; MSIE 6.0; Windows 98; Q312461; .NET CLR 1.0.3705)"`.
834
+ # Corresponds to the JSON property `userAgent`
835
+ # @return [String]
836
+ attr_accessor :user_agent
837
+
838
+ # The size of the HTTP request message in bytes, including the request
839
+ # headers and the request body.
840
+ # Corresponds to the JSON property `requestSize`
841
+ # @return [String]
842
+ attr_accessor :request_size
808
843
 
809
844
  def initialize(**args)
810
845
  update!(**args)
@@ -812,9 +847,20 @@ module Google
812
847
 
813
848
  # Update properties of this object
814
849
  def update!(**args)
815
- @name = args[:name] if args.key?(:name)
816
- @description = args[:description] if args.key?(:description)
817
- @filter = args[:filter] if args.key?(:filter)
850
+ @cache_lookup = args[:cache_lookup] if args.key?(:cache_lookup)
851
+ @response_size = args[:response_size] if args.key?(:response_size)
852
+ @status = args[:status] if args.key?(:status)
853
+ @cache_validated_with_origin_server = args[:cache_validated_with_origin_server] if args.key?(:cache_validated_with_origin_server)
854
+ @referer = args[:referer] if args.key?(:referer)
855
+ @cache_hit = args[:cache_hit] if args.key?(:cache_hit)
856
+ @request_url = args[:request_url] if args.key?(:request_url)
857
+ @latency = args[:latency] if args.key?(:latency)
858
+ @cache_fill_bytes = args[:cache_fill_bytes] if args.key?(:cache_fill_bytes)
859
+ @request_method = args[:request_method] if args.key?(:request_method)
860
+ @remote_ip = args[:remote_ip] if args.key?(:remote_ip)
861
+ @server_ip = args[:server_ip] if args.key?(:server_ip)
862
+ @user_agent = args[:user_agent] if args.key?(:user_agent)
863
+ @request_size = args[:request_size] if args.key?(:request_size)
818
864
  end
819
865
  end
820
866
 
@@ -823,182 +869,184 @@ module Google
823
869
  class RequestLog
824
870
  include Google::Apis::Core::Hashable
825
871
 
826
- # Application that handled this request.
827
- # Corresponds to the JSON property `appId`
872
+ # Size in bytes sent back to client by request.
873
+ # Corresponds to the JSON property `responseSize`
828
874
  # @return [String]
829
- attr_accessor :app_id
875
+ attr_accessor :response_size
830
876
 
831
- # Module of the application that handled this request.
832
- # Corresponds to the JSON property `moduleId`
877
+ # Globally unique identifier for a request, which is based on the request
878
+ # start time. Request IDs for requests which started later will compare
879
+ # greater as strings than those for requests which started earlier.
880
+ # Corresponds to the JSON property `requestId`
833
881
  # @return [String]
834
- attr_accessor :module_id
882
+ attr_accessor :request_id
883
+
884
+ # Whether this is the first `RequestLog` entry for this request. If an
885
+ # active request has several `RequestLog` entries written to Stackdriver
886
+ # Logging, then this field will be set for one of them.
887
+ # Corresponds to the JSON property `first`
888
+ # @return [Boolean]
889
+ attr_accessor :first
890
+ alias_method :first?, :first
891
+
892
+ # Request method. Example: `"GET"`, `"HEAD"`, `"PUT"`, `"POST"`, `"DELETE"`.
893
+ # Corresponds to the JSON property `method`
894
+ # @return [String]
895
+ attr_accessor :method_prop
835
896
 
836
897
  # Version of the application that handled this request.
837
898
  # Corresponds to the JSON property `versionId`
838
899
  # @return [String]
839
900
  attr_accessor :version_id
840
901
 
841
- # Globally unique identifier for a request, which is based on the request start
842
- # time. Request IDs for requests which started later will compare greater as
843
- # strings than those for requests which started earlier.
844
- # Corresponds to the JSON property `requestId`
845
- # @return [String]
846
- attr_accessor :request_id
902
+ # HTTP response status code. Example: 200, 404.
903
+ # Corresponds to the JSON property `status`
904
+ # @return [Fixnum]
905
+ attr_accessor :status
906
+
907
+ # Whether this was a loading request for the instance.
908
+ # Corresponds to the JSON property `wasLoadingRequest`
909
+ # @return [Boolean]
910
+ attr_accessor :was_loading_request
911
+ alias_method :was_loading_request?, :was_loading_request
847
912
 
848
913
  # Origin IP address.
849
914
  # Corresponds to the JSON property `ip`
850
915
  # @return [String]
851
916
  attr_accessor :ip
852
917
 
853
- # Time when the request started.
854
- # Corresponds to the JSON property `startTime`
855
- # @return [String]
856
- attr_accessor :start_time
857
-
858
- # Time when the request finished.
859
- # Corresponds to the JSON property `endTime`
860
- # @return [String]
861
- attr_accessor :end_time
862
-
863
- # Latency of the request.
864
- # Corresponds to the JSON property `latency`
865
- # @return [String]
866
- attr_accessor :latency
867
-
868
- # Number of CPU megacycles used to process request.
869
- # Corresponds to the JSON property `megaCycles`
870
- # @return [String]
871
- attr_accessor :mega_cycles
872
-
873
- # Request method. Example: `"GET"`, `"HEAD"`, `"PUT"`, `"POST"`, `"DELETE"`.
874
- # Corresponds to the JSON property `method`
918
+ # The logged-in user who made the request.
919
+ # Most likely, this is the part of the user's email before the `@` sign. The
920
+ # field value is the same for different requests from the same user, but
921
+ # different users can have similar names. This information is also
922
+ # available to the application via the App Engine Users API.
923
+ # This field will be populated starting with App Engine 1.9.21.
924
+ # Corresponds to the JSON property `nickname`
875
925
  # @return [String]
876
- attr_accessor :method_prop
926
+ attr_accessor :nickname
877
927
 
878
- # Contains the path and query portion of the URL that was requested. For example,
879
- # if the URL was "http://example.com/app?name=val", the resource would be "/app?
880
- # name=val". The fragment identifier, which is identified by the `#` character,
881
- # is not included.
882
- # Corresponds to the JSON property `resource`
928
+ # Queue name of the request, in the case of an offline request.
929
+ # Corresponds to the JSON property `taskQueueName`
883
930
  # @return [String]
884
- attr_accessor :resource
931
+ attr_accessor :task_queue_name
885
932
 
886
- # HTTP version of request. Example: `"HTTP/1.1"`.
887
- # Corresponds to the JSON property `httpVersion`
933
+ # Time this request spent in the pending request queue.
934
+ # Corresponds to the JSON property `pendingTime`
888
935
  # @return [String]
889
- attr_accessor :http_version
936
+ attr_accessor :pending_time
890
937
 
891
- # HTTP response status code. Example: 200, 404.
892
- # Corresponds to the JSON property `status`
938
+ # If the instance processing this request belongs to a manually scaled
939
+ # module, then this is the 0-based index of the instance. Otherwise, this
940
+ # value is -1.
941
+ # Corresponds to the JSON property `instanceIndex`
893
942
  # @return [Fixnum]
894
- attr_accessor :status
943
+ attr_accessor :instance_index
895
944
 
896
- # Size in bytes sent back to client by request.
897
- # Corresponds to the JSON property `responseSize`
898
- # @return [String]
899
- attr_accessor :response_size
945
+ # Source code for the application that handled this request. There can be
946
+ # more than one source reference per deployed application if source code is
947
+ # distributed among multiple repositories.
948
+ # Corresponds to the JSON property `sourceReference`
949
+ # @return [Array<Google::Apis::LoggingV2beta1::SourceReference>]
950
+ attr_accessor :source_reference
900
951
 
901
- # Referrer URL of request.
902
- # Corresponds to the JSON property `referrer`
952
+ # Module of the application that handled this request.
953
+ # Corresponds to the JSON property `moduleId`
903
954
  # @return [String]
904
- attr_accessor :referrer
955
+ attr_accessor :module_id
905
956
 
906
- # User agent that made the request.
907
- # Corresponds to the JSON property `userAgent`
957
+ # Internet host and port number of the resource being requested.
958
+ # Corresponds to the JSON property `host`
908
959
  # @return [String]
909
- attr_accessor :user_agent
960
+ attr_accessor :host
910
961
 
911
- # The logged-in user who made the request. Most likely, this is the part of the
912
- # user's email before the `@` sign. The field value is the same for different
913
- # requests from the same user, but different users can have similar names. This
914
- # information is also available to the application via the App Engine Users API.
915
- # This field will be populated starting with App Engine 1.9.21.
916
- # Corresponds to the JSON property `nickname`
962
+ # Latency of the request.
963
+ # Corresponds to the JSON property `latency`
917
964
  # @return [String]
918
- attr_accessor :nickname
965
+ attr_accessor :latency
919
966
 
920
967
  # File or class that handled the request.
921
968
  # Corresponds to the JSON property `urlMapEntry`
922
969
  # @return [String]
923
970
  attr_accessor :url_map_entry
924
971
 
925
- # Internet host and port number of the resource being requested.
926
- # Corresponds to the JSON property `host`
972
+ # Time when the request finished.
973
+ # Corresponds to the JSON property `endTime`
927
974
  # @return [String]
928
- attr_accessor :host
975
+ attr_accessor :end_time
929
976
 
930
- # An indication of the relative cost of serving this request.
931
- # Corresponds to the JSON property `cost`
932
- # @return [Float]
933
- attr_accessor :cost
977
+ # A list of log lines emitted by the application while serving this request.
978
+ # Corresponds to the JSON property `line`
979
+ # @return [Array<Google::Apis::LoggingV2beta1::LogLine>]
980
+ attr_accessor :line
934
981
 
935
- # Queue name of the request, in the case of an offline request.
936
- # Corresponds to the JSON property `taskQueueName`
982
+ # Number of CPU megacycles used to process request.
983
+ # Corresponds to the JSON property `megaCycles`
937
984
  # @return [String]
938
- attr_accessor :task_queue_name
985
+ attr_accessor :mega_cycles
939
986
 
940
- # Task name of the request, in the case of an offline request.
941
- # Corresponds to the JSON property `taskName`
987
+ # Application that handled this request.
988
+ # Corresponds to the JSON property `appId`
942
989
  # @return [String]
943
- attr_accessor :task_name
944
-
945
- # Whether this was a loading request for the instance.
946
- # Corresponds to the JSON property `wasLoadingRequest`
947
- # @return [Boolean]
948
- attr_accessor :was_loading_request
949
- alias_method :was_loading_request?, :was_loading_request
990
+ attr_accessor :app_id
950
991
 
951
- # Time this request spent in the pending request queue.
952
- # Corresponds to the JSON property `pendingTime`
992
+ # Stackdriver Trace identifier for this request.
993
+ # Corresponds to the JSON property `traceId`
953
994
  # @return [String]
954
- attr_accessor :pending_time
955
-
956
- # If the instance processing this request belongs to a manually scaled module,
957
- # then this is the 0-based index of the instance. Otherwise, this value is -1.
958
- # Corresponds to the JSON property `instanceIndex`
959
- # @return [Fixnum]
960
- attr_accessor :instance_index
995
+ attr_accessor :trace_id
961
996
 
962
- # Whether this request is finished or active.
963
- # Corresponds to the JSON property `finished`
964
- # @return [Boolean]
965
- attr_accessor :finished
966
- alias_method :finished?, :finished
997
+ # Task name of the request, in the case of an offline request.
998
+ # Corresponds to the JSON property `taskName`
999
+ # @return [String]
1000
+ attr_accessor :task_name
967
1001
 
968
- # Whether this is the first RequestLog entry for this request. If an active
969
- # request has several RequestLog entries written to Cloud Logging, this field
970
- # will be set for one of them.
971
- # Corresponds to the JSON property `first`
972
- # @return [Boolean]
973
- attr_accessor :first
974
- alias_method :first?, :first
1002
+ # An indication of the relative cost of serving this request.
1003
+ # Corresponds to the JSON property `cost`
1004
+ # @return [Float]
1005
+ attr_accessor :cost
975
1006
 
976
1007
  # An identifier for the instance that handled the request.
977
1008
  # Corresponds to the JSON property `instanceId`
978
1009
  # @return [String]
979
1010
  attr_accessor :instance_id
980
1011
 
981
- # A list of log lines emitted by the application while serving this request.
982
- # Corresponds to the JSON property `line`
983
- # @return [Array<Google::Apis::LoggingV2beta1::LogLine>]
984
- attr_accessor :line
1012
+ # Time when the request started.
1013
+ # Corresponds to the JSON property `startTime`
1014
+ # @return [String]
1015
+ attr_accessor :start_time
985
1016
 
986
1017
  # App Engine release version.
987
1018
  # Corresponds to the JSON property `appEngineRelease`
988
1019
  # @return [String]
989
1020
  attr_accessor :app_engine_release
990
1021
 
991
- # Cloud Trace identifier for this request.
992
- # Corresponds to the JSON property `traceId`
1022
+ # Contains the path and query portion of the URL that was requested. For
1023
+ # example, if the URL was "http://example.com/app?name=val", the resource
1024
+ # would be "/app?name=val". The fragment identifier, which is identified by
1025
+ # the `#` character, is not included.
1026
+ # Corresponds to the JSON property `resource`
993
1027
  # @return [String]
994
- attr_accessor :trace_id
1028
+ attr_accessor :resource
995
1029
 
996
- # Source code for the application that handled this request. There can be more
997
- # than one source reference per deployed application if source code is
998
- # distributed among multiple repositories.
999
- # Corresponds to the JSON property `sourceReference`
1000
- # @return [Array<Google::Apis::LoggingV2beta1::SourceReference>]
1001
- attr_accessor :source_reference
1030
+ # HTTP version of request. Example: `"HTTP/1.1"`.
1031
+ # Corresponds to the JSON property `httpVersion`
1032
+ # @return [String]
1033
+ attr_accessor :http_version
1034
+
1035
+ # Referrer URL of request.
1036
+ # Corresponds to the JSON property `referrer`
1037
+ # @return [String]
1038
+ attr_accessor :referrer
1039
+
1040
+ # User agent that made the request.
1041
+ # Corresponds to the JSON property `userAgent`
1042
+ # @return [String]
1043
+ attr_accessor :user_agent
1044
+
1045
+ # Whether this request is finished or active.
1046
+ # Corresponds to the JSON property `finished`
1047
+ # @return [Boolean]
1048
+ attr_accessor :finished
1049
+ alias_method :finished?, :finished
1002
1050
 
1003
1051
  def initialize(**args)
1004
1052
  update!(**args)
@@ -1006,130 +1054,107 @@ module Google
1006
1054
 
1007
1055
  # Update properties of this object
1008
1056
  def update!(**args)
1009
- @app_id = args[:app_id] if args.key?(:app_id)
1010
- @module_id = args[:module_id] if args.key?(:module_id)
1011
- @version_id = args[:version_id] if args.key?(:version_id)
1057
+ @response_size = args[:response_size] if args.key?(:response_size)
1012
1058
  @request_id = args[:request_id] if args.key?(:request_id)
1013
- @ip = args[:ip] if args.key?(:ip)
1014
- @start_time = args[:start_time] if args.key?(:start_time)
1015
- @end_time = args[:end_time] if args.key?(:end_time)
1016
- @latency = args[:latency] if args.key?(:latency)
1017
- @mega_cycles = args[:mega_cycles] if args.key?(:mega_cycles)
1059
+ @first = args[:first] if args.key?(:first)
1018
1060
  @method_prop = args[:method_prop] if args.key?(:method_prop)
1019
- @resource = args[:resource] if args.key?(:resource)
1020
- @http_version = args[:http_version] if args.key?(:http_version)
1061
+ @version_id = args[:version_id] if args.key?(:version_id)
1021
1062
  @status = args[:status] if args.key?(:status)
1022
- @response_size = args[:response_size] if args.key?(:response_size)
1023
- @referrer = args[:referrer] if args.key?(:referrer)
1024
- @user_agent = args[:user_agent] if args.key?(:user_agent)
1063
+ @was_loading_request = args[:was_loading_request] if args.key?(:was_loading_request)
1064
+ @ip = args[:ip] if args.key?(:ip)
1025
1065
  @nickname = args[:nickname] if args.key?(:nickname)
1026
- @url_map_entry = args[:url_map_entry] if args.key?(:url_map_entry)
1027
- @host = args[:host] if args.key?(:host)
1028
- @cost = args[:cost] if args.key?(:cost)
1029
1066
  @task_queue_name = args[:task_queue_name] if args.key?(:task_queue_name)
1030
- @task_name = args[:task_name] if args.key?(:task_name)
1031
- @was_loading_request = args[:was_loading_request] if args.key?(:was_loading_request)
1032
1067
  @pending_time = args[:pending_time] if args.key?(:pending_time)
1033
1068
  @instance_index = args[:instance_index] if args.key?(:instance_index)
1034
- @finished = args[:finished] if args.key?(:finished)
1035
- @first = args[:first] if args.key?(:first)
1036
- @instance_id = args[:instance_id] if args.key?(:instance_id)
1069
+ @source_reference = args[:source_reference] if args.key?(:source_reference)
1070
+ @module_id = args[:module_id] if args.key?(:module_id)
1071
+ @host = args[:host] if args.key?(:host)
1072
+ @latency = args[:latency] if args.key?(:latency)
1073
+ @url_map_entry = args[:url_map_entry] if args.key?(:url_map_entry)
1074
+ @end_time = args[:end_time] if args.key?(:end_time)
1037
1075
  @line = args[:line] if args.key?(:line)
1038
- @app_engine_release = args[:app_engine_release] if args.key?(:app_engine_release)
1076
+ @mega_cycles = args[:mega_cycles] if args.key?(:mega_cycles)
1077
+ @app_id = args[:app_id] if args.key?(:app_id)
1039
1078
  @trace_id = args[:trace_id] if args.key?(:trace_id)
1040
- @source_reference = args[:source_reference] if args.key?(:source_reference)
1079
+ @task_name = args[:task_name] if args.key?(:task_name)
1080
+ @cost = args[:cost] if args.key?(:cost)
1081
+ @instance_id = args[:instance_id] if args.key?(:instance_id)
1082
+ @start_time = args[:start_time] if args.key?(:start_time)
1083
+ @app_engine_release = args[:app_engine_release] if args.key?(:app_engine_release)
1084
+ @resource = args[:resource] if args.key?(:resource)
1085
+ @http_version = args[:http_version] if args.key?(:http_version)
1086
+ @referrer = args[:referrer] if args.key?(:referrer)
1087
+ @user_agent = args[:user_agent] if args.key?(:user_agent)
1088
+ @finished = args[:finished] if args.key?(:finished)
1041
1089
  end
1042
1090
  end
1043
1091
 
1044
- # Application log line emitted while processing a request.
1045
- class LogLine
1092
+ # Result returned from WriteLogEntries.
1093
+ # empty
1094
+ class WriteLogEntriesResponse
1046
1095
  include Google::Apis::Core::Hashable
1047
1096
 
1048
- # Approximate time when this log entry was made.
1049
- # Corresponds to the JSON property `time`
1050
- # @return [String]
1051
- attr_accessor :time
1052
-
1053
- # Severity of this log entry.
1054
- # Corresponds to the JSON property `severity`
1055
- # @return [String]
1056
- attr_accessor :severity
1057
-
1058
- # App-provided log message.
1059
- # Corresponds to the JSON property `logMessage`
1060
- # @return [String]
1061
- attr_accessor :log_message
1062
-
1063
- # Specifies a location in a source code file.
1064
- # Corresponds to the JSON property `sourceLocation`
1065
- # @return [Google::Apis::LoggingV2beta1::SourceLocation]
1066
- attr_accessor :source_location
1067
-
1068
1097
  def initialize(**args)
1069
1098
  update!(**args)
1070
1099
  end
1071
1100
 
1072
1101
  # Update properties of this object
1073
1102
  def update!(**args)
1074
- @time = args[:time] if args.key?(:time)
1075
- @severity = args[:severity] if args.key?(:severity)
1076
- @log_message = args[:log_message] if args.key?(:log_message)
1077
- @source_location = args[:source_location] if args.key?(:source_location)
1078
1103
  end
1079
1104
  end
1080
1105
 
1081
- # Specifies a location in a source code file.
1082
- class SourceLocation
1106
+ # The parameters to `ListLogEntries`.
1107
+ class ListLogEntriesRequest
1083
1108
  include Google::Apis::Core::Hashable
1084
1109
 
1085
- # Source file name. Depending on the runtime environment, this might be a simple
1086
- # name or a fully-qualified name.
1087
- # Corresponds to the JSON property `file`
1088
- # @return [String]
1089
- attr_accessor :file
1090
-
1091
- # Line within the source file.
1092
- # Corresponds to the JSON property `line`
1093
- # @return [String]
1094
- attr_accessor :line
1095
-
1096
- # Human-readable name of the function or method being invoked, with optional
1097
- # context such as the class or package name. This information is used in
1098
- # contexts such as the logs viewer, where a file and line number are less
1099
- # meaningful. The format can vary by language. For example: `qual.if.ied.Class.
1100
- # method` (Java), `dir/package.func` (Go), `function` (Python).
1101
- # Corresponds to the JSON property `functionName`
1110
+ # Optional. A filter that chooses which log entries to return. See [Advanced
1111
+ # Logs Filters](/logging/docs/view/advanced_filters). Only log entries that
1112
+ # match the filter are returned. An empty filter matches all log entries.
1113
+ # The maximum length of the filter is 20000 characters.
1114
+ # Corresponds to the JSON property `filter`
1102
1115
  # @return [String]
1103
- attr_accessor :function_name
1116
+ attr_accessor :filter
1104
1117
 
1105
- def initialize(**args)
1106
- update!(**args)
1107
- end
1118
+ # Deprecated. One or more project identifiers or project numbers from which
1119
+ # to retrieve log entries. Examples: `"my-project-1A"`, `"1234567890"`. If
1120
+ # present, these project identifiers are converted to resource format and
1121
+ # added to the list of resources in `resourceNames`. Callers should use
1122
+ # `resourceNames` rather than this parameter.
1123
+ # Corresponds to the JSON property `projectIds`
1124
+ # @return [Array<String>]
1125
+ attr_accessor :project_ids
1108
1126
 
1109
- # Update properties of this object
1110
- def update!(**args)
1111
- @file = args[:file] if args.key?(:file)
1112
- @line = args[:line] if args.key?(:line)
1113
- @function_name = args[:function_name] if args.key?(:function_name)
1114
- end
1115
- end
1127
+ # Required. One or more cloud resources from which to retrieve log entries.
1128
+ # Example: `"projects/my-project-1A"`, `"projects/1234567890"`. Projects
1129
+ # listed in `projectIds` are added to this list.
1130
+ # Corresponds to the JSON property `resourceNames`
1131
+ # @return [Array<String>]
1132
+ attr_accessor :resource_names
1116
1133
 
1117
- # A reference to a particular snapshot of the source tree used to build and
1118
- # deploy an application.
1119
- class SourceReference
1120
- include Google::Apis::Core::Hashable
1134
+ # Optional. The maximum number of results to return from this request.
1135
+ # Non-positive values are ignored. The presence of `nextPageToken` in the
1136
+ # response indicates that more results might be available.
1137
+ # Corresponds to the JSON property `pageSize`
1138
+ # @return [Fixnum]
1139
+ attr_accessor :page_size
1121
1140
 
1122
- # Optional. A URI string identifying the repository. Example: "https://github.
1123
- # com/GoogleCloudPlatform/kubernetes.git"
1124
- # Corresponds to the JSON property `repository`
1141
+ # Optional. How the results should be sorted. Presently, the only permitted
1142
+ # values are `"timestamp asc"` (default) and `"timestamp desc"`. The first
1143
+ # option returns entries in order of increasing values of
1144
+ # `LogEntry.timestamp` (oldest first), and the second option returns entries
1145
+ # in order of decreasing timestamps (newest first). Entries with equal
1146
+ # timestamps are returned in order of `LogEntry.insertId`.
1147
+ # Corresponds to the JSON property `orderBy`
1125
1148
  # @return [String]
1126
- attr_accessor :repository
1149
+ attr_accessor :order_by
1127
1150
 
1128
- # The canonical and persistent identifier of the deployed revision. Example (git)
1129
- # : "0035781c50ec7aa23385dc841529ce8a4b70db1b"
1130
- # Corresponds to the JSON property `revisionId`
1151
+ # Optional. If present, then retrieve the next batch of results from the
1152
+ # preceding call to this method. `pageToken` must be the value of
1153
+ # `nextPageToken` from the previous response. The values of other method
1154
+ # parameters should be identical to those in the previous call.
1155
+ # Corresponds to the JSON property `pageToken`
1131
1156
  # @return [String]
1132
- attr_accessor :revision_id
1157
+ attr_accessor :page_token
1133
1158
 
1134
1159
  def initialize(**args)
1135
1160
  update!(**args)
@@ -1137,8 +1162,12 @@ module Google
1137
1162
 
1138
1163
  # Update properties of this object
1139
1164
  def update!(**args)
1140
- @repository = args[:repository] if args.key?(:repository)
1141
- @revision_id = args[:revision_id] if args.key?(:revision_id)
1165
+ @filter = args[:filter] if args.key?(:filter)
1166
+ @project_ids = args[:project_ids] if args.key?(:project_ids)
1167
+ @resource_names = args[:resource_names] if args.key?(:resource_names)
1168
+ @page_size = args[:page_size] if args.key?(:page_size)
1169
+ @order_by = args[:order_by] if args.key?(:order_by)
1170
+ @page_token = args[:page_token] if args.key?(:page_token)
1142
1171
  end
1143
1172
  end
1144
1173
  end