@@ -23,11 +23,10 @@ import Network.Google.Prelude
2323-- | An object that describes the schema of a MonitoredResource object using
2424-- a type name and a set of labels. For example, the monitored resource
2525-- descriptor for Google Compute Engine VM instances has a type of
26−-- \`\"gce_instance\"\` and specifies the use of the labels
27−-- \`\"instance_id\"\` and \`\"zone\"\` to identify particular VM
28−-- instances. Different APIs can support different monitored resource
29−-- types. APIs generally provide a \`list\` method that returns the
30−-- monitored resource descriptors used by the API.
26+-- \"gce_instance\" and specifies the use of the labels \"instance_id\" and
27+-- \"zone\" to identify particular VM instances.Different APIs can support
28+-- different monitored resource types. APIs generally provide a list method
29+-- that returns the monitored resource descriptors used by the API.
3130--
3231-- /See:/ 'monitoredResourceDescriptor' smart constructor.
3332data MonitoredResourceDescriptor = MonitoredResourceDescriptor'
@@ -63,18 +62,18 @@ monitoredResourceDescriptor =
6362 }
6463
6564-- | Optional. The resource name of the monitored resource descriptor:
66−-- \`\"projects\/{project_id}\/monitoredResourceDescriptors\/{type}\"\`
67−-- where {type} is the value of the \`type\` field in this object and
68−-- {project_id} is a project ID that provides API-specific context for
69−-- accessing the type. APIs that do not use project information can use the
70−-- resource name format \`\"monitoredResourceDescriptors\/{type}\"\`.
65+-- \"projects\/{project_id}\/monitoredResourceDescriptors\/{type}\" where
66+-- {type} is the value of the type field in this object and {project_id} is
67+-- a project ID that provides API-specific context for accessing the type.
68+-- APIs that do not use project information can use the resource name
69+-- format \"monitoredResourceDescriptors\/{type}\".
7170mrdName :: Lens' MonitoredResourceDescriptor (Maybe Text)
7271mrdName = lens _mrdName (\ s a -> s{_mrdName = a})
7372
7473-- | Optional. A concise name for the monitored resource type that might be
7574-- displayed in user interfaces. It should be a Title Cased Noun Phrase,
76−-- without any article or other determiners. For example, \`\"Google Cloud
77−-- SQL Database\"\`.
75+-- without any article or other determiners. For example, \"Google Cloud
76+-- SQL Database\".
7877mrdDisplayName :: Lens' MonitoredResourceDescriptor (Maybe Text)
7978mrdDisplayName
8079 = lens _mrdDisplayName
@@ -82,8 +81,7 @@ mrdDisplayName
8281
8382-- | Required. A set of labels used to describe instances of this monitored
8483-- resource type. For example, an individual Google Cloud SQL database is
85−-- identified by values for the labels \`\"database_id\"\` and
86−-- \`\"zone\"\`.
84+-- identified by values for the labels \"database_id\" and \"zone\".
8785mrdLabels :: Lens' MonitoredResourceDescriptor [LabelDescriptor]
8886mrdLabels
8987 = lens _mrdLabels (\ s a -> s{_mrdLabels = a}) .
@@ -91,7 +89,7 @@ mrdLabels
9189 . _Coerce
9290
9391-- | Required. The monitored resource type. For example, the type
94−-- \`\"cloudsql_database\"\` represents databases in Google Cloud SQL. The
92+-- \"cloudsql_database\" represents databases in Google Cloud SQL. The
9593-- maximum length of this value is 256 characters.
9694mrdType :: Lens' MonitoredResourceDescriptor (Maybe Text)
9795mrdType = lens _mrdType (\ s a -> s{_mrdType = a})
@@ -123,7 +121,7 @@ instance ToJSON MonitoredResourceDescriptor where
123121 ("type" .=) <$> _mrdType,
124122 ("description" .=) <$> _mrdDescription])
125123
126−-- | Result returned from \`ListLogEntries\`.
124+-- | Result returned from ListLogEntries.
127125--
128126-- /See:/ 'listLogEntriesResponse' smart constructor.
129127data ListLogEntriesResponse = ListLogEntriesResponse'
@@ -146,9 +144,15 @@ listLogEntriesResponse =
146144 , _llerEntries = Nothing
147145 }
148146
149−-- | If there might be more results than appear in this response, then
150−-- \`nextPageToken\` is included. To get the next set of results, call this
151−-- method again using the value of \`nextPageToken\` as \`pageToken\`.
147+-- | If there might be more results than those appearing in this response,
148+-- then nextPageToken is included. To get the next set of results, call
149+-- this method again using the value of nextPageToken as pageToken.If a
150+-- value for next_page_token appears and the entries field is empty, it
151+-- means that the search found no log entries so far but it did not have
152+-- time to search all the possible log entries. Retry the method with this
153+-- value for page_token to continue the search. Alternatively, consider
154+-- speeding up the search by changing your filter to specify a single log
155+-- name or resource type, or to narrow the time range of the search.
152156llerNextPageToken :: Lens' ListLogEntriesResponse (Maybe Text)
153157llerNextPageToken
154158 = lens _llerNextPageToken
@@ -178,7 +182,7 @@ instance ToJSON ListLogEntriesResponse where
178182
179183-- | Required. Values for all of the labels listed in the associated
180184-- monitored resource descriptor. For example, Cloud SQL databases use the
181−-- labels \`\"database_id\"\` and \`\"zone\"\`.
185+-- labels \"database_id\" and \"zone\".
182186--
183187-- /See:/ 'monitoredResourceLabels' smart constructor.
184188newtype MonitoredResourceLabels = MonitoredResourceLabels'
@@ -243,8 +247,8 @@ llmrMetrics
243247 . _Coerce
244248
245249-- | If there might be more results than appear in this response, then
246−-- \`nextPageToken\` is included. To get the next set of results, call this
247−-- method again using the value of \`nextPageToken\` as \`pageToken\`.
250+-- nextPageToken is included. To get the next set of results, call this
251+-- method again using the value of nextPageToken as pageToken.
248252llmrNextPageToken :: Lens' ListLogMetricsResponse (Maybe Text)
249253llmrNextPageToken
250254 = lens _llmrNextPageToken
@@ -301,12 +305,11 @@ writeLogEntriesRequest =
301305 }
302306
303307-- | Required. The log entries to write. Values supplied for the fields
304−-- \`log_name\`, \`resource\`, and \`labels\` in this \`entries.write\`
305−-- request are added to those log entries that do not provide their own
306−-- values for the fields. To improve throughput and to avoid exceeding the
307−-- [quota limit](\/logging\/quota-policy) for calls to \`entries.write\`,
308−-- you should write multiple log entries at once rather than calling this
309−-- method for each individual log entry.
308+-- log_name, resource, and labels in this entries.write request are added
309+-- to those log entries that do not provide their own values for the
310+-- fields.To improve throughput and to avoid exceeding the quota limit for
311+-- calls to entries.write, you should write multiple log entries at once
312+-- rather than calling this method for each individual log entry.
310313wlerEntries :: Lens' WriteLogEntriesRequest [LogEntry]
311314wlerEntries
312315 = lens _wlerEntries (\ s a -> s{_wlerEntries = a}) .
@@ -324,7 +327,7 @@ wlerPartialSuccess
324327 (\ s a -> s{_wlerPartialSuccess = a})
325328
326329-- | Optional. A default monitored resource object that is assigned to all
327−-- log entries in \`entries\` that do not specify a value for \`resource\`.
330+-- log entries in entries that do not specify a value for resource.
328331-- Example: { \"type\": \"gce_instance\", \"labels\": { \"zone\":
329332-- \"us-central1-a\", \"instance_id\": \"00000000000000000000\" }} See
330333-- LogEntry.
@@ -332,17 +335,21 @@ wlerResource :: Lens' WriteLogEntriesRequest (Maybe MonitoredResource)
332335wlerResource
333336 = lens _wlerResource (\ s a -> s{_wlerResource = a})
334337
335−-- | Optional. Default labels that are added to the \`labels\` field of all
336−-- log entries in \`entries\`. If a log entry already has a label with the
337−-- same key as a label in this parameter, then the log entry\'s label is
338−-- not changed. See LogEntry.
338+-- | Optional. Default labels that are added to the labels field of all log
339+-- entries in entries. If a log entry already has a label with the same key
340+-- as a label in this parameter, then the log entry\'s label is not
341+-- changed. See LogEntry.
339342wlerLabels :: Lens' WriteLogEntriesRequest (Maybe WriteLogEntriesRequestLabels)
340343wlerLabels
341344 = lens _wlerLabels (\ s a -> s{_wlerLabels = a})
342345
343346-- | Optional. A default log resource name that is assigned to all log
344−-- entries in \`entries\` that do not specify a value for \`log_name\`.
345−-- Example: \`\"projects\/my-project\/logs\/syslog\"\`. See LogEntry.
347+-- entries in entries that do not specify a value for log_name:
348+-- \"projects\/[PROJECT_ID]\/logs\/[LOG_ID]\"
349+-- \"organizations\/[ORGANIZATION_ID]\/logs\/[LOG_ID]\" [LOG_ID] must be
350+-- URL-encoded. For example, \"projects\/my-project-id\/logs\/syslog\" or
351+-- \"organizations\/1234567890\/logs\/cloudresourcemanager.googleapis.com%2Factivity\".
352+-- For more information about log names, see LogEntry.
346353wlerLogName :: Lens' WriteLogEntriesRequest (Maybe Text)
347354wlerLogName
348355 = lens _wlerLogName (\ s a -> s{_wlerLogName = a})
@@ -372,7 +379,7 @@ instance ToJSON WriteLogEntriesRequest where
372379-- empty messages in your APIs. A typical example is to use it as the
373380-- request or the response type of an API method. For instance: service Foo
374381-- { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The
375−-- JSON representation for \`Empty\` is empty JSON object \`{}\`.
382+-- JSON representation for Empty is empty JSON object {}.
376383--
377384-- /See:/ 'empty' smart constructor.
378385data Empty =
@@ -425,7 +432,7 @@ instance FromJSON LogEntryLabels where
425432instance ToJSON LogEntryLabels where
426433 toJSON = toJSON . _lelAddtional
427434
428−-- | Result returned from \`ListSinks\`.
435+-- | Result returned from ListSinks.
429436--
430437-- /See:/ 'listSinksResponse' smart constructor.
431438data ListSinksResponse = ListSinksResponse'
@@ -456,8 +463,8 @@ lsrSinks
456463 . _Coerce
457464
458465-- | If there might be more results than appear in this response, then
459−-- \`nextPageToken\` is included. To get the next set of results, call the
460−-- same method again using the value of \`nextPageToken\` as \`pageToken\`.
466+-- nextPageToken is included. To get the next set of results, call the same
467+-- method again using the value of nextPageToken as pageToken.
461468lsrNextPageToken :: Lens' ListSinksResponse (Maybe Text)
462469lsrNextPageToken
463470 = lens _lsrNextPageToken
@@ -622,7 +629,7 @@ requestLog =
622629 , _rlAppEngineRelease = Nothing
623630 }
624631
625−-- | Cloud Trace identifier for this request.
632+-- | Stackdriver Trace identifier for this request.
626633rlTraceId :: Lens' RequestLog (Maybe Text)
627634rlTraceId
628635 = lens _rlTraceId (\ s a -> s{_rlTraceId = a})
@@ -664,7 +671,7 @@ rlVersionId :: Lens' RequestLog (Maybe Text)
664671rlVersionId
665672 = lens _rlVersionId (\ s a -> s{_rlVersionId = a})
666673
667−-- | HTTP version of request. Example: \`\"HTTP\/1.1\"\`.
674+-- | HTTP version of request. Example: \"HTTP\/1.1\".
668675rlHTTPVersion :: Lens' RequestLog (Maybe Text)
669676rlHTTPVersion
670677 = lens _rlHTTPVersion
@@ -689,8 +696,8 @@ rlWasLoadingRequest
689696 (\ s a -> s{_rlWasLoadingRequest = a})
690697
691698-- | Whether this is the first RequestLog entry for this request. If an
692−-- active request has several RequestLog entries written to Cloud Logging,
693−-- this field will be set for one of them.
699+-- active request has several RequestLog entries written to Stackdriver
700+-- Logging, then this field will be set for one of them.
694701rlFirst :: Lens' RequestLog (Maybe Bool)
695702rlFirst = lens _rlFirst (\ s a -> s{_rlFirst = a})
696703
@@ -738,15 +745,15 @@ rlIP = lens _rlIP (\ s a -> s{_rlIP = a})
738745rlAppId :: Lens' RequestLog (Maybe Text)
739746rlAppId = lens _rlAppId (\ s a -> s{_rlAppId = a})
740747
741−-- | Request method. Example: \`\"GET\"\`, \`\"HEAD\"\`, \`\"PUT\"\`,
742−-- \`\"POST\"\`, \`\"DELETE\"\`.
748+-- | Request method. Example: \"GET\", \"HEAD\", \"PUT\", \"POST\",
749+-- \"DELETE\".
743750rlMethod :: Lens' RequestLog (Maybe Text)
744751rlMethod = lens _rlMethod (\ s a -> s{_rlMethod = a})
745752
746753-- | Contains the path and query portion of the URL that was requested. For
747754-- example, if the URL was \"http:\/\/example.com\/app?name=val\", the
748755-- resource would be \"\/app?name=val\". The fragment identifier, which is
749−-- identified by the \`#\` character, is not included.
756+-- identified by the # character, is not included.
750757rlResource :: Lens' RequestLog (Maybe Text)
751758rlResource
752759 = lens _rlResource (\ s a -> s{_rlResource = a})
@@ -773,11 +780,11 @@ rlUserAgent :: Lens' RequestLog (Maybe Text)
773780rlUserAgent
774781 = lens _rlUserAgent (\ s a -> s{_rlUserAgent = a})
775782
776−-- | The logged-in user who made the request. Most likely, this is the part
777−-- of the user\'s email before the \`\'\` sign. The field value is the same
778−-- for different requests from the same user, but different users can have
783+-- | The logged-in user who made the request.Most likely, this is the part of
784+-- the user\'s email before the \' sign. The field value is the same for
785+-- different requests from the same user, but different users can have
779786-- similar names. This information is also available to the application via
780−-- the App Engine Users API. This field will be populated starting with App
787+-- the App Engine Users API.This field will be populated starting with App
781788-- Engine 1.9.21.
782789rlNickname :: Lens' RequestLog (Maybe Text)
783790rlNickname
@@ -926,6 +933,72 @@ instance FromJSON LogEntryProtoPayload where
926933instance ToJSON LogEntryProtoPayload where
927934 toJSON = toJSON . _leppAddtional
928935
936+-- | Additional information about the source code location that produced the
937+-- log entry.
938+--
939+-- /See:/ 'logEntrySourceLocation' smart constructor.
940+data LogEntrySourceLocation = LogEntrySourceLocation'
941+ { _leslFunction :: !(Maybe Text)
942+ , _leslLine :: !(Maybe (Textual Int64))
943+ , _leslFile :: !(Maybe Text)
944+ } deriving (Eq,Show,Data,Typeable,Generic)
945+
946+-- | Creates a value of 'LogEntrySourceLocation' with the minimum fields required to make a request.
947+--
948+-- Use one of the following lenses to modify other fields as desired:
949+--
950+-- * 'leslFunction'
951+--
952+-- * 'leslLine'
953+--
954+-- * 'leslFile'
955+logEntrySourceLocation
956+ :: LogEntrySourceLocation
957+logEntrySourceLocation =
958+ LogEntrySourceLocation'
959+ { _leslFunction = Nothing
960+ , _leslLine = Nothing
961+ , _leslFile = Nothing
962+ }
963+
964+-- | Optional. Human-readable name of the function or method being invoked,
965+-- with optional context such as the class or package name. This
966+-- information may be used in contexts such as the logs viewer, where a
967+-- file and line number are less meaningful. The format can vary by
968+-- language. For example: qual.if.ied.Class.method (Java),
969+-- dir\/package.func (Go), function (Python).
970+leslFunction :: Lens' LogEntrySourceLocation (Maybe Text)
971+leslFunction
972+ = lens _leslFunction (\ s a -> s{_leslFunction = a})
973+
974+-- | Optional. Line within the source file. 1-based; 0 indicates no line
975+-- number available.
976+leslLine :: Lens' LogEntrySourceLocation (Maybe Int64)
977+leslLine
978+ = lens _leslLine (\ s a -> s{_leslLine = a}) .
979+ mapping _Coerce
980+
981+-- | Optional. Source file name. Depending on the runtime environment, this
982+-- might be a simple name or a fully-qualified name.
983+leslFile :: Lens' LogEntrySourceLocation (Maybe Text)
984+leslFile = lens _leslFile (\ s a -> s{_leslFile = a})
985+
986+instance FromJSON LogEntrySourceLocation where
987+ parseJSON
988+ = withObject "LogEntrySourceLocation"
989+ (\ o ->
990+ LogEntrySourceLocation' <$>
991+ (o .:? "function") <*> (o .:? "line") <*>
992+ (o .:? "file"))
993+
994+instance ToJSON LogEntrySourceLocation where
995+ toJSON LogEntrySourceLocation'{..}
996+ = object
997+ (catMaybes
998+ [("function" .=) <$> _leslFunction,
999+ ("line" .=) <$> _leslLine,
1000+ ("file" .=) <$> _leslFile])
1001+
9291002-- | Result returned from WriteLogEntries. empty
9301003--
9311004-- /See:/ 'writeLogEntriesResponse' smart constructor.
@@ -947,8 +1020,10 @@ instance FromJSON WriteLogEntriesResponse where
9471020instance ToJSON WriteLogEntriesResponse where
9481021 toJSON = const emptyObject
9491022
950−-- | Describes a sink used to export log entries outside of Stackdriver
951−-- Logging.
1023+-- | Describes a sink used to export log entries to one of the following
1024+-- destinations in any project: a Cloud Storage bucket, a BigQuery dataset,
1025+-- or a Cloud Pub\/Sub topic. A logs filter controls which log entries are
1026+-- exported. The sink must be created within a project or organization.
9521027--
9531028-- /See:/ 'logSink' smart constructor.
9541029data LogSink = LogSink'
@@ -991,69 +1066,72 @@ logSink =
9911066 , _lsFilter = Nothing
9921067 }
9931068
994−-- | Required. The export destination. See [Exporting Logs With
995−-- Sinks](\/logging\/docs\/api\/tasks\/exporting-logs). Examples:
996−-- \"storage.googleapis.com\/my-gcs-bucket\"
997−-- \"bigquery.googleapis.com\/projects\/my-project-id\/datasets\/my-dataset\"
998−-- \"pubsub.googleapis.com\/projects\/my-project\/topics\/my-topic\"
1069+-- | Required. The export destination:
1070+-- \"storage.googleapis.com\/[GCS_BUCKET]\"
1071+-- \"bigquery.googleapis.com\/projects\/[PROJECT_ID]\/datasets\/[DATASET]\"
1072+-- \"pubsub.googleapis.com\/projects\/[PROJECT_ID]\/topics\/[TOPIC_ID]\"
1073+-- The sink\'s writer_identity, set when the sink is created, must have
1074+-- permission to write to the destination or else the log entries are not
1075+-- exported. For more information, see Exporting Logs With Sinks.
9991076lsDestination :: Lens' LogSink (Maybe Text)
10001077lsDestination
10011078 = lens _lsDestination
10021079 (\ s a -> s{_lsDestination = a})
10031080
1004−-- | Optional. Time range for which this sink is active. Logs are exported
1005−-- only if start_time \<= entry.timestamp \< end_time Both start_time and
1006−-- end_time may be omitted to specify (half) infinite ranges. The
1007−-- start_time must be less than the end_time.
1081+-- | Optional. The time at which this sink will begin exporting log entries.
1082+-- Log entries are exported only if their timestamp is not earlier than the
1083+-- start time. The default value of this field is the time the sink is
1084+-- created or updated.
10081085lsStartTime :: Lens' LogSink (Maybe UTCTime)
10091086lsStartTime
10101087 = lens _lsStartTime (\ s a -> s{_lsStartTime = a}) .
10111088 mapping _DateTime
10121089
1013−-- | Optional. The log entry version to use for this sink\'s exported log
1014−-- entries. This version does not have to correspond to the version of the
1015−-- log entry that was written to Stackdriver Logging. If omitted, the v2
1016−-- format is used.
1090+-- | Optional. The log entry format to use for this sink\'s exported log
1091+-- entries. The v2 format is used by default. The v1 format is deprecated
1092+-- and should be used only as part of a migration effort to v2. See
1093+-- Migration to the v2 API.
10171094lsOutputVersionFormat :: Lens' LogSink (Maybe LogSinkOutputVersionFormat)
10181095lsOutputVersionFormat
10191096 = lens _lsOutputVersionFormat
10201097 (\ s a -> s{_lsOutputVersionFormat = a})
10211098
1022−-- | Output only. The IAM identity to which the destination needs to grant
1023−-- write access. This may be a service account or a group. Examples (Do not
1024−-- assume these specific values):
1025−-- \"serviceAccount:cloud-logs\'system.gserviceaccount.com\"
1026−-- \"group:cloud-logs\'google.com\" For GCS destinations, the role
1027−-- \"roles\/owner\" is required on the bucket For Cloud Pubsub
1028−-- destinations, the role \"roles\/pubsub.publisher\" is required on the
1029−-- topic For BigQuery, the role \"roles\/editor\" is required on the
1030−-- dataset
1099+-- | Output only. An IAM identity—a service account or group—under which
1100+-- Stackdriver Logging writes the exported log entries to the sink\'s
1101+-- destination. This field is set by sinks.create and sinks.update, based
1102+-- on the setting of unique_writer_identity in those methods.Until you
1103+-- grant this identity write-access to the destination, log entry exports
1104+-- from this sink will fail. For more information, see Granting access for
1105+-- a resource. Consult the destination service\'s documentation to
1106+-- determine the appropriate IAM roles to assign to the identity.
10311107lsWriterIdentity :: Lens' LogSink (Maybe Text)
10321108lsWriterIdentity
10331109 = lens _lsWriterIdentity
10341110 (\ s a -> s{_lsWriterIdentity = a})
10351111
10361112-- | Required. The client-assigned sink identifier, unique within the
1037−-- project. Example: \`\"my-syslog-errors-to-pubsub\"\`. Sink identifiers
1038−-- are limited to 1000 characters and can include only the following
1039−-- characters: \`A-Z\`, \`a-z\`, \`0-9\`, and the special characters
1040−-- \`_-.\`. The maximum length of the name is 100 characters.
1113+-- project. Example: \"my-syslog-errors-to-pubsub\". Sink identifiers are
1114+-- limited to 100 characters and can include only the following characters:
1115+-- upper and lower-case alphanumeric characters, underscores, hyphens, and
1116+-- periods.
10411117lsName :: Lens' LogSink (Maybe Text)
10421118lsName = lens _lsName (\ s a -> s{_lsName = a})
10431119
1044−-- | Optional. Time at which this sink expires.
1120+-- | Optional. The time at which this sink will stop exporting log entries.
1121+-- Log entries are exported only if their timestamp is earlier than the end
1122+-- time. If this field is not supplied, there is no end time. If both a
1123+-- start time and an end time are provided, then the end time must be later
1124+-- than the start time.
10451125lsEndTime :: Lens' LogSink (Maybe UTCTime)
10461126lsEndTime
10471127 = lens _lsEndTime (\ s a -> s{_lsEndTime = a}) .
10481128 mapping _DateTime
10491129
1050−-- | Optional. An [advanced logs
1051−-- filter](\/logging\/docs\/view\/advanced_filters). Only log entries
1052−-- matching the filter are exported. The filter must be consistent with the
1053−-- log entry format specified by the \`outputVersionFormat\` parameter,
1054−-- regardless of the format of the log entry that was originally written to
1055−-- Stackdriver Logging. Example filter (V2 format):
1056−-- logName=projects\/my-projectid\/logs\/syslog AND severity>=ERROR
1130+-- | Optional. An advanced logs filter. The only exported log entries are
1131+-- those that are in the resource owning the sink and that match the
1132+-- filter. The filter must use the log entry format specified by the
1133+-- output_version_format parameter. For example, in the v2 format:
1134+-- logName=\"projects\/[PROJECT_ID]\/logs\/[LOG_ID]\" AND severity>=ERROR
10571135lsFilter :: Lens' LogSink (Maybe Text)
10581136lsFilter = lens _lsFilter (\ s a -> s{_lsFilter = a})
10591137
@@ -1082,6 +1160,60 @@ instance ToJSON LogSink where
10821160 ("endTime" .=) <$> _lsEndTime,
10831161 ("filter" .=) <$> _lsFilter])
10841162
1163+-- | Result returned from ListLogs.
1164+--
1165+-- /See:/ 'listLogsResponse' smart constructor.
1166+data ListLogsResponse = ListLogsResponse'
1167+ { _llrNextPageToken :: !(Maybe Text)
1168+ , _llrLogNames :: !(Maybe [Text])
1169+ } deriving (Eq,Show,Data,Typeable,Generic)
1170+
1171+-- | Creates a value of 'ListLogsResponse' with the minimum fields required to make a request.
1172+--
1173+-- Use one of the following lenses to modify other fields as desired:
1174+--
1175+-- * 'llrNextPageToken'
1176+--
1177+-- * 'llrLogNames'
1178+listLogsResponse
1179+ :: ListLogsResponse
1180+listLogsResponse =
1181+ ListLogsResponse'
1182+ { _llrNextPageToken = Nothing
1183+ , _llrLogNames = Nothing
1184+ }
1185+
1186+-- | If there might be more results than those appearing in this response,
1187+-- then nextPageToken is included. To get the next set of results, call
1188+-- this method again using the value of nextPageToken as pageToken.
1189+llrNextPageToken :: Lens' ListLogsResponse (Maybe Text)
1190+llrNextPageToken
1191+ = lens _llrNextPageToken
1192+ (\ s a -> s{_llrNextPageToken = a})
1193+
1194+-- | A list of log names. For example, \"projects\/my-project\/syslog\" or
1195+-- \"organizations\/123\/cloudresourcemanager.googleapis.com%2Factivity\".
1196+llrLogNames :: Lens' ListLogsResponse [Text]
1197+llrLogNames
1198+ = lens _llrLogNames (\ s a -> s{_llrLogNames = a}) .
1199+ _Default
1200+ . _Coerce
1201+
1202+instance FromJSON ListLogsResponse where
1203+ parseJSON
1204+ = withObject "ListLogsResponse"
1205+ (\ o ->
1206+ ListLogsResponse' <$>
1207+ (o .:? "nextPageToken") <*>
1208+ (o .:? "logNames" .!= mempty))
1209+
1210+instance ToJSON ListLogsResponse where
1211+ toJSON ListLogsResponse'{..}
1212+ = object
1213+ (catMaybes
1214+ [("nextPageToken" .=) <$> _llrNextPageToken,
1215+ ("logNames" .=) <$> _llrLogNames])
1216+
10851217-- | Result returned from ListMonitoredResourceDescriptors.
10861218--
10871219-- /See:/ 'listMonitoredResourceDescriptorsResponse' smart constructor.
@@ -1105,9 +1237,9 @@ listMonitoredResourceDescriptorsResponse =
11051237 , _lmrdrResourceDescriptors = Nothing
11061238 }
11071239
1108−-- | If there might be more results than appear in this response, then
1109−-- \`nextPageToken\` is included. To get the next set of results, call this
1110−-- method again using the value of \`nextPageToken\` as \`pageToken\`.
1240+-- | If there might be more results than those appearing in this response,
1241+-- then nextPageToken is included. To get the next set of results, call
1242+-- this method again using the value of nextPageToken as pageToken.
11111243lmrdrNextPageToken :: Lens' ListMonitoredResourceDescriptorsResponse (Maybe Text)
11121244lmrdrNextPageToken
11131245 = lens _lmrdrNextPageToken
@@ -1221,7 +1353,7 @@ httprStatus
12211353
12221354-- | The scheme (http, https), the host name, the path and the query portion
12231355-- of the URL that was requested. Example:
1224−-- \`\"http:\/\/example.com\/some\/info?color=red\"\`.
1356+-- \"http:\/\/example.com\/some\/info?color=red\".
12251357httprRequestURL :: Lens' HTTPRequest (Maybe Text)
12261358httprRequestURL
12271359 = lens _httprRequestURL
@@ -1236,8 +1368,7 @@ httprCacheFillBytes
12361368 . mapping _Coerce
12371369
12381370-- | The IP address (IPv4 or IPv6) of the client that issued the HTTP
1239−-- request. Examples: \`\"192.168.1.1\"\`,
1240−-- \`\"FE80::0202:B3FF:FE1E:8329\"\`.
1371+-- request. Examples: \"192.168.1.1\", \"FE80::0202:B3FF:FE1E:8329\".
12411372httprRemoteIP :: Lens' HTTPRequest (Maybe Text)
12421373httprRemoteIP
12431374 = lens _httprRemoteIP
@@ -1266,16 +1397,16 @@ httprRequestSize
12661397 . mapping _Coerce
12671398
12681399-- | Whether or not the response was validated with the origin server before
1269−-- being served from cache. This field is only meaningful if \`cache_hit\`
1270−-- is True.
1400+-- being served from cache. This field is only meaningful if cache_hit is
1401+-- True.
12711402httprCacheValidatedWithOriginServer :: Lens' HTTPRequest (Maybe Bool)
12721403httprCacheValidatedWithOriginServer
12731404 = lens _httprCacheValidatedWithOriginServer
12741405 (\ s a ->
12751406 s{_httprCacheValidatedWithOriginServer = a})
12761407
1277−-- | The user agent sent by the client. Example: \`\"Mozilla\/4.0
1278−-- (compatible; MSIE 6.0; Windows 98; Q312461; .NET CLR 1.0.3705)\"\`.
1408+-- | The user agent sent by the client. Example: \"Mozilla\/4.0 (compatible;
1409+-- MSIE 6.0; Windows 98; Q312461; .NET CLR 1.0.3705)\".
12791410httprUserAgent :: Lens' HTTPRequest (Maybe Text)
12801411httprUserAgent
12811412 = lens _httprUserAgent
@@ -1295,8 +1426,7 @@ httprResponseSize
12951426 (\ s a -> s{_httprResponseSize = a})
12961427 . mapping _Coerce
12971428
1298−-- | The request method. Examples: \`\"GET\"\`, \`\"HEAD\"\`, \`\"PUT\"\`,
1299−-- \`\"POST\"\`.
1429+-- | The request method. Examples: \"GET\", \"HEAD\", \"PUT\", \"POST\".
13001430httprRequestMethod :: Lens' HTTPRequest (Maybe Text)
13011431httprRequestMethod
13021432 = lens _httprRequestMethod
@@ -1309,8 +1439,9 @@ httprCacheHit
13091439 = lens _httprCacheHit
13101440 (\ s a -> s{_httprCacheHit = a})
13111441
1312−-- | The referer URL of the request, as defined in [HTTP\/1.1 Header Field
1313−-- Definitions](http:\/\/www.w3.org\/Protocols\/rfc2616\/rfc2616-sec14.html).
1442+-- | The referer URL of the request, as defined in HTTP\/1.1 Header Field
1443+-- Definitions
1444+-- (http:\/\/www.w3.org\/Protocols\/rfc2616\/rfc2616-sec14.html).
13141445httprReferer :: Lens' HTTPRequest (Maybe Text)
13151446httprReferer
13161447 = lens _httprReferer (\ s a -> s{_httprReferer = a})
@@ -1354,10 +1485,10 @@ instance ToJSON HTTPRequest where
13541485 ("cacheHit" .=) <$> _httprCacheHit,
13551486 ("referer" .=) <$> _httprReferer])
13561487
1357−-- | Optional. Default labels that are added to the \`labels\` field of all
1358−-- log entries in \`entries\`. If a log entry already has a label with the
1359−-- same key as a label in this parameter, then the log entry\'s label is
1360−-- not changed. See LogEntry.
1488+-- | Optional. Default labels that are added to the labels field of all log
1489+-- entries in entries. If a log entry already has a label with the same key
1490+-- as a label in this parameter, then the log entry\'s label is not
1491+-- changed. See LogEntry.
13611492--
13621493-- /See:/ 'writeLogEntriesRequestLabels' smart constructor.
13631494newtype WriteLogEntriesRequestLabels = WriteLogEntriesRequestLabels'
@@ -1395,15 +1526,15 @@ instance ToJSON WriteLogEntriesRequestLabels where
13951526
13961527-- | An object representing a resource that can be used for monitoring,
13971528-- logging, billing, or other purposes. Examples include virtual machine
1398−-- instances, databases, and storage devices such as disks. The \`type\`
1399−-- field identifies a MonitoredResourceDescriptor object that describes the
1400−-- resource\'s schema. Information in the \`labels\` field identifies the
1529+-- instances, databases, and storage devices such as disks. The type field
1530+-- identifies a MonitoredResourceDescriptor object that describes the
1531+-- resource\'s schema. Information in the labels field identifies the
14011532-- actual resource and its attributes according to the schema. For example,
14021533-- a particular Compute Engine VM instance could be represented by the
14031534-- following object, because the MonitoredResourceDescriptor for
1404−-- \`\"gce_instance\"\` has labels \`\"instance_id\"\` and \`\"zone\"\`: {
1405−-- \"type\": \"gce_instance\", \"labels\": { \"instance_id\":
1406−-- \"12345678901234\", \"zone\": \"us-central1-a\" }}
1535+-- \"gce_instance\" has labels \"instance_id\" and \"zone\": { \"type\":
1536+-- \"gce_instance\", \"labels\": { \"instance_id\": \"12345678901234\",
1537+-- \"zone\": \"us-central1-a\" }}
14071538--
14081539-- /See:/ 'monitoredResource' smart constructor.
14091540data MonitoredResource = MonitoredResource'
@@ -1428,13 +1559,13 @@ monitoredResource =
14281559
14291560-- | Required. Values for all of the labels listed in the associated
14301561-- monitored resource descriptor. For example, Cloud SQL databases use the
1431−-- labels \`\"database_id\"\` and \`\"zone\"\`.
1562+-- labels \"database_id\" and \"zone\".
14321563mrLabels :: Lens' MonitoredResource (Maybe MonitoredResourceLabels)
14331564mrLabels = lens _mrLabels (\ s a -> s{_mrLabels = a})
14341565
1435−-- | Required. The monitored resource type. This field must match the
1436−-- \`type\` field of a MonitoredResourceDescriptor object. For example, the
1437−-- type of a Cloud SQL database is \`\"cloudsql_database\"\`.
1566+-- | Required. The monitored resource type. This field must match the type
1567+-- field of a MonitoredResourceDescriptor object. For example, the type of
1568+-- a Cloud SQL database is \"cloudsql_database\".
14381569mrType :: Lens' MonitoredResource (Maybe Text)
14391570mrType = lens _mrType (\ s a -> s{_mrType = a})
14401571
@@ -1581,7 +1712,7 @@ instance ToJSON LabelDescriptor where
15811712 ("valueType" .=) <$> _ldValueType,
15821713 ("description" .=) <$> _ldDescription])
15831714
1584−-- | The parameters to \`ListLogEntries\`.
1715+-- | The parameters to ListLogEntries.
15851716--
15861717-- /See:/ 'listLogEntriesRequest' smart constructor.
15871718data ListLogEntriesRequest = ListLogEntriesRequest'
@@ -1621,21 +1752,20 @@ listLogEntriesRequest =
16211752 }
16221753
16231754-- | Optional. How the results should be sorted. Presently, the only
1624−-- permitted values are \`\"timestamp asc\"\` (default) and \`\"timestamp
1625−-- desc\"\`. The first option returns entries in order of increasing values
1626−-- of \`LogEntry.timestamp\` (oldest first), and the second option returns
1627−-- entries in order of decreasing timestamps (newest first). Entries with
1628−-- equal timestamps are returned in order of \`LogEntry.insertId\`.
1755+-- permitted values are \"timestamp asc\" (default) and \"timestamp desc\".
1756+-- The first option returns entries in order of increasing values of
1757+-- LogEntry.timestamp (oldest first), and the second option returns entries
1758+-- in order of decreasing timestamps (newest first). Entries with equal
1759+-- timestamps are returned in order of LogEntry.insertId.
16291760llerOrderBy :: Lens' ListLogEntriesRequest (Maybe Text)
16301761llerOrderBy
16311762 = lens _llerOrderBy (\ s a -> s{_llerOrderBy = a})
16321763
1633−-- | Deprecated. One or more project identifiers or project numbers from
1634−-- which to retrieve log entries. Examples: \`\"my-project-1A\"\`,
1635−-- \`\"1234567890\"\`. If present, these project identifiers are converted
1636−-- to resource format and added to the list of resources in
1637−-- \`resourceNames\`. Callers should use \`resourceNames\` rather than this
1638−-- parameter.
1764+-- | Deprecated. Use resource_names instead. One or more project identifiers
1765+-- or project numbers from which to retrieve log entries. Example:
1766+-- \"my-project-1A\". If present, these project identifiers are converted
1767+-- to resource name format and added to the list of resources in
1768+-- resource_names.
16391769llerProjectIds :: Lens' ListLogEntriesRequest [Text]
16401770llerProjectIds
16411771 = lens _llerProjectIds
@@ -1644,16 +1774,18 @@ llerProjectIds
16441774 . _Coerce
16451775
16461776-- | Optional. A filter that chooses which log entries to return. See
1647−-- [Advanced Logs Filters](\/logging\/docs\/view\/advanced_filters). Only
1648−-- log entries that match the filter are returned. An empty filter matches
1649−-- all log entries.
1777+-- Advanced Logs Filters. Only log entries that match the filter are
1778+-- returned. An empty filter matches all log entries in the resources
1779+-- listed in resource_names. Referencing a parent resource that is not
1780+-- listed in resource_names will cause the filter to return no results. The
1781+-- maximum length of the filter is 20000 characters.
16501782llerFilter :: Lens' ListLogEntriesRequest (Maybe Text)
16511783llerFilter
16521784 = lens _llerFilter (\ s a -> s{_llerFilter = a})
16531785
16541786-- | Optional. If present, then retrieve the next batch of results from the
1655−-- preceding call to this method. \`pageToken\` must be the value of
1656−-- \`nextPageToken\` from the previous response. The values of other method
1787+-- preceding call to this method. pageToken must be the value of
1788+-- nextPageToken from the previous response. The values of other method
16571789-- parameters should be identical to those in the previous call.
16581790llerPageToken :: Lens' ListLogEntriesRequest (Maybe Text)
16591791llerPageToken
@@ -1661,17 +1793,16 @@ llerPageToken
16611793 (\ s a -> s{_llerPageToken = a})
16621794
16631795-- | Optional. The maximum number of results to return from this request.
1664−-- Non-positive values are ignored. The presence of \`nextPageToken\` in
1665−-- the response indicates that more results might be available.
1796+-- Non-positive values are ignored. The presence of nextPageToken in the
1797+-- response indicates that more results might be available.
16661798llerPageSize :: Lens' ListLogEntriesRequest (Maybe Int32)
16671799llerPageSize
16681800 = lens _llerPageSize (\ s a -> s{_llerPageSize = a})
16691801 . mapping _Coerce
16701802
1671−-- | Required. One or more cloud resources from which to retrieve log
1672−-- entries. Example: \`\"projects\/my-project-1A\"\`,
1673−-- \`\"projects\/1234567890\"\`. Projects listed in \`projectIds\` are
1674−-- added to this list.
1803+-- | Required. Names of one or more resources from which to retrieve log
1804+-- entries: \"projects\/[PROJECT_ID]\" \"organizations\/[ORGANIZATION_ID]\"
1805+-- Projects listed in the project_ids field are added to this list.
16751806llerResourceNames :: Lens' ListLogEntriesRequest [Text]
16761807llerResourceNames
16771808 = lens _llerResourceNames
@@ -1738,10 +1869,10 @@ logEntryOperation =
17381869leoFirst :: Lens' LogEntryOperation (Maybe Bool)
17391870leoFirst = lens _leoFirst (\ s a -> s{_leoFirst = a})
17401871
1741−-- | Optional. An arbitrary producer identifier. The combination of \`id\`
1742−-- and \`producer\` must be globally unique. Examples for \`producer\`:
1743−-- \`\"MyDivision.MyBigCompany.com\"\`,
1744−-- \`\"github.com\/MyProject\/MyApplication\"\`.
1872+-- | Optional. An arbitrary producer identifier. The combination of id and
1873+-- producer must be globally unique. Examples for producer:
1874+-- \"MyDivision.MyBigCompany.com\",
1875+-- \"github.com\/MyProject\/MyApplication\".
17451876leoProducer :: Lens' LogEntryOperation (Maybe Text)
17461877leoProducer
17471878 = lens _leoProducer (\ s a -> s{_leoProducer = a})
@@ -1774,7 +1905,7 @@ instance ToJSON LogEntryOperation where
17741905 ("last" .=) <$> _leoLast, ("id" .=) <$> _leoId])
17751906
17761907-- | Describes a logs-based metric. The value of the metric is the number of
1777−-- log entries that match a logs filter.
1908+-- log entries that match a logs filter in a given time interval.
17781909--
17791910-- /See:/ 'logMetric' smart constructor.
17801911data LogMetric = LogMetric'
@@ -1805,14 +1936,17 @@ logMetric =
18051936 , _lmDescription = Nothing
18061937 }
18071938
1808−-- | Required. The client-assigned metric identifier. Example:
1809−-- \`\"severe_errors\"\`. Metric identifiers are limited to 100 characters
1810−-- and can include only the following characters: \`A-Z\`, \`a-z\`,
1811−-- \`0-9\`, and the special characters \`_-.,+!*\',()%\/\`. The
1812−-- forward-slash character (\`\/\`) denotes a hierarchy of name pieces, and
1813−-- it cannot be the first character of the name. The \'%\' character is
1814−-- used to URL encode unsafe and reserved characters and must be followed
1815−-- by two hexadecimal digits according to RFC 1738.
1939+-- | Required. The client-assigned metric identifier. Examples:
1940+-- \"error_count\", \"nginx\/requests\".Metric identifiers are limited to
1941+-- 100 characters and can include only the following characters: A-Z, a-z,
1942+-- 0-9, and the special characters _-.,+!*\',()%\/. The forward-slash
1943+-- character (\/) denotes a hierarchy of name pieces, and it cannot be the
1944+-- first character of the name.The metric identifier in this field must not
1945+-- be URL-encoded (https:\/\/en.wikipedia.org\/wiki\/Percent-encoding).
1946+-- However, when the metric identifier appears as the [METRIC_ID] part of a
1947+-- metric_name API parameter, then the metric identifier must be
1948+-- URL-encoded. Example:
1949+-- \"projects\/my-project\/metrics\/nginx%2Frequests\".
18161950lmName :: Lens' LogMetric (Maybe Text)
18171951lmName = lens _lmName (\ s a -> s{_lmName = a})
18181952
@@ -1823,9 +1957,9 @@ lmVersion :: Lens' LogMetric (Maybe LogMetricVersion)
18231957lmVersion
18241958 = lens _lmVersion (\ s a -> s{_lmVersion = a})
18251959
1826−-- | Required. An [advanced logs
1827−-- filter](\/logging\/docs\/view\/advanced_filters). Example:
1828−-- \`\"resource.type=gae_app AND severity>=ERROR\"\`.
1960+-- | Required. An advanced logs filter which is used to match log entries.
1961+-- Example: \"resource.type=gae_app AND severity>=ERROR\" The maximum
1962+-- length of the filter is 20000 characters.
18291963lmFilter :: Lens' LogMetric (Maybe Text)
18301964lmFilter = lens _lmFilter (\ s a -> s{_lmFilter = a})
18311965
@@ -1857,17 +1991,19 @@ instance ToJSON LogMetric where
18571991--
18581992-- /See:/ 'logEntry' smart constructor.
18591993data LogEntry = LogEntry'
1860− { _leOperation :: !(Maybe LogEntryOperation)
1861− , _leSeverity :: !(Maybe LogEntrySeverity)
1862− , _leTextPayload :: !(Maybe Text)
1863− , _leJSONPayload :: !(Maybe LogEntryJSONPayload)
1864− , _leHTTPRequest :: !(Maybe HTTPRequest)
1865− , _leResource :: !(Maybe MonitoredResource)
1866− , _leInsertId :: !(Maybe Text)
1867− , _leLabels :: !(Maybe LogEntryLabels)
1868− , _leProtoPayload :: !(Maybe LogEntryProtoPayload)
1869− , _leLogName :: !(Maybe Text)
1870− , _leTimestamp :: !(Maybe DateTime')
1994+ { _leOperation :: !(Maybe LogEntryOperation)
1995+ , _leSeverity :: !(Maybe LogEntrySeverity)
1996+ , _leTextPayload :: !(Maybe Text)
1997+ , _leJSONPayload :: !(Maybe LogEntryJSONPayload)
1998+ , _leHTTPRequest :: !(Maybe HTTPRequest)
1999+ , _leResource :: !(Maybe MonitoredResource)
2000+ , _leInsertId :: !(Maybe Text)
2001+ , _leLabels :: !(Maybe LogEntryLabels)
2002+ , _leProtoPayload :: !(Maybe LogEntryProtoPayload)
2003+ , _leSourceLocation :: !(Maybe LogEntrySourceLocation)
2004+ , _leLogName :: !(Maybe Text)
2005+ , _leTimestamp :: !(Maybe DateTime')
2006+ , _leTrace :: !(Maybe Text)
18712007 } deriving (Eq,Show,Data,Typeable,Generic)
18722008
18732009-- | Creates a value of 'LogEntry' with the minimum fields required to make a request.
@@ -1892,9 +2028,13 @@ data LogEntry = LogEntry'
18922028--
18932029-- * 'leProtoPayload'
18942030--
2031+-- * 'leSourceLocation'
2032+--
18952033-- * 'leLogName'
18962034--
18972035-- * 'leTimestamp'
2036+--
2037+-- * 'leTrace'
18982038logEntry
18992039 :: LogEntry
19002040logEntry =
@@ -1908,8 +2048,10 @@ logEntry =
19082048 , _leInsertId = Nothing
19092049 , _leLabels = Nothing
19102050 , _leProtoPayload = Nothing
2051+ , _leSourceLocation = Nothing
19112052 , _leLogName = Nothing
19122053 , _leTimestamp = Nothing
2054+ , _leTrace = Nothing
19132055 }
19142056
19152057-- | Optional. Information about an operation associated with the log entry,
@@ -1919,7 +2061,7 @@ leOperation
19192061 = lens _leOperation (\ s a -> s{_leOperation = a})
19202062
19212063-- | Optional. The severity of the log entry. The default value is
1922−-- \`LogSeverity.DEFAULT\`.
2064+-- LogSeverity.DEFAULT.
19232065leSeverity :: Lens' LogEntry (Maybe LogEntrySeverity)
19242066leSeverity
19252067 = lens _leSeverity (\ s a -> s{_leSeverity = a})
@@ -1972,15 +2114,26 @@ leProtoPayload
19722114 = lens _leProtoPayload
19732115 (\ s a -> s{_leProtoPayload = a})
19742116
1975−-- | Required. The resource name of the log to which this log entry belongs.
1976−-- The format of the name is \`\"projects\/\/logs\/\"\`. Examples:
1977−-- \`\"projects\/my-projectid\/logs\/syslog\"\`,
1978−-- \`\"projects\/my-projectid\/logs\/library.googleapis.com%2Fbook_log\"\`.
1979−-- The log ID part of resource name must be less than 512 characters long
1980−-- and can only include the following characters: upper and lower case
1981−-- alphanumeric characters: [A-Za-z0-9]; and punctuation characters:
1982−-- forward-slash, underscore, hyphen, and period. Forward-slash (\`\/\`)
1983−-- characters in the log ID must be URL-encoded.
2117+-- | Optional. Source code location information associated with the log
2118+-- entry, if any.
2119+leSourceLocation :: Lens' LogEntry (Maybe LogEntrySourceLocation)
2120+leSourceLocation
2121+ = lens _leSourceLocation
2122+ (\ s a -> s{_leSourceLocation = a})
2123+
2124+-- | Required. The resource name of the log to which this log entry belongs:
2125+-- \"projects\/[PROJECT_ID]\/logs\/[LOG_ID]\"
2126+-- \"organizations\/[ORGANIZATION_ID]\/logs\/[LOG_ID]\" [LOG_ID] must be
2127+-- URL-encoded within log_name. Example:
2128+-- \"organizations\/1234567890\/logs\/cloudresourcemanager.googleapis.com%2Factivity\".
2129+-- [LOG_ID] must be less than 512 characters long and can only include the
2130+-- following characters: upper and lower case alphanumeric characters,
2131+-- forward-slash, underscore, hyphen, and period.For backward
2132+-- compatibility, if log_name begins with a forward-slash, such as
2133+-- \/projects\/..., then the log entry is ingested as usual but the
2134+-- forward-slash is removed. Listing the log entry will not show the
2135+-- leading slash and filtering for a log name with a leading slash will
2136+-- never return any results.
19842137leLogName :: Lens' LogEntry (Maybe Text)
19852138leLogName
19862139 = lens _leLogName (\ s a -> s{_leLogName = a})
@@ -1993,6 +2146,13 @@ leTimestamp
19932146 = lens _leTimestamp (\ s a -> s{_leTimestamp = a}) .
19942147 mapping _DateTime
19952148
2149+-- | Optional. Resource name of the trace associated with the log entry, if
2150+-- any. If it contains a relative resource name, the name is assumed to be
2151+-- relative to \/\/tracing.googleapis.com. Example:
2152+-- projects\/my-projectid\/traces\/06796866738c859f2f19b7cfb3214824
2153+leTrace :: Lens' LogEntry (Maybe Text)
2154+leTrace = lens _leTrace (\ s a -> s{_leTrace = a})
2155+
19962156instance FromJSON LogEntry where
19972157 parseJSON
19982158 = withObject "LogEntry"
@@ -2006,8 +2166,10 @@ instance FromJSON LogEntry where
20062166 <*> (o .:? "insertId")
20072167 <*> (o .:? "labels")
20082168 <*> (o .:? "protoPayload")
2169+ <*> (o .:? "sourceLocation")
20092170 <*> (o .:? "logName")
2010− <*> (o .:? "timestamp"))
2171+ <*> (o .:? "timestamp")
2172+ <*> (o .:? "trace"))
20112173
20122174instance ToJSON LogEntry where
20132175 toJSON LogEntry'{..}
@@ -2022,8 +2184,10 @@ instance ToJSON LogEntry where
20222184 ("insertId" .=) <$> _leInsertId,
20232185 ("labels" .=) <$> _leLabels,
20242186 ("protoPayload" .=) <$> _leProtoPayload,
2187+ ("sourceLocation" .=) <$> _leSourceLocation,
20252188 ("logName" .=) <$> _leLogName,
2026− ("timestamp" .=) <$> _leTimestamp])
2189+ ("timestamp" .=) <$> _leTimestamp,
2190+ ("trace" .=) <$> _leTrace])
20272191
20282192-- | Specifies a location in a source code file.
20292193--
@@ -2062,8 +2226,8 @@ slLine
20622226-- optional context such as the class or package name. This information is
20632227-- used in contexts such as the logs viewer, where a file and line number
20642228-- are less meaningful. The format can vary by language. For example:
2065−-- \`qual.if.ied.Class.method\` (Java), \`dir\/package.func\` (Go),
2066−-- \`function\` (Python).
2229+-- qual.if.ied.Class.method (Java), dir\/package.func (Go), function
2230+-- (Python).
20672231slFunctionName :: Lens' SourceLocation (Maybe Text)
20682232slFunctionName
20692233 = lens _slFunctionName