Troubleshooting Node.js App and API Protection
이 페이지는 아직 한국어로 제공되지 않습니다. 번역 작업 중입니다.
현재 번역 프로젝트에 대한 질문이나 피드백이 있으신 경우
언제든지 연락주시기 바랍니다.App and API Protection is in Preview on Datadog Government site US1-FED.
Common Issues
No security signals appearing
If you don’t see AAP threat information in the Trace and Signals Explorer for your Node.js application, follow these steps to troubleshoot the issue:
Verify Agent version:
- Ensure you’re running Datadog Agent v7.41.1 or higher.
- Check Agent status:
datadog-agent status.
Check Node.js tracer version:
- Confirm you’re using Node.js tracer v4.30.0 or higher.
- Verify the tracer is loaded:
node -e "console.log(require('dd-trace/package.json').version)".
Verify environment variables:
- Ensure
DD_APPSEC_ENABLED=true is set. - Check
DD_SERVICE and DD_ENV are properly configured. - Verify
DD_APM_ENABLED=true if using APM features.
Check tracer initialization:
- Ensure
dd-trace/init is required at the start of your application. - Verify the tracer is properly loaded before your application code.
Application fails to start
Check Node.js version compatibility:
Check dd-trace installation:
- Ensure
dd-trace is properly installed: npm list dd-trace. - Reinstall if necessary:
npm install dd-trace.
Module loading errors:
- Check for conflicts with other SDKs.
- Verify the tracer is required before other modules.
High latency:
- Check Agent resource usage.
- Verify network connectivity between Agent and Datadog.
- Consider adjusting sampling rates.
- Review performance considerations.
High memory usage:
- Monitor Node.js process memory usage.
- Check for memory leaks in your application.
- Consider adjusting tracer configuration.
Configuration issues
Environment variables not recognized:
- Ensure environment variables are set before starting the application.
- Check for typos in environment variable names.
- Verify that the tracer is initialized with the correct configuration.
Tracer initialization problems:
- Make sure
require('dd-trace/init') is the first line in your application. - Check for syntax errors in your tracer configuration.
- Verify that the tracer is being imported correctly.
Still having issues?
If you’re still experiencing problems:
- Check the Application Security Monitoring troubleshooting guide.
- Review the Node.js tracer documentation.
- Enable debug logging:
DD_TRACE_DEBUG=true. - Contact Datadog support.