79d6b0a4b2
- DriverHostActor.StopChild removes the driver's _lastReprovisionUtc stamp (and its deferred-reprovision timer): the map grew per removed id and a re-added driver inherited a backoff it never earned (02/L2). - Stale now registers explicit drops for AttributeValueBatchPublished, AttributeAlarmPublished, ArtifactForApply and ApplyWedged instead of letting them hit Unhandled (02/H5). - DbHealthProbeActor runs its SELECT on the thread pool and pipes the outcome back (single-flight), with a 2 s command timeout on relational providers, so a hung SQL Server no longer pins the actor thread and the cached GetStatus answer stays reachable (02/P7). - TelemetryLocalHub eviction tombstones are timestamped and swept past a 10 min TTL on the next Evict; a TimeProvider ctor is the test seam (02/L4). - Tests: ValuePublishes.Single helper replaces the per-value AttributeValuePublished in CalculationDependencyFlowTests (02/U4, test half; the production receive is owned by Lane E). - R05/8 audit: PollGroupEngine.Unsubscribe has no production caller; every driver already uses UnsubscribeAsync (no change). Refs #731 Claude-Session: https://claude.ai/code/session_01Ub9hGmYLQvn9XETzw7CMsT
24 lines
1.3 KiB
C#
24 lines
1.3 KiB
C#
using ZB.MOM.WW.OtOpcUa.Runtime.Drivers;
|
|
|
|
namespace ZB.MOM.WW.OtOpcUa.Runtime.Tests.Harness;
|
|
|
|
/// <summary>
|
|
/// Builds the ONE message shape a driver child sends for its values — a
|
|
/// <see cref="DriverInstanceActor.AttributeValueBatchPublished"/> — for tests that push a single value into the
|
|
/// dependency mux by hand. The per-value <see cref="DriverInstanceActor.AttributeValuePublished"/> has no
|
|
/// production sender (02/U4); tests should not keep one alive either.
|
|
/// </summary>
|
|
public static class ValuePublishes
|
|
{
|
|
/// <summary>A one-item batch for <paramref name="fullReference"/>.</summary>
|
|
/// <param name="driverInstanceId">The publishing driver's id.</param>
|
|
/// <param name="fullReference">The value's reference (RawPath).</param>
|
|
/// <param name="value">The value.</param>
|
|
/// <param name="statusCode">The full OPC UA status code.</param>
|
|
/// <param name="timestampUtc">The source timestamp.</param>
|
|
/// <returns>The batch message.</returns>
|
|
public static DriverInstanceActor.AttributeValueBatchPublished Single(
|
|
string driverInstanceId, string fullReference, object? value, uint statusCode, DateTime timestampUtc) =>
|
|
new(driverInstanceId, new[] { new DriverInstanceActor.AttributeValueItem(fullReference, value, statusCode, timestampUtc) });
|
|
}
|