0

I got loads of pages explaining the springboot actuator configuration in older versions but none of which seems to work with springboot2.7.9 and Jersey setup. PLease find below actuator endpoints setup for application on jersey rest and spring boot 2.7.9. Java Version: 11 Springboot version: 2.7.9 Jersey version: 2.35 Actuator:2.7.9

Dependency in POM.xml

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-actuator</artifactId>
        </dependency>

application.properties

management.endpoints.web.exposure.include="*"
spring.jersey.type=filter

Spring-Boot Jersey: allow Jersey to serve static content will explain which we need spring.jersey.type=filter properties

property(ServletProperties.FILTER_FORWARD_ON_404, true); must also be set up in your Jersey configuration class which extends ResourceConfig

Arjun NAS
  • 1
  • 2
  • As that link explains, there's more to it than just add the `spring.jersey.type` property. Did you do that also? – Paul Samsotha May 03 '23 at 13:38
  • No, I only added the property and the dependency, and that got it working for the Jersey application. I created this post for the same reason. To keep it simple. Please let me know if you facing any issues. I can see if I can help – Arjun NAS May 03 '23 at 21:48
  • The post also says you need to set a property for forward requests. – Paul Samsotha May 04 '23 at 22:16
  • Yes, I had it by default earlier. Check after adding and removing it. you are right. I have updated my answer. Thank you. – Arjun NAS May 12 '23 at 08:50

0 Answers0