gpt4 book ai didi

java - "Dispatcher"对 NewRelic 的 @Trace 注解做了什么

转载 作者:搜寻专家 更新时间:2023-10-31 20:04:47 24 4
gpt4 key购买 nike

New Relic 的 @Trace 注解的 dispatcher 属性有什么作用?我能找到的所有示例都将其设置为 true - 如果将其设置为 false 会怎样?

最佳答案

基本上,dispatcher=true 的意思是“将此方法视为我要与其他类型的请求分开监视的请求的开始”。

来自documentation on monitoring Java background processes with New Relic :

The dispatcher=true option causes the annotated method to be treated like a web transaction--the agent will report errors and transaction traces for the task.

设置为false,跟踪的方法本身不会被视为事务,并且只有在从已经报告的事务中调用时才会出现在 New Relic 中。

关于java - "Dispatcher"对 NewRelic 的 @Trace 注解做了什么,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11036236/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com