Class: Google::Apis::LoggingV2::RequestLog

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/logging_v2/classes.rb,
lib/google/apis/logging_v2/representations.rb,
lib/google/apis/logging_v2/representations.rb

Overview

Complete log information about a single HTTP request to an App Engine application.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ RequestLog

Returns a new instance of RequestLog.



2283
2284
2285
# File 'lib/google/apis/logging_v2/classes.rb', line 2283

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#app_engine_releaseString

App Engine release version. Corresponds to the JSON property appEngineRelease

Returns:

  • (String)


2102
2103
2104
# File 'lib/google/apis/logging_v2/classes.rb', line 2102

def app_engine_release
  @app_engine_release
end

#app_idString

Application that handled this request. Corresponds to the JSON property appId

Returns:

  • (String)


2107
2108
2109
# File 'lib/google/apis/logging_v2/classes.rb', line 2107

def app_id
  @app_id
end

#costFloat

An indication of the relative cost of serving this request. Corresponds to the JSON property cost

Returns:

  • (Float)


2112
2113
2114
# File 'lib/google/apis/logging_v2/classes.rb', line 2112

def cost
  @cost
end

#end_timeString

Time when the request finished. Corresponds to the JSON property endTime

Returns:

  • (String)


2117
2118
2119
# File 'lib/google/apis/logging_v2/classes.rb', line 2117

def end_time
  @end_time
end

#finishedBoolean Also known as: finished?

Whether this request is finished or active. Corresponds to the JSON property finished

Returns:

  • (Boolean)


2122
2123
2124
# File 'lib/google/apis/logging_v2/classes.rb', line 2122

def finished
  @finished
end

#firstBoolean Also known as: first?

Whether this is the first RequestLog entry for this request. If an active request has several RequestLog entries written to Stackdriver Logging, then this field will be set for one of them. Corresponds to the JSON property first

Returns:

  • (Boolean)


2130
2131
2132
# File 'lib/google/apis/logging_v2/classes.rb', line 2130

def first
  @first
end

#hostString

Internet host and port number of the resource being requested. Corresponds to the JSON property host

Returns:

  • (String)


2136
2137
2138
# File 'lib/google/apis/logging_v2/classes.rb', line 2136

def host
  @host
end

#http_versionString

HTTP version of request. Example: "HTTP/1.1". Corresponds to the JSON property httpVersion

Returns:

  • (String)


2141
2142
2143
# File 'lib/google/apis/logging_v2/classes.rb', line 2141

def http_version
  @http_version
end

#instance_idString

An identifier for the instance that handled the request. Corresponds to the JSON property instanceId

Returns:

  • (String)


2146
2147
2148
# File 'lib/google/apis/logging_v2/classes.rb', line 2146

def instance_id
  @instance_id
end

#instance_indexFixnum

If the instance processing this request belongs to a manually scaled module, then this is the 0-based index of the instance. Otherwise, this value is -1. Corresponds to the JSON property instanceIndex

Returns:

  • (Fixnum)


2152
2153
2154
# File 'lib/google/apis/logging_v2/classes.rb', line 2152

def instance_index
  @instance_index
end

#ipString

Origin IP address. Corresponds to the JSON property ip

Returns:

  • (String)


2157
2158
2159
# File 'lib/google/apis/logging_v2/classes.rb', line 2157

def ip
  @ip
end

#latencyString

Latency of the request. Corresponds to the JSON property latency

Returns:

  • (String)


2162
2163
2164
# File 'lib/google/apis/logging_v2/classes.rb', line 2162

def latency
  @latency
end

#lineArray<Google::Apis::LoggingV2::LogLine>

A list of log lines emitted by the application while serving this request. Corresponds to the JSON property line



2167
2168
2169
# File 'lib/google/apis/logging_v2/classes.rb', line 2167

def line
  @line
end

#mega_cyclesFixnum

Number of CPU megacycles used to process request. Corresponds to the JSON property megaCycles

Returns:

  • (Fixnum)


2172
2173
2174
# File 'lib/google/apis/logging_v2/classes.rb', line 2172

def mega_cycles
  @mega_cycles
end

#method_propString

Request method. Example: "GET", "HEAD", "PUT", "POST", "DELETE". Corresponds to the JSON property method

Returns:

  • (String)


2177
2178
2179
# File 'lib/google/apis/logging_v2/classes.rb', line 2177

def method_prop
  @method_prop
end

#module_idString

Module of the application that handled this request. Corresponds to the JSON property moduleId

Returns:

  • (String)


2182
2183
2184
# File 'lib/google/apis/logging_v2/classes.rb', line 2182

def module_id
  @module_id
end

#nicknameString

The logged-in user who made the request.Most likely, this is the part of the user's email before the @ sign. The field value is the same for different requests from the same user, but different users can have similar names. This information is also available to the application via the App Engine Users API. This field will be populated starting with App Engine 1.9.21. Corresponds to the JSON property nickname

Returns:

  • (String)


2191
2192
2193
# File 'lib/google/apis/logging_v2/classes.rb', line 2191

def nickname
  @nickname
end

#pending_timeString

Time this request spent in the pending request queue. Corresponds to the JSON property pendingTime

Returns:

  • (String)


2196
2197
2198
# File 'lib/google/apis/logging_v2/classes.rb', line 2196

def pending_time
  @pending_time
end

#referrerString

Referrer URL of request. Corresponds to the JSON property referrer

Returns:

  • (String)


2201
2202
2203
# File 'lib/google/apis/logging_v2/classes.rb', line 2201

def referrer
  @referrer
end

#request_idString

Globally unique identifier for a request, which is based on the request start time. Request IDs for requests which started later will compare greater as strings than those for requests which started earlier. Corresponds to the JSON property requestId

Returns:

  • (String)


2208
2209
2210
# File 'lib/google/apis/logging_v2/classes.rb', line 2208

def request_id
  @request_id
end

#resourceString

Contains the path and query portion of the URL that was requested. For example, if the URL was "http://example.com/app?name=val", the resource would be "/app? name=val". The fragment identifier, which is identified by the # character, is not included. Corresponds to the JSON property resource

Returns:

  • (String)


2216
2217
2218
# File 'lib/google/apis/logging_v2/classes.rb', line 2216

def resource
  @resource
end

#response_sizeFixnum

Size in bytes sent back to client by request. Corresponds to the JSON property responseSize

Returns:

  • (Fixnum)


2221
2222
2223
# File 'lib/google/apis/logging_v2/classes.rb', line 2221

def response_size
  @response_size
end

#source_referenceArray<Google::Apis::LoggingV2::SourceReference>

Source code for the application that handled this request. There can be more than one source reference per deployed application if source code is distributed among multiple repositories. Corresponds to the JSON property sourceReference



2228
2229
2230
# File 'lib/google/apis/logging_v2/classes.rb', line 2228

def source_reference
  @source_reference
end

#start_timeString

Time when the request started. Corresponds to the JSON property startTime

Returns:

  • (String)


2233
2234
2235
# File 'lib/google/apis/logging_v2/classes.rb', line 2233

def start_time
  @start_time
end

#statusFixnum

HTTP response status code. Example: 200, 404. Corresponds to the JSON property status

Returns:

  • (Fixnum)


2238
2239
2240
# File 'lib/google/apis/logging_v2/classes.rb', line 2238

def status
  @status
end

#task_nameString

Task name of the request, in the case of an offline request. Corresponds to the JSON property taskName

Returns:

  • (String)


2243
2244
2245
# File 'lib/google/apis/logging_v2/classes.rb', line 2243

def task_name
  @task_name
end

#task_queue_nameString

Queue name of the request, in the case of an offline request. Corresponds to the JSON property taskQueueName

Returns:

  • (String)


2248
2249
2250
# File 'lib/google/apis/logging_v2/classes.rb', line 2248

def task_queue_name
  @task_queue_name
end

#trace_idString

Stackdriver Trace identifier for this request. Corresponds to the JSON property traceId

Returns:

  • (String)


2253
2254
2255
# File 'lib/google/apis/logging_v2/classes.rb', line 2253

def trace_id
  @trace_id
end

#trace_sampledBoolean Also known as: trace_sampled?

If true, the value in the 'trace_id' field was sampled for storage in a trace backend. Corresponds to the JSON property traceSampled

Returns:

  • (Boolean)


2259
2260
2261
# File 'lib/google/apis/logging_v2/classes.rb', line 2259

def trace_sampled
  @trace_sampled
end

#url_map_entryString

File or class that handled the request. Corresponds to the JSON property urlMapEntry

Returns:

  • (String)


2265
2266
2267
# File 'lib/google/apis/logging_v2/classes.rb', line 2265

def url_map_entry
  @url_map_entry
end

#user_agentString

User agent that made the request. Corresponds to the JSON property userAgent

Returns:

  • (String)


2270
2271
2272
# File 'lib/google/apis/logging_v2/classes.rb', line 2270

def user_agent
  @user_agent
end

#version_idString

Version of the application that handled this request. Corresponds to the JSON property versionId

Returns:

  • (String)


2275
2276
2277
# File 'lib/google/apis/logging_v2/classes.rb', line 2275

def version_id
  @version_id
end

#was_loading_requestBoolean Also known as: was_loading_request?

Whether this was a loading request for the instance. Corresponds to the JSON property wasLoadingRequest

Returns:

  • (Boolean)


2280
2281
2282
# File 'lib/google/apis/logging_v2/classes.rb', line 2280

def was_loading_request
  @was_loading_request
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
# File 'lib/google/apis/logging_v2/classes.rb', line 2288

def update!(**args)
  @app_engine_release = args[:app_engine_release] if args.key?(:app_engine_release)
  @app_id = args[:app_id] if args.key?(:app_id)
  @cost = args[:cost] if args.key?(:cost)
  @end_time = args[:end_time] if args.key?(:end_time)
  @finished = args[:finished] if args.key?(:finished)
  @first = args[:first] if args.key?(:first)
  @host = args[:host] if args.key?(:host)
  @http_version = args[:http_version] if args.key?(:http_version)
  @instance_id = args[:instance_id] if args.key?(:instance_id)
  @instance_index = args[:instance_index] if args.key?(:instance_index)
  @ip = args[:ip] if args.key?(:ip)
  @latency = args[:latency] if args.key?(:latency)
  @line = args[:line] if args.key?(:line)
  @mega_cycles = args[:mega_cycles] if args.key?(:mega_cycles)
  @method_prop = args[:method_prop] if args.key?(:method_prop)
  @module_id = args[:module_id] if args.key?(:module_id)
  @nickname = args[:nickname] if args.key?(:nickname)
  @pending_time = args[:pending_time] if args.key?(:pending_time)
  @referrer = args[:referrer] if args.key?(:referrer)
  @request_id = args[:request_id] if args.key?(:request_id)
  @resource = args[:resource] if args.key?(:resource)
  @response_size = args[:response_size] if args.key?(:response_size)
  @source_reference = args[:source_reference] if args.key?(:source_reference)
  @start_time = args[:start_time] if args.key?(:start_time)
  @status = args[:status] if args.key?(:status)
  @task_name = args[:task_name] if args.key?(:task_name)
  @task_queue_name = args[:task_queue_name] if args.key?(:task_queue_name)
  @trace_id = args[:trace_id] if args.key?(:trace_id)
  @trace_sampled = args[:trace_sampled] if args.key?(:trace_sampled)
  @url_map_entry = args[:url_map_entry] if args.key?(:url_map_entry)
  @user_agent = args[:user_agent] if args.key?(:user_agent)
  @version_id = args[:version_id] if args.key?(:version_id)
  @was_loading_request = args[:was_loading_request] if args.key?(:was_loading_request)
end