Skip to content

Commit e1b8eca

Browse files
authored
feat: Add additional logging when RUM injection is being skipped. (#1561)
1 parent 5f749e9 commit e1b8eca

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/Agent/NewRelic/Agent/Core/BrowserMonitoring/BrowserMonitoringScriptMaker.cs

+8-1
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,17 @@ public BrowserMonitoringScriptMaker(IConfigurationService configurationService,
4444
public string GetScript(IInternalTransaction transaction, string nonce)
4545
{
4646
if (string.IsNullOrEmpty(_configurationService.Configuration.BrowserMonitoringJavaScriptAgent))
47+
{
48+
Log.Debug("Skipping RUM injection because \"js_agent_loader\" config is missing or empty");
4749
return null;
50+
}
4851

49-
if (_configurationService.Configuration.BrowserMonitoringJavaScriptAgentLoaderType.Equals("none", StringComparison.InvariantCultureIgnoreCase))
52+
if (_configurationService.Configuration.BrowserMonitoringJavaScriptAgentLoaderType.Equals("none",
53+
StringComparison.InvariantCultureIgnoreCase))
54+
{
55+
Log.Debug("Skipping RUM injection because \"browser_monitoring.loader\" config is \"none\"");
5056
return null;
57+
}
5158

5259
if (transaction.Ignored)
5360
{

0 commit comments

Comments
 (0)