[英]Web request tracing in node.js
I have a web application with node + express.我有一个带有 node + express 的 Web 应用程序。 I want to record web request execution from start to end which include some db calls as well.
我想从头到尾记录 Web 请求执行,其中还包括一些 db 调用。 How could I map the context of http request to db call context.
如何将 http 请求的上下文映射到 db 调用上下文。 I have tried async_hook APIs as well.
我也尝试过 async_hook API。 Found that in case of db calls it uses the old connection instead of creating new connection.
发现在 db 调用的情况下,它使用旧连接而不是创建新连接。 In this condition how can I map http request to db call?
在这种情况下,如何将 http 请求映射到 db 调用? Thanks in advance.
提前致谢。
Try eizer Zipkin or this https://blog.risingstack.com/distributed-tracing-opentracing-node-js/试试 eizer Zipkin 或这个https://blog.risingstack.com/distributed-tracing-opentracing-node-js/
Ps Db requests tracing - is painful task =) Ps Db 请求跟踪 - 是痛苦的任务 =)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.