Skip to content

Commit 0ff3ddd

Browse files
authored
feat: Move TLS config logging closer to connect. (#1562)
1 parent e1b8eca commit 0ff3ddd

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/Agent/NewRelic/Agent/Core/DataTransport/ConnectionHandler.cs

+6
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ public void Connect()
7474
try
7575
{
7676
ValidateNotBothHsmAndSecurityPolicies(_configuration);
77+
LogTlsConfiguration();
7778

7879
var preconnectResult = SendPreconnectRequest();
7980
_connectionInfo = new ConnectionInfo(_configuration, preconnectResult.RedirectHost);
@@ -112,6 +113,11 @@ public void Connect()
112113
}
113114
}
114115

116+
private void LogTlsConfiguration()
117+
{
118+
Log.Info($"Current TLS Configuration (System.Net.ServicePointManager.SecurityProtocol): {System.Net.ServicePointManager.SecurityProtocol}");
119+
}
120+
115121
private void GenerateSpanEventsHarvestLimitMetrics(SingleEventHarvestConfig spanEventHarvestConfig)
116122
{
117123
if (spanEventHarvestConfig != null)

src/Agent/NewRelic/Agent/Core/NewRelic.Agent.Core/AgentManager.cs

-6
Original file line numberDiff line numberDiff line change
@@ -184,12 +184,6 @@ private void Initialize()
184184

185185
StartServices();
186186
LogInitialized();
187-
LogTlsConfiguration();
188-
}
189-
190-
private void LogTlsConfiguration()
191-
{
192-
Log.Info($"TLS Configuration (System.Net.ServicePointManager.SecurityProtocol): {System.Net.ServicePointManager.SecurityProtocol}");
193187
}
194188

195189
private void LogInitialized()

0 commit comments

Comments
 (0)