Describe the bug
When uploading the application by running docker-compose up, a request that returns status 2xx such as http://localhost:xxxx/hc is not being captured by the APM agent but a request that returns a 404 for example http://localhost:xxxx/foo/bar is being logged by APM.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Show the http requests with status 2xx.
Same experience here, but I am using .net core 3.1.
Yeah, I've tried the .net core 3.1 too 馃槕
Same here.
I also noticed that POST requests are not being captured.
@luisaantonio I looked at your sample app and I think the problem is that the APM Agent is not registered as the 1. middleware here.
The app.UseAllElasticApm(Configuration); should be the 1. line in the Configure method, otherwise the APM middleware does not have a chance to capture the request before it hits MVC, or any other Middleware.
@gregkalapos Thanks!
Your tip solved the problem here.
Great, thanks for the quick feedback.
I looked into our docs, and as it seems we don't document this properly. I'll add this to the docs!
Thanks @gregkalapos!!
Problem solved here too.
Most helpful comment
@luisaantonio I looked at your sample app and I think the problem is that the APM Agent is not registered as the 1. middleware here.
The
app.UseAllElasticApm(Configuration);should be the 1. line in theConfiguremethod, otherwise the APM middleware does not have a chance to capture the request before it hits MVC, or any other Middleware.