O'Reilly logo

Hands-On High Performance with Spring 5 by Dinesh Radadiya, Prashant Goswami, Pritesh Shah, Subhash Shah, Chintan Mehta

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Undertow as an embedded server

Spring Boot provides embedded servers that can run web applications in a JAR file. A few of the available embedded servers for use are Tomcat, Undertow, Webflux, and Jetty. It is advisable to have Undertow as the embedded server. Undertow provides more throughput and consumes less memory compared to Tomcat and Jetty. The following comparisons may provide some insight:

  • Throughput comparison:

 Server

Samples

Error % 

Throughput 

Tomcat

3000

       0

293.86

Jetty

3000

0

291.52

Undertow

3000

0

295.68

  • Heap memory comparison:

 Server

Heap size

Used

Max

Tomcat

665.5 MB

118.50 MB

2 GB

Jetty

599.5 MB

297 MB

2 GB

Undertow

602 MB

109 ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required