Http auto instrumentation fails when using @FileInterceptor
See original GitHub issueSample fork : https://github.com/benitezho/nestjs-otel
Using: nodeJS 16.1.0
Description
I uploaded a sample nestjs main module ready to run.
In the example i created a AppController that outputs on the console the active span from the current context, the line that reproduces the issue its:
// @UseInterceptors(FileInterceptor('field'))
If you uncomment this line, the active span from the current context its undefined when a new request its incoming.
My guess is that Nestjs’s @FileInterceptor that uses multer under the hood, somehow it’s replacing the async hook request listeners. For that reason, i don’t know if this issue should be here.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:10 (8 by maintainers)
Top Results From Across the Web
multer options fileFilter FileInterceptor throws http status code ...
Bug Report Same as #465 , the fileFilter returns an internal error while I'd expect a bad request when file type mismatch.
Read more >multer - Nestjs throw error and http status 400 when fileFilter in ...
I'd rather use the logging for this instead. (The application has middleware in place to pick up NestJS errors and log them automagically.)...
Read more >File upload | NestJS - A progressive Node.js framework
To upload a single file, simply tie the FileInterceptor() interceptor to the route ... The HTTP status code to be thrown in case...
Read more >Dual-Force: Understanding WebView Malware via Cross ...
Statements that invoke string comparison methods whose arguments contain “http://”, “file:///” or “javascript:”. These locations are identified for further use ...
Read more >no metadata for categoryrepository was found. nestjs - You.com
js location, but i keep getting the following error when running my server.spec.ts file through mocha: { EntityMetadataNotFound: No metadata for ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This should be fixed here: https://github.com/pragmaticivan/nestjs-otel/releases/tag/v2.0.0
@pratimsc @benitezho a lot of the problems I found when I created that lib are going to be fixed in this PR: https://github.com/pragmaticivan/nestjs-otel/pull/55
It will require a Major version though. FYI.