JAX-RS Done Right! (IX. – Default Entity Providers)

Hey guys! How’s it going?

Separating domain logic of the http body handling from technical aspects is easy in JAX-RS thanks to Entity Providers.

In today’s episode of “JAX-RS Done Right!” we introduce Separation of Concerns to only have pure domain code in our application when it comes to handling http bodies, while every technical aspect is in separated code. The key for this are Entity Providers (i. e. Renderers and Parsers for a combination of Java Class and Media Type). There even are Default Entity Providers built into JAX-RS, so it is easy to get started with that.

In a future episode, we will extend the concept by intoducing our own Custom Entity Providers.

Code example can be found on Gitlab: https://gitlab.com/mkarg/jaxrs-done-right

Stay safe and… Party on!

About Markus Karg

Java Guru with +30 years of experience in professional software development. I travelled the whole world of IT, starting from Sinclair's great ZX Spectrum 48K, Commodore's 4040, over S/370, PCs since legendary XT, CP/M, VM/ESA, DOS, Windows (remember 3.1?), OS/2 WARP, Linux to Android and iOS... and still coding is my passion, and Java is my favourite drug!
Video | This entry was posted in Jakarta EE, Java, Programming, Standards and tagged , , , , , , , , , , , . Bookmark the permalink.