chapter eight

8 Using advanced visualization tools for profiled data

 

This chapter covers

  • Detecting problems with connections to relational databases
  • Using call graphs to understand an app’s design faster
  • Using flame graphs to visualize an app’s execution easier
  • Analyzing queries an app sends to a NoSQL database server

In this chapter, we’ll discuss valuable techniques that can make your life easier when you investigate specific scenarios. We’ll start the chapter, in section 8.1, by examining an approach to identify connection problems between a Java app and a relational database server. We already discussed profiling SQL queries in chapter 7, but sometimes problems appear when an app establishes the communication with a database management system (DBMS). And such situations can even lead to an app not responding at all, which makes finding causes of such problems in real-world apps essential.

In section 8.2, I’ll show you one of my favorite ways to understand the code behind a given execution scenario – a simple approach using call graphs. Call graphs are visual representations of the dependencies between an app’s objects. I found call graphs helpful, especially when dealing with messy code I’ve never seen before. And since I’m sure most developers have to deal at some point in their careers with messy codebases, I consider knowing this approach will potentially save you plenty of time at some point.

8.1 Detecting problems with JDBC connections

8.2 Understanding the app’s code design using call graphs

8.3 Using flame graphs to easier spot performance problems

8.4 Analyzing queries on NoSQL databases

8.5 Summary