bug: OpenAPM not masking the path in some cases
Open
@chtushar is already working on this.
Since May 14, 2024.
waiting-for-reproduction
- Dominant language
- TypeScript
- Stars
- 66
- Forks
- 5
- PR merge metrics
- No merged PRs in 30d
Description
Describe the bug
After instrumenting the express app. In some cases OpenAPM is not masking the paths using openapm.instrument('express') signature. The paths in the screenshot should be prefixed with /org/:orgId/
To Reproduce
Steps to reproduce the behavior:
- Generate a demo express application using
npx express-generator - Use
openapm.instrument('express')as per the documentation - Create a router and use a parameter in the base path
- Start the application and make calls to the paths initialized in the router.
localhost:9097/metricswon't have a parameterised routes.
Expected behavior
The paths should be parameterized like it is in the screenshot. When the middleware is used directly like this
app.use(openapm.REDMiddleware); the behaviour seems to be as expected.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.