With AppDynamics 3.2, we recently announced support for Big Data. This essentially allows our customers to manage application performance in production applications while aligning with the growing trend of NoSQL technologies. As applications become more distributed and complex, many organizations are looking to exploit the benefits of Cassandra, Hadoop and MongoDB (to name a few), which offer more agile data models along with superior read/write performance. They are also significantly cheaper to own and scale compared to the traditional relational database.
But as I mentioned in my previous blog, NoSQL is about “Not Just SQL” rather than waving goodbye to the relational database. So as a vendor that provides innovative APM solutions, it was a logical step for AppDynamics to provide support for NoSQL technologies at the first knock for our customers so they could monitor the performance of both their relational and non-relational databases.
This blog takes a look at the new capabilities AppDynamics Pro provides for monitoring Cassandra, a highly scalable, second-generation distributed database that has received modest adoption over the last 18 months. This adoption has been helped significantly through the publicity generated by heavyweight Cassandra users such as Facebook and Twitter. It isn’t just hype, though; at AppDynamics we’re seeing more and more of this stuff in our customers environments and they love it.
For those not familiar with Cassandra, here’s a quick comparison of how it differs from the traditional relational database just so you understand what exactly is being reported by AppDynamics:
With AppDynamics Pro 3.2, we’re essentially letting our users understand business transaction latency of Cassandra (Thrift) queries along with how those queries are serviced by the Cassandra Cluster itself. Think of it as similar visibility to what we currently provide for JDBC queries and relational databases. Here’s a quick glimpse of what you can expect with AppDynamics Pro 3.2 when monitoring your Cassandra based applications:
Auto-Discovery and Mapping of Cassandra KeySpaces
AppDynamics Pro will automatically discover and map Cassandra KeySpaces to your application and business transaction flows. This gives you a real-time visualization of what your application and your business transactions look like when they interact with Cassandra KeySpaces. With this unique visibility (as shown below), you can also identify latency over the Thrift protocol between your application servers and Cassandra KeySpaces as well as the response times from each individual Cassandra KeySpace.
Understand latency of how Business Transactions are serviced by Cassandra
Troubleshooting Business Transaction Latency
A unique part of AppDynamics Pro is the ability to troubleshoot performance issues both from a business transaction and infrastructure perspective. If a business transaction is slow, the user can see how this business transaction executes through each JVM/CLR with complete call stacks showing the exit calls to Cassandra KeySpaces. The screenshot below shows a call stack of a business transaction that took 321 milliseconds to execute. You can see that 54ms (15.8%) of the response time is spent calling Cassandra, and 164ms (51%) is spent formatting the results returned.
Understand Business Transaction Call Stack Latency within Application Server JVM/CLR
Visibility of Cassandra Queries
It’s good to know how much time is spent in each Cassandra KeySpace. However, it’s even better to know the actual queries that were submitted by your business transactions so you get a deep understanding of what exactly was invoked. For example, clicking on the Thrift external call link in the above screenshot reveals the actual Cassandra Query executed by the business transaction:
Gain Visibility into the latency of your Cassandra Queries
This is excellent visibility for understanding which key and column family was queried, along with its range count and consistency level. As you can see, AppDynamics shows the actual latency of the query and associated calling method. By clicking on the link “Drill into Call,” the user can now drill in context to the actual Cassandra Cluster and understand where the latency (54ms) is spent in Cassandra. The screenshot below shows this call stack so the user can gain a deeper insight into how Cassandra is servicing the business transaction and associated query.
Understand Call Stack Latency within Cassandra JVM
Cassandra OS Metrics
After analyzing call stack latency, the user can access OS metrics by clicking on the Hardware/JVM/CLR tab on the left hand side menu. This provides visibility into CPU, memory and disk I/O utilization at the time the slow business transaction was executing–allowing the user to understand whether Cassandra latency was caused by server resource contention.
Understand OS resource activity of Cassandra Cluster
The user can toggle to the memory tab and understand the Cassandra JVM heap activity along with GC cycles. Again, doing so allows the user to see which resource was potentially contributing to the latency of queries.
Understand memory usage and activity of Cassandra JVM
Cassandra JMX Metric Trending
As well as Cassandra OS metrics, the user can trend and correlate JMX metrics from the related Cassandra Cluster at the time when the business transaction was executing. This visibility and trending helps the user understand what state the OS and Cassandra Cluster was in along with key events and pending tasks that occurred (e.g. compaction). Thread Pool Utilization and Column Family activity can also be monitored so the user can troubleshoot what was impacting query performance. For example, the below screenshot show the number of CompletedTasks (green) versus the number of PendingTasks (red) so the user can rapidly understand if tasks are being queued in Cassandra.
Correlate and Trend Cassandra JMX Metrics over-time
In summary, AppDynamics Pro 3.2 allows you to gain visibility into how your application and its business transactions are being serviced by your application server and Cassandra JVMs. It provides granular call stack visibility into the latency of Cassandra queries and how they execute. It also allows you to trend and correlate OS and JMX metrics to understand the state of your Cassandra Clusters, so that when slowdowns occur you can identify root cause in minutes. And it does all this out of the box so you don’t need to worry about configuration or overhead.
If you’re interested in getting visibility of how your application and business transaction performance is impacted by Cassandra, you can request a trial of AppDynamics Pro. If you’re super keen and want to get your feet wet straight away you can download our free product AppDynamics Lite.