Course Image

Advanced JAX-RS

Java EE

This course covers more advanced concepts of JAX-RS. You will learn some important concepts related to resource life cycle, authentication and client APIs. You will also implement framework extensions like converters, message readers and writers.

Start Course

This course covers:

  • Bootstrapping JAX-RS applications with Application class
  • Understanding resource life cycles
  • Implementing ParamConverters, MessageBodyReaders and MessageBodyWriters
  • Building a REST API client in Java using JAX-RS
  • Implementing REST API Authentication



The Application Class

Learn how to setup a JAX-RS application in an environment-agnostic way using the Application class. Deploy a REST API web application on Tomcat without a servlet.xml.

Introduction 1 minute
Tomcat Setup 2 minutes
Setting up pom.xml 6 minutes
Setting up a JAX RS application 5 minutes
The Application Class 4 minutes
Review 4 questions



JAX-RS Extensions

JAX-RS provides several ways to extend and customize the framework when building a REST application. You can create your own custom converters to handle data type conversions, as well as create custom readers and writers to work with the message body content.

Resource Life Cycle 5 minutes
Param Annotations and Member Variables 7 minutes
ParamConverters 10 minutes
Implementing Custom ParamConverters 7 minutes
ParamConverters Review 5 questions
MessageBodyReaders and MessageBodyWriters 6 minutes
Implementing a MessageBodyWriter 10 minutes
Custom Media Types 6 minutes
Unit Review 3 questions



REST API Authentication

Learn how to implement authentication in your REST APIs. Learn how to create filters in JAX-RS and implement an Authentication filter that does Basic Auth.

Unit Introduction 51 seconds
Implementing Filters 10 minutes
REST API Authentication Mechanisms 15 minutes
Sending Basic Auth Requests 3 minutes
Implementing REST API Authorization 12 minutes
Unit Review 5 questions



Wrapping Up

Let's wrap up the course with a few miscellaneous topics - some more details on Filters and interceptors and understanding how JAX-RS works with EJBs.

Filters And Interceptors 8 minutes
JAX-RS and EJBs 3 minutes
Conclusion 3 minutes


Project source code

.zip file