Java EE 8 High Performance
上QQ阅读APP看书,第一时间看更新

What this book covers

Chapter 1, Money – The Quote Manager Application, starts by explaining how to set up a basic environment to be able to follow the book's chapters. It also shows you how to develop a common Java EE 8 application, which you can use all along the chapters to easily test every topic.

Chapter 2, Looking Under the Cover – What is This EE Thing?, explains why we use a JavaEE 8 container and what it brings to the developers. It goes through some mainstream technologies, and shows the work done under the cover by the server and how it can impact the performance when not used the way it was designed to be.

Chapter 3, Monitor Your Application, targets the instrumentation of the application in several flavors. The high-level goal is to get the metrics of your application at every level and layer to ensure that you can clearly identify bottlenecks work on the performance of your application. It uses several techniques, more or less simple, and targets the different phases of work you can do on your application.

Chapter 4, Application Optimization – Memory Management and Server Configuration, targets the configuration you can use to optimize your application without modifying your code at all. It concentrates around JVM memory tuning, which can be very advanced with modern platforms, and Java EE server configuration, which can be worth having a look at.

Chapter 5, Scale Up – Threading and Implications, concentrates on the threading model that Java EE 8 offers. It starts by listing the thread pool you will work with, how you can define new thread pools specific to your application and integrating with the platform, and, finally, it opens the end of the chapter, talking about modern programming models in the Java EE 8 platform, which completely changes the way you use threads to be more reactive.

Chapter 6, Be Lazy; Cache Your Data, deals with the caching. It starts by explaining what caching is and how it is supposed to help you improve performance. Then, it explains how Java EE 8 helps you to rely on the cache at HTTP level and how it integrates with JCache specification to speed up your code drastically.

Chapter 7, Be Fault-Tolerant, helps you design and code distributed applications such as microservices to keep your performance under control and your application stable. The overall goal is to ensure that you don't get affected by services you rely on in a bad manner and that your service stays available irrespective of the state others are in. In other words, it helps you prevent a domino effect on your system if something goes wrong somewhere.

Chapter 8, Loggers and Performances – A Trade-Off, deals with loggers. This is surely the most common API used across all applications, but it can also viciously affect the performance, since a badly used or configured logger can be very significant to your performance figures. This chapter explains what a logging framework is and how to use it. It will help you avoid all these pitfalls.

Chapter 9, Benchmarking Your Application, is about dedicated benchmark projects or phases of your project. It explains which tools to use, what steps to go through so as to ensure your benchmark is useful, and how to get the most out of a benchmark.

Chapter 10, Continuous Performance Evaluation, goes through several solutions to make sure that you can evaluate the performance of your system in a continuous way. It aims to ensure you can get performance figures out of your system at each and every development stage and, used at the extreme, you can even get it for each pull request done on your project. This chapter goes through some tools and solutions, and explains how to enrich some existing frameworks with some glue code to go further and not stay blocked on the topic that is not yet that common but very important for applications with a defined SLA.