From 541aca9f442837d2bea38705c6d85406fe032aa4 Mon Sep 17 00:00:00 2001 From: Ahmad Shahwan Date: Tue, 21 May 2024 11:15:55 +0200 Subject: [PATCH] Expose REST resource via config This solves #16695. --- .../baeldung/boot/jersey/JerseyResourceConfig.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 spring-boot-modules/spring-boot-mvc-jersey/spring-boot-jersey/src/main/java/com/baeldung/boot/jersey/JerseyResourceConfig.java diff --git a/spring-boot-modules/spring-boot-mvc-jersey/spring-boot-jersey/src/main/java/com/baeldung/boot/jersey/JerseyResourceConfig.java b/spring-boot-modules/spring-boot-mvc-jersey/spring-boot-jersey/src/main/java/com/baeldung/boot/jersey/JerseyResourceConfig.java new file mode 100644 index 000000000000..2b8a60c7d88f --- /dev/null +++ b/spring-boot-modules/spring-boot-mvc-jersey/spring-boot-jersey/src/main/java/com/baeldung/boot/jersey/JerseyResourceConfig.java @@ -0,0 +1,13 @@ +package com.baeldung.boot.jersey; + +import com.baeldung.boot.jersey.controllers.HelloController; +import org.glassfish.jersey.server.ResourceConfig; +import org.springframework.stereotype.Component; + +@Component +public class JerseyResourceConfig extends ResourceConfig { + + public JerseyResourceConfig() { + super(HelloController.class); + } +}