Useful Insights Queries for before and after Release Deployment

Feel free to share your useful insights queries here that you think is useful for diagnosing any new errors and application performance after Release deployment:

I will share mine too after I figure it out.


Excellent idea, @icardenas! I bet @stefan_garnham has some successful queries to share! More fodder for our NRQL library!

Hi, @icardenas: If you are using New Relic APM’s deployments feature, it automatically generates a dashboard for each deployment showing response time vs. throughput, Apdex, CPU, memory, and database usage before and after the deploy, as well as a change report that shows the Apdex, response time, or throughput of each transaction before and after the deploy.

You may be able to re-create some of these charts in Insights. For example, this query displays Apdex per transaction (replace 0.4 in the apdex function with your application’s actual Apdex threshold):

SELECT apdex(duration, 0.4) FROM Transaction 
WHERE appName = 'New Relic Pet Clinic' 
SINCE '2017-12-04 21:55:00 PST' UNTIL '2017-12-04 22:45:00 PST' 

Unfortunately, because Insights cannot yet display event markers on charts, it’s difficult to know when the actual deployment occurred. Another option is to simply display key performance metrics, and you select the time window based on when you know you did a deploy:

Finally, if you pass a custom version or build attribute from each transaction, you can say, “Show me the average response time (or Apdex, or whatever) for Build X vs. Build Y”:

P.S. — Do you notice the new feature in the above query?


Thanks @philweber !

Is the new feature facet’ing multiple attributes? (just answer yes or no)

1 Like


1 Like

Awesome! That is so cool.

I’ve created a dashboard.

Is there anything else you can add here?

1 Like

@philweber is there a way to query a unique errormessage that hasn’t occurred the days after a deployment?

You can get the number of occurrences an error message like this:

SELECT count(*) FROM TransactionError 
WHERE `error.message` LIKE 'Your message here'

But I don’t know of any way to query for something that hasn’t occurred. Maybe someone else will have a suggestion.

1 Like

I spotted the multiple facet as well :grinning:


@stefan_garnham Multi-attribute FACETs are now supported :grinning: :thumbsup: