Using Newrelic to monitor Java applications on Tomcat7

Asked

Viewed 202 times

1

As well as monitoring PHP and Django, I would like to monitor the "Browser page load time" of applications .

I installed the "Java agent self-installer" as described in the New Relic documents. It’s all right, I’m monitoring several of JVM, monitoring access to DB and all that.

The problem is that the "Browser page load time" as in the case of PHP and Python/Django..

Because?

1 answer

2

I don’t know if this is exactly the case with your application, but some browsers don’t send the information that Newrelic uses to build this graph.

The link below has code snippets to send the information:

https://docs.newrelic.com/docs/features/how-does-real-user-monitoring-work#rum-for-browsers-without-the-navigation-timing-api

Some Javascript scripts should be added to the header:

<script type="text/javascript">
   var NREUMQ=[];NREUMQ.push(["mark","firstbyte",new Date().getTime()]);
</script>

...and at the bottom:

<script type="text/javascript">
 if (!NREUMQ.f) NREUMQ.f=function() {
   NREUMQ.push(["load",new Date().getTime()]);
   var e=document.createElement("script");
   e.type="text/javascript";e.src="https://d7p9czrvs14ne.cloudfront.net/11/eum/rum.js";
   document.body.appendChild(e);
   if(NREUMQ.a)NREUMQ.a();
 };
 if(window.onload!==NREUMQ.f){NREUMQ.a=window.onload;window.onload=NREUMQ.f;};
 NREUMQ.push(["nrf2","beacon-1.newrelic.com","api-key",appID,"cV5eEkBfCF1WRBgECFZEQwNAbwVBQ1peAgdGWF8IQR8LR1ZEQQgDRQ==",6,707, new Date().getTime()]);
</script>

Browser other questions tagged

You are not signed in. Login or sign up in order to post.