统一的跨组件事务诊断Unified cross-component transaction diagnostics

统一诊断体验自动将所有受 Application Insights 监视的组件中的服务器端遥测关联到一个单独的视图。The unified diagnostics experience automatically correlates server-side telemetry from across all your Application Insights monitored components into a single view. 是否拥有多个资源和单独的检测密钥并不重要。It doesn't matter if you have multiple resources with separate instrumentation keys. Application Insights 可检测基础关系,并可用于轻松诊断导致事务缓慢或失败的应用程序组件、依赖项或异常。Application Insights detects the underlying relationship and allows you to easily diagnose the application component, dependency, or exception that caused a transaction slowdown or failure.

组件是什么?What is a Component?

组件是分布式/微服务应用程序的可独立部署的部件。Components are independently deployable parts of your distributed/microservices application. 开发者或操作团队具有代码级可见性,或有权访问由这些应用程序组件生成的遥测。Developers and operations teams have code-level visibility or access to telemetry generated by these application components.

  • 组件与“观察到的”外部依赖项(如 SQL 和 EventHub 等)不同,团队/组织可能无权访问(代码或遥测)。Components are different from "observed" external dependencies such as SQL, EventHub etc. which your team/organization may not have access to (code or telemetry).
  • 组件在任意数目的服务器/角色/容器实例上运行。Components run on any number of server/role/container instances.
  • 组件可以是单独的 Application Insights 检测密钥(即使订阅并不相同),或是向单个 Application Insights 检测密钥报告的不同角色。Components can be separate Application Insights instrumentation keys (even if subscriptions are different) or different roles reporting to a single Application Insights instrumentation key. 新体验显示了所有组件的详细信息,而不论其设置方式。The new experience shows details across all components, regardless of how they have been set up.

备注

  • 缺少相关的项链接?Missing the related item links? 所有相关的遥测都位于左侧的顶部底部部分。All of the related telemetry are in the top and bottom sections of the left side.

事务诊断体验Transaction diagnostics experience

此视图有四个关键部分:结果列表、跨组件事务图、与此操作相关的所有遥测的时序列表,以及左侧的详细信息窗格(显示任何选定遥测项的详细信息)。This view has four key parts: results list, a cross-component transaction chart, a time-sequence list of all telemetry related to this operation, and the details pane for any selected telemetry item on the left.

关键部分

跨组件事务图Cross-component transaction chart

此图提供使用水平条的时间线,表示请求的持续时间及各组件间的依赖项。This chart provides a timeline with horizontal bars for the duration of requests and dependencies across components. 收集的任何异常也会标记在时间线上。Any exceptions that are collected are also marked on the timeline.

  • 此图的最上面一行表示入口点,即在此事务中调用的第一个组件的传入请求。The top row on this chart represents the entry point, the incoming request to the first component called in this transaction. 持续时间是指完成事务所用的总时间。The duration is the total time taken for the transaction to complete.
  • 对外部依赖项的任何调用都是简单的不可折叠行,以图标表示依赖项类型。Any calls to external dependencies are simple non-collapsible rows, with icons representing the dependency type.
  • 对其它组件的调用均属于可折叠行。Calls to other components are collapsible rows. 每一行都与在组件处调用的特定操作对应。Each row corresponds to a specific operation invoked at the component.
  • 默认情况下,所选择的请求、依赖项或异常显示在右侧。By default, the request, dependency, or exception that you selected is displayed on the right side.
  • 选择任意行,在右侧查看其详细信息Select any row to see its details on the right.

备注

对其他组件的调用包括两行:一行表示来自调用方组件的出站调用(依赖项),另一行对应于调用的组件处的入站请求。Calls to other components have two rows: one row represents the outbound call (dependency) from the caller component, and the other row corresponds to the inbound request at the called component. 可通过前导图标和样式不同的持续时间条来区分它们。The leading icon and distinct styling of the duration bars help differentiate between them.

所有使用此操作 ID 的遥测All telemetry with this Operation Id

本部分以与此事务相关的所有遥测的时间序列显示平面列表视图。This section shows flat list view in a time sequence of all the telemetry related to this transaction. 它还显示自定义事件以及未在事务图中显示的跟踪。It also shows the custom events, and traces that aren't displayed in the transaction chart. 可以将此列表筛选为特定组件/调用生成的遥测。You can filter this list to telemetry generated by a specific component/call. 可以在此列表中选择任意遥测项,并在右侧查看相应的详细信息You can select any telemetry item in this list to see corresponding details on the right.

所有遥测的时间序列

所选遥测数据的详细信息Details of the selected telemetry

此可折叠窗格显示事务图或列表中任何所选项的详细信息。This collapsible pane shows the detail of any selected item from the transaction chart, or the list. “显示全部”列出了收集的所有标准属性。"Show all" lists all of the standard attributes that are collected. 所有自定义属性都单独列在标准集之下。Any custom attributes are separately listed below the standard set. 单击堆栈跟踪窗口下方的“...”以获取复制跟踪的选项。Click on the "..." below the stack trace window to get an option to copy the trace. “打开探查器跟踪”或“打开调试快照”在相应的详细信息窗格中查看代码级诊断信息。"Open profiler traces" or "Open debug snapshot" shows code level diagnostics in corresponding detail panes.

异常详细信息

搜索结果Search results

此可折叠窗格会显示符合筛选条件的其他结果。This collapsible pane shows the other results that meet the filter criteria. 单击任何结果可更新上面列出的 3 个部分的相应详细信息。Click on any result to update the respective details the 3 sections listed above. 我们试图找到最可能从所有组件中获得详细信息的样本,即使在任何一个组件中采样都是有效的。We try to find samples that are most likely to have the details available from all components even if sampling is in effect in any of them. 这些显示为“建议的”样本。These are shown as "suggested" samples.

搜索结果

常见问题FAQ

图中只显示了一个组件,其余组件仅显示为外部依赖项,没有显示有关这些组件内发生的情况的详细信息 。I see a single component on the chart, and the others are only showing as external dependencies without any detail of what happened within those components.

可能的原因:Potential reasons:

  • 是否使用 Application Insights 检测了其他组件?Are the other components instrumented with Application Insights?
  • 是否使用了最新的稳定 Application Insights SDK?Are they using the latest stable Application Insights SDK?
  • 如果这些组件是单独的 Application Insights 资源,你是否具有访问其遥测的所需权限?If these components are separate Application Insights resources, do you have required access to their telemetry?

如果确实具有权限,且使用了最新的 Application Insights SDK 来检测组件,请通过右上方的反馈通道告知我们。If you do have access and the components are instrumented with the latest Application Insights SDKs, let us know via the top right feedback channel.

依赖项具有重复的行。 这是正常情况吗?I see duplicate rows for the dependencies. Is this expected?

当前,出站依赖项调用与入站请求分开显示。At this time, we are showing the outbound dependency call separate from the inbound request. 通常情况下,这两种调用大致相同,但持续时间值因网络往返而不同。Typically, the two calls look identical with only the duration value being different due to the network round trip. 可通过前导图标和样式不同的持续时间条来区分它们。The leading icon and distinct styling of the duration bars help differentiate between them. 这份数据演示文稿是否包含令人困惑的内容?Is this presentation of the data confusing? 欢迎提供反馈!Give us your feedback!

不同组件实例间的时钟偏差情况如何? What about clock skews across different component instances?

在事务图中针对时钟偏差调整了时间线。Timelines are adjusted for clock skews in the transaction chart. 可以在详细信息窗格中查看确切的时间戳,或使用“Analytics”进行查看。You can see the exact timestamps in the details pane or by using Analytics.

为什么新体验中缺少大部分相关项查询? Why is the new experience missing most of the related items queries?

这是设计使然。This is by design. 所有组件的全部相关项都已显示在左侧(顶部和底部)。All of the related items, across all components, are already available on the left side (top and bottom sections). 新体验中有两个左侧未包含的相关项:此事件发生前后五分钟内的所有遥测,以及用户时间线。The new experience has two related items that the left side doesn't cover: all telemetry from five minutes before and after this event and the user timeline.