This folder contains a Dockerfile and a simple ASP.NET Core web api application that can be used to test the agent's ability to ignore error codes by status.
Steps for testing:
- Edit the Dockerfile to set your New Relic license key and application name.
docker build . -t errortest
docker run -p 8080:80 errortest
- In a browser or with curl, make several requests to http://localhost:8080/weatherforecast and then one or two requests to http://localhost:8080/throwerror
- Observe in New Relic APM that there should be some 422 errors in your errors inbox for the test app
- Now run the container again with the ignore error codes env var set:
docker run -p 8080:80 -e 'NEW_RELIC_ERROR_COLLECTOR_IGNORE_ERROR_CODES=422' errortest
- Repeat step 4
- There should be no additional 422 errors in your errors inbox