.NET 9 中的 RuntimeMetrics

.NET-MetricsNet捕捉CLR和应用级监测 Metrics-Net - 捕捉CLR 和应用级监测,让你请清楚发生了什么 立即下载

.NET 9 中的 RuntimeMetrics

Intro

.NET 9 中引入了 RuntimeMetrics,基于 dotnet 里的 metrics 实现 System.Diagnostic.Metrics.Meter 来生成 metrics 数据,包含了 CPU、内存、GC、JIT 以及线程等信息

Sample

那我们就结合 OpenTelemetry 来看一个简单的示例,sample 引用了 OpenTelemetry.Exporter.Console 将 metrics 数据直接导出到 console

using var _ = Sdk.CreateMeterProviderBuilder()
    .AddMeter("System.Runtime")
    .AddConsoleExporter()
    .Build();

while (true)
{
    await Task.Delay(TimeSpan.FromSeconds(10));
    GC.Collect();
}

运行结果如下:

d57ab9c86ea0bdb14e1e467e6659a5a0.png

40edfa90756aaa9e47eddca141d6171c.png

Metric Name: dotnet.gc.collections, The number of garbage collections that have occurred since the process has started., Unit: {collection}, Meter: System.Runtime
(2024-09-15T11:24:26.3765112Z, 2024-09-15T11:24:36.3639680Z] gc.heap.generation: gen2 LongSum
Value: 0
(2024-09-15T11:24:26.3765112Z, 2024-09-15T11:24:36.3639680Z] gc.heap.generation: gen1 LongSum
Value: 0
(2024-09-15T11:24:26.3765112Z, 2024-09-15T11:24:36.3639680Z] gc.heap.generation: gen0 LongSum
Value: 0

Metric Name: dotnet.process.memory.working_set, The number of bytes of physical memory mapped to the process context., Unit: By, Meter: System.Runtime
(2024-09-15T11:24:26.3779803Z, 2024-09-15T11:24:36.3640471Z] LongSumNonMonotonic
Value: 29241344

Metric Name: dotnet.gc.heap.total_allocated, The approximate number of bytes allocated on the managed GC heap since the process has started. The returned value does not include any native allocations., Unit: By, Meter: System.Runtime
(2024-09-15T11:24:26.3779975Z, 2024-09-15T11:24:36.3640481Z] LongSum
Value: 3427736

Metric Name: dotnet.gc.pause.time, The total amount of time paused in GC since the process has started., Unit: s, Meter: System.Runtime
(2024-09-15T11:24:26.3793018Z, 2024-09-15T11:24:36.3640951Z] DoubleSum
Value: 0

Metric Name: dotnet.jit.compiled_il.size, Count of bytes of intermediate language that have been compiled since the process has started., Unit: By, Meter: System.Runtime
(2024-09-15T11:24:26.3793233Z, 2024-09-15T11:24:36.3640965Z] LongSum
Value: 67761

Metric Name: dotnet.jit.compiled_methods, The number of times the JIT compiler (re)compiled methods since the process has started., Unit: {method}, Meter: System.Runtime
(2024-09-15T11:24:26.3793381Z, 2024-09-15T11:24:36.3640975Z] LongSum
Value: 829

Metric Name: dotnet.jit.compilation.time, The number of times the JIT compiler (re)compiled methods since the process has started., Unit: s, Meter: System.Runtime
(2024-09-15T11:24:26.3793520Z, 2024-09-15T11:24:36.3640985Z] DoubleSum
Value: 1.3528453

Metric Name: dotnet.monitor.lock_contentions, The number of times there was contention when trying to acquire a monitor lock since the process has started., Unit: {contention}, Meter: System.Runtime
(2024-09-15T11:24:26.3793612Z, 2024-09-15T11:24:36.3641010Z] LongSum
Value: 0

Metric Name: dotnet.thread_pool.thread.count, The number of thread pool threads that currently exist., Unit: {thread}, Meter: System.Runtime
(2024-09-15T11:24:26.3793740Z, 2024-09-15T11:24:36.3641018Z] LongSum
Value: 1

Metric Name: dotnet.thread_pool.work_item.count, The number of work items that the thread pool has completed since the process has started., Unit: {work_item}, Meter: System.Runtime
(2024-09-15T11:24:26.3793850Z, 2024-09-15T11:24:36.3641026Z] LongSum
Value: 2

Metric Name: dotnet.thread_pool.queue.length, The number of work items that are currently queued to be processed by the thread pool., Unit: {work_item}, Meter: System.Runtime
(2024-09-15T11:24:26.3793936Z, 2024-09-15T11:24:36.3641034Z] LongSum
Value: 0

Metric Name: dotnet.timer.count, The number of timer instances that are currently active. An active timer is registered to tick at some point in the future and has not yet been canceled., Unit: {timer}, Meter: System.Runtime
(2024-09-15T11:24:26.3794100Z, 2024-09-15T11:24:36.3641060Z] LongSumNonMonotonic
Value: 2

Metric Name: dotnet.assembly.count, The number of .NET assemblies that are currently loaded., Unit: {assembly}, Meter: System.Runtime
(2024-09-15T11:24:26.3794199Z, 2024-09-15T11:24:36.3641072Z] LongSumNonMonotonic
Value: 33

Metric Name: dotnet.process.cpu.count, The number of processors available to the process., Unit: {cpu}, Meter: System.Runtime
(2024-09-15T11:24:26.3794408Z, 2024-09-15T11:24:36.3641099Z] LongSumNonMonotonic
Value: 22

Metric Name: dotnet.process.cpu.time, CPU time used by the process., Unit: s, Meter: System.Runtime
(2024-09-15T11:24:26.3794527Z, 2024-09-15T11:24:36.3641105Z] cpu.mode: user DoubleSum
Value: 0.15625
(2024-09-15T11:24:26.3794527Z, 2024-09-15T11:24:36.3641105Z] cpu.mode: system DoubleSum
Value: 0

随着我们触发 GC.Collect GC 回收的 metrics 也会发生变化

Metric Name: dotnet.gc.collections, The number of garbage collections that have occurred since the process has started., Unit: {collection}, Meter: System.Runtime
(2024-09-15T11:24:26.3765112Z, 2024-09-15T11:25:06.3409748Z] gc.heap.generation: gen2 LongSum
Value: 3
(2024-09-15T11:24:26.3765112Z, 2024-09-15T11:25:06.3409748Z] gc.heap.generation: gen1 LongSum
Value: 0
(2024-09-15T11:24:26.3765112Z, 2024-09-15T11:25:06.3409748Z] gc.heap.generation: gen0 LongSum
Value: 0

Metric Name: dotnet.process.memory.working_set, The number of bytes of physical memory mapped to the process context., Unit: By, Meter: System.Runtime
(2024-09-15T11:24:26.3779803Z, 2024-09-15T11:25:06.3409766Z] LongSumNonMonotonic
Value: 36999168

Metric Name: dotnet.gc.heap.total_allocated, The approximate number of bytes allocated on the managed GC heap since the process has started. The returned value does not include any native allocations., Unit: By, Meter: System.Runtime
(2024-09-15T11:24:26.3779975Z, 2024-09-15T11:25:06.3409774Z] LongSum
Value: 3602608

Metric Name: dotnet.gc.last_collection.memory.committed_size, The amount of committed virtual memory in use by the .NET GC, as observed during the latest garbage collection., Unit: By, Meter: System.Runtime
(2024-09-15T11:24:26.3780104Z, 2024-09-15T11:25:06.3409782Z] LongSumNonMonotonic
Value: 4530176

Metric Name: dotnet.gc.last_collection.heap.size, The managed GC heap size (including fragmentation), as observed during the latest garbage collection., Unit: By, Meter: System.Runtime
(2024-09-15T11:24:26.3780292Z, 2024-09-15T11:25:06.3409791Z] gc.heap.generation: gen0 LongSumNonMonotonic
Value: 0
(2024-09-15T11:24:26.3780292Z, 2024-09-15T11:25:06.3409791Z] gc.heap.generation: gen1 LongSumNonMonotonic
Value: 560
(2024-09-15T11:24:26.3780292Z, 2024-09-15T11:25:06.3409791Z] gc.heap.generation: gen2 LongSumNonMonotonic
Value: 466256
(2024-09-15T11:24:26.3780292Z, 2024-09-15T11:25:06.3409791Z] gc.heap.generation: loh LongSumNonMonotonic
Value: 2739800
(2024-09-15T11:24:26.3780292Z, 2024-09-15T11:25:06.3409791Z] gc.heap.generation: poh LongSumNonMonotonic
Value: 9232

Metric Name: dotnet.gc.last_collection.heap.fragmentation.size, The heap fragmentation, as observed during the latest garbage collection., Unit: By, Meter: System.Runtime
(2024-09-15T11:24:26.3789008Z, 2024-09-15T11:25:06.3409804Z] gc.heap.generation: gen0 LongSumNonMonotonic
Value: 0
(2024-09-15T11:24:26.3789008Z, 2024-09-15T11:25:06.3409804Z] gc.heap.generation: gen1 LongSumNonMonotonic
Value: 80
(2024-09-15T11:24:26.3789008Z, 2024-09-15T11:25:06.3409804Z] gc.heap.generation: gen2 LongSumNonMonotonic
Value: 24
(2024-09-15T11:24:26.3789008Z, 2024-09-15T11:25:06.3409804Z] gc.heap.generation: loh LongSumNonMonotonic
Value: 608
(2024-09-15T11:24:26.3789008Z, 2024-09-15T11:25:06.3409804Z] gc.heap.generation: poh LongSumNonMonotonic
Value: 0

Metric Name: dotnet.gc.pause.time, The total amount of time paused in GC since the process has started., Unit: s, Meter: System.Runtime
(2024-09-15T11:24:26.3793018Z, 2024-09-15T11:25:06.3409815Z] DoubleSum
Value: 0.007868

Metric Name: dotnet.jit.compiled_il.size, Count of bytes of intermediate language that have been compiled since the process has started., Unit: By, Meter: System.Runtime
(2024-09-15T11:24:26.3793233Z, 2024-09-15T11:25:06.3409821Z] LongSum
Value: 102621

Metric Name: dotnet.jit.compiled_methods, The number of times the JIT compiler (re)compiled methods since the process has started., Unit: {method}, Meter: System.Runtime
(2024-09-15T11:24:26.3793381Z, 2024-09-15T11:25:06.3409826Z] LongSum
Value: 1196

Metric Name: dotnet.jit.compilation.time, The number of times the JIT compiler (re)compiled methods since the process has started., Unit: s, Meter: System.Runtime
(2024-09-15T11:24:26.3793520Z, 2024-09-15T11:25:06.3409832Z] DoubleSum
Value: 1.7024187

Metric Name: dotnet.monitor.lock_contentions, The number of times there was contention when trying to acquire a monitor lock since the process has started., Unit: {contention}, Meter: System.Runtime
(2024-09-15T11:24:26.3793612Z, 2024-09-15T11:25:06.3409859Z] LongSum
Value: 0

Metric Name: dotnet.thread_pool.thread.count, The number of thread pool threads that currently exist., Unit: {thread}, Meter: System.Runtime
(2024-09-15T11:24:26.3793740Z, 2024-09-15T11:25:06.3409867Z] LongSum
Value: 1

Metric Name: dotnet.thread_pool.work_item.count, The number of work items that the thread pool has completed since the process has started., Unit: {work_item}, Meter: System.Runtime
(2024-09-15T11:24:26.3793850Z, 2024-09-15T11:25:06.3409875Z] LongSum
Value: 8

Metric Name: dotnet.thread_pool.queue.length, The number of work items that are currently queued to be processed by the thread pool., Unit: {work_item}, Meter: System.Runtime
(2024-09-15T11:24:26.3793936Z, 2024-09-15T11:25:06.3409883Z] LongSum
Value: 0

Metric Name: dotnet.timer.count, The number of timer instances that are currently active. An active timer is registered to tick at some point in the future and has not yet been canceled., Unit: {timer}, Meter: System.Runtime
(2024-09-15T11:24:26.3794100Z, 2024-09-15T11:25:06.3409890Z] LongSumNonMonotonic
Value: 2

Metric Name: dotnet.assembly.count, The number of .NET assemblies that are currently loaded., Unit: {assembly}, Meter: System.Runtime
(2024-09-15T11:24:26.3794199Z, 2024-09-15T11:25:06.3409895Z] LongSumNonMonotonic
Value: 36

Metric Name: dotnet.process.cpu.count, The number of processors available to the process., Unit: {cpu}, Meter: System.Runtime
(2024-09-15T11:24:26.3794408Z, 2024-09-15T11:25:06.3409908Z] LongSumNonMonotonic
Value: 22

Metric Name: dotnet.process.cpu.time, CPU time used by the process., Unit: s, Meter: System.Runtime
(2024-09-15T11:24:26.3794527Z, 2024-09-15T11:25:06.3409913Z] cpu.mode: user DoubleSum
Value: 0.203125
(2024-09-15T11:24:26.3794527Z, 2024-09-15T11:25:06.3409913Z] cpu.mode: system DoubleSum
Value: 0

详细的 metrics 如下:

  • dotnet.process.cpu.time 进程使用的 CPU 时间(Counter)

    • cpu.mode:user/system,分为两种,用户态和系统态分别占用的时间,分别对应了 process 的  UserProcessorTime 和 PrivilegedProcessorTime

  • dotnet.process.memory.working_set 映射到进程上下文的物理内存字节数 (UpDownCounter),对应 Environment.WorkingSet

  • dotnet.gc.collections 垃圾回收的次数(Counter)

    • dotnet.gc.heap.generation 垃圾回收所属堆的最大代数,比如 gen0/gen1/gen2

  • dotnet.gc.heap.total_allocated GC 堆总计大约分配的字节数(Counter),对应 GC.GetTotalAllocatedBytes()

  • dotnet.gc.last_collection.memory.committed_size 最近一次垃圾回收期间 GC 占用的提交内存(UpDownCounter),对应 GCMemoryInfo.TotalCommittedBytes

  • dotnet.gc.last_collection.heap.size 在最近一次垃圾回收期间观察到的托管GC堆大小(包括碎片)(UpDownCounter)

    • dotnet.gc.heap.generation 垃圾回收器托管堆代数名称 (gen0/gen1/gen2/loh/poh)

  • dotnet.gc.last_collection.heap.fragmentation.size 在最近的垃圾回收中观察到的堆碎片化情况(UpDownCounter)对应 GCGenerationInfo.FragmentationAfterBytes

  • dotnet.gc.pause.time GC暂停的总时间(Counter)对应 GC.GetTotalPauseDuration()

  • dotnet.jit.compiled_il.size 已编译的中间语言字节数(Counter)对应 JitInfo.GetCompiledILBytes

  • dotnet.jit.compiled_methods JIT编译器(重新)编译方法的次数(Counter)对应 JitInfo.GetCompiledMethodCount

  • dotnet.jit.compilation.time JIT编译器花费在编译方法上的时间(Counter)对应  JitInfo.GetCompilationTime

  • dotnet.thread_pool.thread.count 当前存在的线程池线程数量(UpDownCounter)对应 ThreadPool.ThreadCount

  • dotnet.thread_pool.work_item.count 线程池已完成的工作项数量(Counter)对应 ThreadPool.CompletedWorkItemCount

  • dotnet.thread_pool.queue.length  当前排队等待线程池处理的工作项数量(UpDownCounter)对应 ThreadPool.PendingWorkItemCount

  • dotnet.monitor.lock_contentions 尝试获取 Monitor 锁时发生争用的次数(Counter)对应  Monitor.LockContentionCount

  • dotnet.timer.count 当前活动的 Timer 实例数量(UpDownCounter)对应 Timer.ActiveCount

  • dotnet.assembly.count 当前加载的 .NET 程序集数量(UpDownCounter) 对应  AppDomain.GetAssemblies() 的数量

  • dotnet.exceptions 在托管代码中抛出的异常数量(Counter),对应  AppDomain.FirstChanceException event 的触发次数

    • error.type Exception 的类型,例如:System.OperationCanceledException/Contoso.MyException

More

结合这些信息可以比较轻松地了解当前的 CPU,memory,GC,thread 等信息,对于了解当前应用是否健康非常的有帮助,除了在进程内使用 OpenTelemetry 来导出 metrics 之外也可以使用进程外的 dotnet-counters 等诊断工具来观察。

观察 CPU 数据来观察是否有过高的 CPU 使用

观察内存和 GC 数据看是否有垃圾回收、内存泄漏以及内存碎片之类的问题

观察线程池中队列和线程数的情况来查看是否有线程池饿死(thread pool starvation)的情况

观察 lock contention 来看是否有死锁以及锁不合理的使用

总而言之, runtime metrics  使得我们的应用可以有更好的观测性,获取当前应用的状态信息更加地方便了

References

  • https://github.com/dotnet/runtime/issues/85372

  • https://github.com/dotnet/runtime/pull/104680

  • https://github.com/dotnet/runtime/issues/105845

  • https://github.com/dotnet/runtime/pull/106014

  • https://github.com/open-telemetry/opentelemetry-dotnet-contrib/tree/main/src/OpenTelemetry.Instrumentation.Runtime

  • https://learn.microsoft.com/en-us/dotnet/core/diagnostics/built-in-metrics-runtime

  • https://github.com/WeihanLi/SamplesInPractice/blob/main/net9sample/Net9Samples/RuntimeMetricsSample.cs

从数据集到产品:聊聊Room-to-Room (R2R) 如何影响扫地机器人、AR导航的未来 本文探讨了Room-to-Room (R2R) 数据集如何推动视觉与语言导航(VLN)技术的发展,并重塑扫地机器人和AR导航的未来。通过分析R2R基于Matterport3D的设计及其在真实场景中的应用,揭示了其在提升智能导航精度和自然语言交互能力方面的潜力。文章还讨论了从实验室到产品化的关键技术挑战与解决方案。 阅读详情

相关推荐

单相PWM整流器四象限运行原理

简述单相PWM整流器四象限运行原理。

m0_75208156的博客 8343

.net应用监控类库Metrics.NET入门

要开始使用库,请安装Metrics.NET NuGet包,使用包管理UI或包管理控制台运行: Install-Package Metrics.NET 在您的应用程序的初始化代码中添加以下Metrics.NET配置代码: using Metrics; Metric.Config .WithHttpEndpoint("http://localhost:1234/") .

Welcome to Leonard's weblog! 2574

PX4无人机实战:手把手教你用MAVROS实现Offboard模式(附避坑指南)

本文提供了一份详尽的PX4无人机Offboard模式实战指南,重点解析了如何通过MAVROS实现从仿真到实机的控制。内容涵盖硬件连接、串口权限设置、MAVROS配置、核心代码编写以及实机操作全流程,并附有详细的避坑指南和故障排查手册,帮助开发者快速掌握ROS与PX4飞控的集成开发。

weixin_29172201的博客 273

Metrics.NET:强大的.NET性能监控库

Metrics.NET:强大的.NET性能监控库 是一个开源项目,专为.NET开发者设计,用于在应用程序中轻松集成和度量各种性能指标。它提供了丰富的API,使你能跟踪、记录并可视化你的代码运行时的各种数据,从而帮助你优化代码,提升应用性能。 技术分析 Metrics.NET的核心是一个灵活且可扩展的设计,它允许你在代码中定义多种类型的度量,如计数器、定时器、滑动窗口统计等。这些度量可以被自动报告到...

gitblog_00069的博客 530

ARM和FPGA之间的通信(硬件原理图篇)

设计该开发板的初衷是为了学习,但也希望今后能扩展其功能,看到大家都在diy示波器,自己也非常冲动的想DIY一把,于是呼选了arm+fpga的方案,fpga主要用来实现数据的高速采样,而ARM则提供数据的显示,以及一些人机交互的功能。那么该方案中最重要的地方就是ARM和FPGA之间的通信如何实现了。在网上查了很多的资料,有说将FPGA作为ARM的一个外设,可以通过DMA的方式来直接访问;也有说把FP

屌yy的博客 5万+

Keil 丢失编译器版本5、内核文件core_cm3.c报错

若用的是旧版本的core_cm3.c ,就使用编译器v5编译工程;若想用编译器v6,就更新4个相关的内核文件:(CMSIS:Cortex Microcontroller Software Interface Standard,ARM Cortex™ 微控制器软件接口标准)

qq_52804040的博客 6250

.NET6之MiniAPI(二十七):Metrics

应用的各种Metrics是保证应用健康稳定运行的基础,特别对于一些可用性有所要求的应用,本文介绍prometheus-net这个三方指示库。prometheus-net的工作原理是,在应用内部埋点,通过prometheus采集数据,然后通过grafana把采集到的数据展现出来,所以这里首先要下载prometheus和grafana,因为是demo,这里下载两个应用的win...

dotNET跨平台 948

LeRobot SO-ARM100 学习笔记(2) diffusion module

对 lerobot 中的 diffusion policy 进行基本的代码阅读

mikhailbran的博客 1592

【译】.NET 8 网络改进(一)

▲点击上方“DotNet NB”关注公众号回复“1”获取开发者路线图学习分享丨作者/郑子铭这是DotNetNB公众号的第223篇原创文章原文 | Máňa,Natalia Kondratyeva翻译 | 郑子铭随着新的 .NET 版本的发布,发布有关网络空间中新的有趣变化的博客文章已成为一种传统。今年,我们希望引入 HTTP 空间的变化、新添加的指标、新的 HttpClie...

dotNET跨平台 196

ESP32固定翼航模硬件设计与飞行力学解析

固定翼无人机是嵌入式控制与空气动力学交叉实践的经典载体,其飞行稳定性本质源于重心、气动中心与控制面的物理耦合关系。理解静稳定度(Static Margin)、升力系数调控、偏航力矩生成等基础原理,是实现可靠姿态控制的前提。在低成本工程约束下,材料刚度、结构弹性与电机-驱动协同设计共同决定了系统动态响应边界。ESP32平台凭借高精度PWM、低功耗双模无线及丰富GPIO,成为教学级航模开发的理想主控;而魔术贴基板、可调电池配重、柔性尾翼等创新结构,则将抽象的飞行力学概念转化为可测量、可调试的实体对象,广泛应用于

weixin_29859471的博客 368

72、海洋地理信息系统:电子海图的全面解析

本文全面解析了海洋地理信息系统中的电子海图技术,从AIS数据的应用、电子海图数据的存储与显示,到电子导航的发展趋势和S-100通用水文数据模型的推广,系统地阐述了电子海图在现代航海中的核心作用及其未来发展方向。

hhh00的博客 260

Metrics.NET 使用教程

Metrics.NET 是一个用于 .NET 应用程序的度量工具库,提供了对应用程序进行自定义度量(如计时器、直方图、计数器等)的功能。通过这个库,开发者可以收集和报告各种度量数据,从而深入了解应用程序的运行状态。 Metrics.NET 是基于 Java 的 Metrics 库的一个 .NET 移植版本,增加了许多额外的功能。它可以帮助开发者监控应用程序的性能和健康状况,提供有价值的洞察。

gitblog_00932的博客 751

ansys license许可证问题:Ansys License Manager Release 2024 R1...如何解决?

🏆本文收录于 《全栈 Bug 调优(实战版)》 专栏。专栏聚焦真实项目中的各类疑难 Bug,从成因剖析 → 排查路径 → 解决方案 → 预防优化全链路拆解,形成一套可复用、可沉淀的实战知识体系。无论你是初入职场的开发者,还是负责复杂项目的资深工程师,都可以在这里构建一套属于自己的「问题诊断与性能调优」方法论,助你稳步进阶、放大技术价值 。

**My Coding Family** 5393

【微软MVP亲测】.NET 9跨平台边缘部署Checklist(含21项必验指标、13个YAML模板、8个Shell诊断脚本)——限免领取最后48小时

微软MVP实测验证的.NET 9跨平台边缘部署优化步骤,覆盖IoT、工业网关等轻量场景,提供精简镜像构建、资源约束配置与离线运行保障。含21项必验指标、13个YAML模板及8个Shell诊断脚本,显著提升部署稳定性与启动速度,值得收藏。

Instrulink的博客 144

计算机控制技术及应用

《计算机控制技术及应用》通过总结作者的科研成果和吸收国内外的先进理论、方法和技术,以计算机控制系统的网络化、开放化、智能化和集成化发展趋势为主线索,主要介绍计算机控制系统的基本概念和计算机控制系统的典型形式,计算机控制系统的数学描述与基本分析方法,以及数字PID控制器、最少拍控制系统、达林算法、状态变量设计法等设计方法及其各种改进算法。重点突出计算机控制系统输入输出通道接口的设计方法和典型控制系统的设计案例与实现方法等。

C# WinForm 基于DirectShow.dll编写的程序,可边预览边保存视频,音频和图片

基于微软的DirectShow.dll的二次开发1.自动识别连接的摄像头跟麦克风且可以对其进行选择(默认选中第一个)2.可录制wmv和avi两种格式的视频并且都带有音频,avi可以录制的分辨率和帧数进行选择,wmv默认进行了淸晰度优化如不喜欢可去除代码中有相关提示3.可在预览点开之后进行拍照,也可边录制视频边拍照4.添加了视频和音频的压缩功能(酌情使用)这次二次开发发现C#对DirectShow的相关信息太少,这次做完也不敢藏私共享出来,还望大家指正

.NET运行时指标三件套:opentelemetry-dotnet-contrib的Runtime、Process与EventCounters监控完整清单

opentelemetry-dotnet-contrib 是 OpenTelemetry .NET SDK 的官方扩展组件仓库,其中就包含一组开箱即用的 **.NET 运行时指标监控** 三件套:**Runtime、Process、EventCounters** 三套 Instrumentation。它们分别盯住 **GC 垃圾回收、JIT 编译、线程池** 等运行时内部行为,**CPU 使用率、

gitblog_01092的博客 1062

数学建模模型总结

这是本人在两年内准备参加数学建模竞赛搜集到的模型资料,已经经过了本人的筛选和整理,希望能够对准备参加数学建模竞赛的学弟学妹们提供一些帮助!

Metrics.NET:.NET 应用性能监控的利器

**许可证**:Apache 2.0 License

gitblog_00803的博客 826

STM32F407中文手册

STM32f407中文手册 本参考手册面向应用开发人员,提供有关使用 STM32F405xx/07xx、STM32F415xx/17xx、 STM32F42xxx 和 STM32F43xxx 微控制器存储器与外设的完整信息。STM32F405xx/07xx、STM32F415xx/17xx、STM32F42xxx 和 STM32F43xxx 构成一个微 控制器系列,各产品具有不同的存储器大小、封装和外设。有关订购信息以及器件的机械与电气特性,请参见数据手册。有关 ARM Cortex™-M4F 内核的信息,请参见《Cortex™-M4F 技术参考手册》。

jetson-inference 实战:用 Flask + REST 打造多模型 WebRTC 交互式 DNN 控制台

本篇指南聚焦 jetson-inference 仓库中的 [Flask + REST 示例](https://link.gitcode.com/i/04cc6eecfd5f0c967dea15e38e06eb37),讲解如何基于 Flask 微框架与 REST JSON 接口构建一个可在浏览器中实时观看、动态切换与调参的多模型深度学习推理控制台。读完本文,你将掌握该 WebApp 的启动方式、多

gitblog_00056的博客 584

【.NET 9低代码革命】:3大Runtime级优化技术首次公开,开发者效率提升47%(微软内部验证数据)

.NET 9低代码优化显著提升开发效率,通过JIT编译增强、AOT预编译优化与低代码运行时沙箱三大Runtime级技术,实现可视化逻辑到原生性能的无缝转化。适用于企业级表单、流程自动化等场景,微软内部验证效率提升47%,值得收藏。

PixelStream的博客 346

.NET 6 全新指标 System.Diagnostics.Metrics 介绍

前言工友们, .NET 6 Preview 7 已经在8月10号发布了, 除了众多的功能更新和性能改进之外, 在 preview 7 版本中, 也新增了全新的指标API,System.D...

dotNET跨平台 731

MeterListener 是 .NET 中 System.Diagnostics.Metrics 命名空间的一部分,用于监听和收集 Meter 发出的度量数据(如 Histogram<T>、 Cou

MeterListener 是 .NET 中 System.Diagnostics.Metrics 命名空间的一部分,用于监听和收集 Meter 发出的度量数据(如 Histogram<T>、 Counter<T> 等)。测试用例代码csharp。代码示例:使用 MeterListener 收集 Histogram 数据以下是针对你之前提到的 Histogram<double> 的完整示例,展示如何使用 MeterListener 收集度量数据并实现 GetTaskAllocation 方法。

专注于前沿技术的探索与实践,热衷于从代码逻辑、架构设计到行业应用等多维度深挖技术本质。期待在技术之路上与你共同成长~ 890

推荐文章:深入探索Metrics.NET —— .NET平台的性能监控利器

推荐文章:深入探索Metrics.NET —— .NET平台的性能监控利器 在当今软件开发的快节奏环境中,系统性能监控成为了确保应用稳定性的关键。今天,我们要向您推荐一款针对.NET生态量身定制的开源神器——Metrics.NET。这是一款基于Java版Dropwizard Metrics库的优秀.NET移植作品,不仅完整保留了其核心功能,还加入了诸多创新特性,旨在简化应用性能监控的复杂度。 1....

gitblog_00939的博客 994

基于.Net的Windows和Linux等平台计算机资源监控系统

CZGL.SystemInfo 是一个支持 Windows 和 Linux 等平台的能够获取机器硬件信息、采集机器资源信息、监控进程资源的库。在不引入额外依赖的情况下,使用 .NET Runtime 本身的 API,或通过计算获得信息,提供高性能的计算方式以及缓存,提高性能,还提供 dotnet tool 工具,通过命令行在终端使用。

毕业作品网站 775

Orleans 可观测性实战:基于源码的指标与分布式追踪(含 Prometheus 集成)

I整理了一份基于源码的 Orleans 可观测性与 Prometheus 集成说明文档(含指标体系、关键代码位置、Tracing、实践建议与 PromQL 示例)。

helloworlddm的博客 824

.NET Core使用OpenTelemetry接入Prometheus+Grafana

本文章内容来自于:https://docs.microsoft.com/en-us/dotnet/core/diagnostics/metrics-collection OpenTelemetry /təˈlemətri/ 是CNCF(Cloud Native Computing Foundation) 推出的标准化生成和收集遥测数据的开源项目。 Prometheus /prəˈmiːθiəs/ 是搞监控和预警的 Grafana /grəˈfɑːnˌɑː/ 展示监控数据的 简要流程: 使用opentelem

生活在底层的低级码农 2465

asp.net core 集成 prometheus

asp.net core 集成 prometheusIntroPrometheus 是一个开源的现代化,云原生的系统监控框架,并且可以轻松的集成 PushGateway, AlertMa...

dotNET跨平台 998

Metrics, tracing 和 logging 的关系

为什么80%的码农都做不了架构师?>>> ...

weixin_34212189的博客 2169
上一篇: ASP.NET Core 知识速递 - Day 3:每天进步一点
下一篇: MonoDevelop 的续集dotdevelop
dotNET跨平台
博客等级 码龄9年 6952粉丝 1790原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值