Java EE implicit features

The Java EE philosophy has always been to work out of the box. However, it may have some impact on the performance as, sometimes, features are activated without your application requiring them at all. If you know that you don't need a feature, don't hesitate to disable it.

For instance, in persistence.xml, we disabled bean validation integration adding this line:

<validation-mode>NONE</validation-mode>

This avoids the JPA provider adding the bean validation listeners it uses to validate the entities and, thus, saves some CPU cycles without impacting the application. If you check the chain of our application, we use JAX-RS (has a bean validation integration) and then JPA (has another bean validation integration). ...

Get Java EE 8 High Performance now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.