• /
  • Log in

disable_browser_autorum (Python agent API)

Syntax

newrelic.agent.disable_browser_autorum(flag=True)

Disables Browser monitoring for a web request.

Description

This call disables browser monitoring for the page/request it is called for. This call only affects the current web request and must be called prior to the point where the browser agent header/footer JavaScript are injected. For more on how the browser agent JavaScript is inserted, see Install browser monitoring.

Tip

You can also disable browser injection by setting the newrelic.disable_browser_autorum key for the specific request in the WSGI environ dictionary passed by the WSGI server into the WSGI application being monitored.

Parameters

Parameter

Description

flag

boolean

Optional. Default is True. Set to False to instead allow browser agent injection.

Return values

None.

Examples

Disabling browser monitoring

In this example, you've upgraded the agent and you've noticed the N JavaScript that's automatically injected onto the HTML page is also being injected into every iFrame that is loaded on those pages. This has caused your pageviews to increase substantially.

On those specific iFrame views, you would make this call:

newrelic.agent.disable_browser_autorum()

For more help

If you need more help, check out these support and learning resources:

Create issueEdit page
Copyright © 2021 New Relic Inc.