struct

Azu::ErrorContext

Inherits Struct < Value < Object

Enhanced error context for better debugging

Constructors

new(timestamp : Time = Time.utc, request_id : Nil | String = nil, user_id : Nil | String = nil, session_id : Nil | String = nil, ip_address : Nil | String = nil, user_agent : Nil | String = nil, referer : Nil | String = nil, endpoint : Nil | String = nil, method : Nil | String = nil, params : Nil | Hash(String, String) = nil, headers : HTTP::Headers | Nil = nil, _load_environment : Bool = false)
Source

Class methods

from_http_context(context : HTTP::Server::Context, request_id : String | Nil = nil, load_environment : Bool = true)
Source
lightweight_from_http_context(context : HTTP::Server::Context, request_id : String | Nil = nil)

Create a lightweight context without environment data

Source

Instance methods

endpoint
Source
environment

Lazy getter for environment data

Source
headers
Source
ip_address
Source
method
Source
params
Source
referer
Source
request_id
Source
session_id
Source
timestamp
Source
to_h
Source
to_json(json : JSON::Builder)
Source
user_agent
Source
user_id
Source