rzo1 commented on PR #2960:
URL: https://github.com/apache/tomee/pull/2960#issuecomment-5876460949
@jungm I pushed cc6f875538 with two more cases for `HealthEndpointTest`:
- `multipleApplications` (two applications at `/api` and `/other`): passes
- `applicationAtTheContextRoot` (`@ApplicationPath("/")`, listing its
classes): **fails**, `/test/hello` answers 200 but `/test/health` is a 404
So the additional container application at `/*` collides with a user
application, which is mapped to the context root as well.
`RESTService#afterApplicationCreated` always deploys it with the prefix `"/" +
wildcard`, which is the same address as the one of the user application.
An idea would be to add the `containerRestClass` classes to the user
application, if it is mapped to the context root, instead of deploying a second
application. Can you have a look?
Two more things I noticed, but did not verify:
- The new block is guarded by `deploymentWithApplication`, so with the old
deployment (pojo configuration for a listed class or
`openejb.jaxrs.application=false`) and an application listing its classes, the
health endpoint might still be missing.
- For an application listing nothing, the endpoint moves from
`<context>/<application path>/health` to `<context>/health`. This is intended
as far as I understand, but it is worth a note in the release notes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]