[ 
https://issues.apache.org/jira/browse/TOMEE-4728?focusedWorklogId=1046206&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-1046206
 ]

ASF GitHub Bot logged work on TOMEE-4728:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 07/Oct/26 15:37
            Start Date: 07/Oct/26 15:37
    Worklog Time Spent: 10m 
      Work Description: rzo1 merged PR #3064:
URL: https://github.com/apache/tomee/pull/3064




Issue Time Tracking
-------------------

    Worklog Id:     (was: 1046206)
    Time Spent: 20m  (was: 10m)

> MicroProfile Health endpoint runs the providers of a declared JAX-RS 
> application
> --------------------------------------------------------------------------------
>
>                 Key: TOMEE-4728
>                 URL: https://issues.apache.org/jira/browse/TOMEE-4728
>             Project: TomEE
>          Issue Type: Bug
>            Reporter: Markus Jung
>            Assignee: Markus Jung
>            Priority: Major
>             Fix For: 11.0.0
>
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> Since TOMEE-4716, {{RESTService}} deploys the MicroProfile Health endpoint 
> ({{MicroProfileHealthChecksEndpoint}}) in its own {{InternalApplication}} at 
> the context root when the webapp declares JAX-RS applications, but none at 
> the context root.
> That application is deployed with {{additionalProviders}}, the collection 
> that the loop over the declared applications fills with the providers each 
> one lists in {{getClasses()}} / {{getSingletons()}}. So a provider meant for 
> one application, e.g. an unbound {{@PreMatching}} {{ContainerRequestFilter}} 
> of an application at {{/api}}, also runs for {{/health}}, {{/health/live}}, 
> {{/health/ready}} and {{/health/started}}.
> With a filter that aborts every request it doesn't recognize, all health 
> endpoints answer with that filter's response instead of the health checks. 
> Seen with an MCP server application whose pre-matching filter answers {{503}} 
> with an empty body outside its own application: every {{/health}} request 
> returns {{503}}, and the endpoint method never runs.
> Fix: deploy the container application with only the webapp-wide providers, 
> those collected before the declared applications add their own.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to