You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
See [samples/LoopHostingApp](samples/LoopHostingApp).
118
118
119
+
### Metrics
120
+
121
+
LogicLooper provides metrics using the Metric API. This allows you to obtain the number of LogicLoopers and registered actions, as well as the execution time per loop.
122
+
123
+
To enable metrics collection, install the `LogicLooper.Diagnostics` package and call `AddLogicLooperMetrics`.
124
+
125
+
```csharp
126
+
services.AddLogicLooperMetrics();
127
+
```
128
+
129
+
|Instrumentation|Unit|Description|
130
+
|---|---|---|
131
+
|LogicLooper.shared_pool.loopers|`{looper}`|Number of LogicLooper instances running in LogicLooperPool.Shared|
132
+
|LogicLooper.shared_pool.running_actions|`{action}`|Number of actions registered in LogicLooperPool.Shared that are running in LogicLooper|
133
+
|LogicLooper.running_loopers|`{looper}`|Number of LogicLooper instances running in the process|
134
+
|LogicLooper.running_actions|`{action}`|Number of actions registered in LogicLooper that are running in the process|
135
+
|LogicLooper.processing_duration_min|`ms`|Minimum execution time of one loop in the process for LogicLooper|
136
+
|LogicLooper.processing_duration_max|`ms`|Maximum execution time of one loop in the process for LogicLooper|
137
+
|LogicLooper.processing_duration_avg|`ms`|Average execution time of one loop in the process for LogicLooper|
138
+
139
+
119
140
## Advanced
120
141
### Unit tests / Frame-by-Frame execution
121
142
If you want to write unit tests with LogicLooper or update frames manually, you can use `ManualLogicLooper` / `ManualLogicLooperPool`.
0 commit comments