elastic / elastic/apm-agent-nodejs
how to capture transactions with long duration? timeout ?
- Dominant language
- JavaScript
- Stars
- 594
- Forks
- 244
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 16
Description
**Describe the bug**
Not sure if this is a bug or a wrong configuration that it is not enabling capture long duration transaction or without timeout
**To Reproduce**
Steps to reproduce the behavior:
1. Use this config '...'
2. Then call '....'
3. Then do '....'
4. See error
setup APM, and try to make a long duration request, more than 3 minutes
**Expected behavior**
it should capture and show this transaction in APM
**Environment (please complete the following information)**
- OS: [e.g. Linux]
- Node.js version:
- APM Server version:
- Agent version:
System:
OS: macOS 15.1.1
CPU: (8) arm64 Apple M1 Pro
Memory: 127.75 MB / 16.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 22.12.0 - ~/.nvm/versions/node/v22.12.0/bin/node
npm: 10.9.0 - ~/.nvm/versions/node/v22.12.0/bin/npm
pnpm: 9.15.0 - ~/Library/pnpm/pnpm
bun: 1.1.38 - /opt/homebrew/bin/bun
Browsers:
Chrome: 131.0.6778.109
Safari: 18.1.1
apm server 7
elastic-apm-node: 4.7.3
**How are you starting the agent? (please tick one of the boxes)**
- [ ] Calling `agent.start()` directly (e.g. `require('elastic-apm-node').start(...)`)
- [ ] Requiring `elastic-apm-node/start` from within the source code
- [x] Starting node with `-r elastic-apm-node/start`
**Additional context**
Agent config options:
Click to expand
```
replace this line with your agent config options
```
`package.json` dependencies:
Click to expand
```
replace this line with your dependencies section from package.json
```
What is the right environment variable for this?
ELASTIC_APM_API_REQUEST_TIME
ELASTIC_APM_SERVER_TIMEOUT
Contributor guide
Assessment
This issue has not been assessed yet.