@@ -379,6 +379,10 @@ instance LogFormatting (TracePeerSelection SockAddr) where
379379 forMachine _dtal (TraceChurnMode c) =
380380 mconcat [ " kind" .= String " ChurnMode"
381381 , " event" .= show c ]
382+ forMachine _dtal (TraceKnownInboundConnection addr sharing) =
383+ mconcat [ " kind" .= String " KnownInboundConnection"
384+ , " peer" .= toJSON addr
385+ , " peerSharing" .= String (pack . show $ sharing) ]
382386 forHuman = pack . show
383387
384388instance MetaTrace (TracePeerSelection SockAddr ) where
@@ -442,6 +446,8 @@ instance MetaTrace (TracePeerSelection SockAddr) where
442446 Namespace [] [" ChurnWait" ]
443447 namespaceFor TraceChurnMode {} =
444448 Namespace [] [" ChurnMode" ]
449+ namespaceFor TraceKnownInboundConnection {} =
450+ Namespace [] [" KnownInboundConnection" ]
445451
446452 severityFor (Namespace [] [" LocalRootPeersChanged" ]) _ = Just Notice
447453 severityFor (Namespace [] [" TargetsChanged" ]) _ = Just Notice
@@ -472,6 +478,7 @@ instance MetaTrace (TracePeerSelection SockAddr) where
472478 severityFor (Namespace [] [" GovernorWakeup" ]) _ = Just Info
473479 severityFor (Namespace [] [" ChurnWait" ]) _ = Just Info
474480 severityFor (Namespace [] [" ChurnMode" ]) _ = Just Info
481+ severityFor (Namespace [] [" KnownInboundConnection" ]) _ = Just Info
475482 severityFor _ _ = Nothing
476483
477484 documentFor (Namespace [] [" LocalRootPeersChanged" ]) = Just " "
@@ -524,6 +531,8 @@ instance MetaTrace (TracePeerSelection SockAddr) where
524531 documentFor (Namespace [] [" GovernorWakeup" ]) = Just " "
525532 documentFor (Namespace [] [" ChurnWait" ]) = Just " "
526533 documentFor (Namespace [] [" ChurnMode" ]) = Just " "
534+ documentFor (Namespace [] [" KnownInboundConnection" ]) = Just
535+ " An inbound connection was added to known set of outbound governor"
527536 documentFor _ = Nothing
528537
529538 allNamespaces = [
@@ -556,6 +565,7 @@ instance MetaTrace (TracePeerSelection SockAddr) where
556565 , Namespace [] [" GovernorWakeup" ]
557566 , Namespace [] [" ChurnWait" ]
558567 , Namespace [] [" ChurnMode" ]
568+ , Namespace [] [" KnownInboundConnection" ]
559569 ]
560570
561571--------------------------------------------------------------------------------
0 commit comments