The development of complex interactive web applications inherently requires you to store state in one location or another (on the server, on the client, in a database, …). Using JSF, the web session preserves the state of the container managed beans by taking your scope rules into account. Since this is conveniently tied to regular Java classes and their fields, it’s very easy to accidentally grow the session without really realizing just how large the memory footprint has become.
Product Updates, Company News & Fun
Spring is one of the most popular Java web frameworks in existence, it provides amazing benefit in providing a reliable, tested framework for developing web applications in Java. Developers don’t have to reinvent the wheel when it comes to well understood problems like serving content over HTTP and wiring up a model-view-controller (MVC) layout for their application.
Spring’s core functionality is to provide an Inversion of Control (IoC) platform for Dependency Injection (DI). There are many benefits of loosely coupling components through DI, however application initialization takes longer than if everything were tightly coupled in code without a DI platform. Creating and modifying Spring beans is a normal, everyday activity for Java developers utilizing Spring in their applications.
While the infamous N+1 SELECTs problem is increasingly associated with ORM tools, it can still happen in your app even if you avoid ORM like the plague. Spring JDBC Template is a popular way to use Plain Old SQL in Java in a way that provides some abstraction over SQL parameters, looping over rows and mapping to DTOs.
According to a recent report, Spring MVC is used by 40% of Java developers out there, making it one of the most popular Java web frameworks in existence. Fair enough, it provides amazing benefits in providing a reliable, time-tested framework for developing web applications in Java. Developers don’t have to reinvent the wheel when it comes to well-understood problems, like serving content over HTTP and wiring up a model-view-controller (MVC) layout for their application.
In the previous article we’ve uncovered a typical Hibernate issue – as Hibernate hides a lot of relational database complexity from us, it is easy to accidentally pull too much data through too many queries from the database. We used XRebel to identify that issue in Spring Petclinic, but haven’t figured out how to fix it yet…
ICON Health & Fitness frequently reviews tools to help their developers both be more productive and write better code. They chose to use XRebel to assist with the performance profiling of their applications, from the session to the database and to help them find exceptions and/or errors in their code. XRebel was designed to help developers fix issues like:
- Session Issues: bloat and leaks
- Database: Rogue SQL, track offending methods, inefficient queries, naive ORM configurations
- Hidden exceptions
With these benefits in mind, ICON set off to see how XRebel could give them better insight into their apps, and how to discover and squash bugs in production while still writing code.