Interface: RequestWatcherConfig
Defined in: nestlens.config.ts:145
Properties
captureBody?
optionalcaptureBody:boolean
Defined in: nestlens.config.ts:150
captureControllerInfo?
optionalcaptureControllerInfo:boolean
Defined in: nestlens.config.ts:171
captureHeaders?
optionalcaptureHeaders:boolean
Defined in: nestlens.config.ts:149
captureMemory?
optionalcaptureMemory:boolean
Defined in: nestlens.config.ts:170
Record how much the heap grew across the handler. Default: false.
Off by default because the figure is not what it appears to be and is not
free. It is process.memoryUsage().heapUsed read either side of the
handler, and the heap is shared with every other request in flight, with a
garbage collection free to run between the two readings. Measured on an
endpoint that returns {ok: true} and allocates nothing worth naming, it
ranged from -570KB to +671KB and was negative in one request out of thirty.
Reading it twice per request cost about 2.5% of the process's CPU under load. Turn it on when the application is handling one request at a time — a local reproduction, a worker — where the number means something.
captureResponse?
optionalcaptureResponse:boolean
Defined in: nestlens.config.ts:151
captureResponseHeaders?
optionalcaptureResponseHeaders:boolean
Defined in: nestlens.config.ts:155
captureSession?
optionalcaptureSession:boolean
Defined in: nestlens.config.ts:154
captureUser?
optionalcaptureUser:boolean
Defined in: nestlens.config.ts:153
enabled?
optionalenabled:boolean
Defined in: nestlens.config.ts:146
ignorePaths?
optionalignorePaths:string[]
Defined in: nestlens.config.ts:147
maxBodySize?
optionalmaxBodySize:number
Defined in: nestlens.config.ts:148
tags()?
optionaltags: (req) =>string[] |Promise<string[]>
Defined in: nestlens.config.ts:172
Parameters
req
Request
Returns
string[] | Promise<string[]>