@@ -268,10 +268,9 @@ instance LogFormatting (TracePeerSelection SockAddr) where
268268 , " actualEstablished" .= actualKnown
269269 , " selectedPeers" .= toJSONList (toList sp)
270270 ]
271- forMachine _dtal (TracePromoteColdLocalPeers tLocalEst aLocalEst sp) =
271+ forMachine _dtal (TracePromoteColdLocalPeers tLocalEst sp) =
272272 mconcat [ " kind" .= String " PromoteColdLocalPeers"
273273 , " targetLocalEstablished" .= tLocalEst
274- , " actualLocalEstablished" .= aLocalEst
275274 , " selectedPeers" .= toJSONList (toList sp)
276275 ]
277276 forMachine _dtal (TracePromoteColdFailed tEst aEst p d err) =
@@ -379,6 +378,10 @@ instance LogFormatting (TracePeerSelection SockAddr) where
379378 forMachine _dtal (TraceChurnMode c) =
380379 mconcat [ " kind" .= String " ChurnMode"
381380 , " event" .= show c ]
381+ forMachine _dtal (TraceKnownInboundConnection addr sharing) =
382+ mconcat [ " kind" .= String " KnownInboundConnection"
383+ , " peer" .= toJSON addr
384+ , " peerSharing" .= String (pack . show $ sharing) ]
382385 forHuman = pack . show
383386
384387instance MetaTrace (TracePeerSelection SockAddr ) where
@@ -442,6 +445,8 @@ instance MetaTrace (TracePeerSelection SockAddr) where
442445 Namespace [] [" ChurnWait" ]
443446 namespaceFor TraceChurnMode {} =
444447 Namespace [] [" ChurnMode" ]
448+ namespaceFor TraceKnownInboundConnection {} =
449+ Namespace [] [" KnownInboundConnection" ]
445450
446451 severityFor (Namespace [] [" LocalRootPeersChanged" ]) _ = Just Notice
447452 severityFor (Namespace [] [" TargetsChanged" ]) _ = Just Notice
@@ -472,6 +477,7 @@ instance MetaTrace (TracePeerSelection SockAddr) where
472477 severityFor (Namespace [] [" GovernorWakeup" ]) _ = Just Info
473478 severityFor (Namespace [] [" ChurnWait" ]) _ = Just Info
474479 severityFor (Namespace [] [" ChurnMode" ]) _ = Just Info
480+ severityFor (Namespace [] [" KnownInboundConnection" ]) _ = Just Info
475481 severityFor _ _ = Nothing
476482
477483 documentFor (Namespace [] [" LocalRootPeersChanged" ]) = Just " "
@@ -524,6 +530,8 @@ instance MetaTrace (TracePeerSelection SockAddr) where
524530 documentFor (Namespace [] [" GovernorWakeup" ]) = Just " "
525531 documentFor (Namespace [] [" ChurnWait" ]) = Just " "
526532 documentFor (Namespace [] [" ChurnMode" ]) = Just " "
533+ documentFor (Namespace [] [" KnownInboundConnection" ]) = Just
534+ " An inbound connection was added to known set of outbound governor"
527535 documentFor _ = Nothing
528536
529537 allNamespaces = [
@@ -556,6 +564,7 @@ instance MetaTrace (TracePeerSelection SockAddr) where
556564 , Namespace [] [" GovernorWakeup" ]
557565 , Namespace [] [" ChurnWait" ]
558566 , Namespace [] [" ChurnMode" ]
567+ , Namespace [] [" KnownInboundConnection" ]
559568 ]
560569
561570--------------------------------------------------------------------------------
0 commit comments