fix(grpc-data): A1 review S2 — only a retired child's Bad edge withdraws known; a stray sender changes nothing

This commit is contained in:
Joseph Doherty
2026-11-24 10:47:49 -05:00
parent 2fdf9d87c2
commit 795ad6ccc7
@@ -88,8 +88,10 @@ public sealed partial class DriverHostActor
{
if (!IsCurrentChild(driverInstanceId, sender))
{
// A stopped incarnation (or a stray sender): never recreate or reset the tracker. Its Bad edge still
// withdraws known unless the CURRENT child of the same id is connected (its state is the live one).
// A stopped incarnation (or a stray sender): never recreate or reset the tracker. A stopped incarnation's
// Bad edge still withdraws known unless the CURRENT child of the same id is connected (its state is the
// live one); a sender that was never a child of this host changes nothing.
if (!_retiredChildren.Contains(sender)) return;
var currentConnected = _conditionSignalTrackers.TryGetValue(driverInstanceId, out var live) && live.GoodSinceUtc is not null
&& _children.TryGetValue(driverInstanceId, out var current) && Equals(live.Owner, current.Actor);
if (!connected && !currentConnected) WithdrawDriverConditionsKnown(driverInstanceId);