eclipse / microprofile-telemetry

microprofile telemetry
Apache License 2.0
16 stars 16 forks source link

Split Application and Endpoint declarations #129

Closed radcortez closed 9 months ago

radcortez commented 9 months ago

To run the TCK properly with RESTEasy and Jetty, the Application and endpoints declaration must be separate.

I had a look into the specification and also on the TCK. I couldn't find any indication that such set up should work.

Azquelt commented 9 months ago

It looks like JaxRsServerAsyncTestEndpoint also has this problem.

Other tests have the Application class as a static inner class named RestApplication so we should use the same approach here.

I'll make these changes now because we're in the middle of staging the release so if we're getting this change in it needs to be done quickly.

radcortez commented 9 months ago

Thank you!

Unsure why this is a problem, we're also using resteasy within Liberty, but no objection to the changes.

The RESTEasy ServletInitializer (which I use to add to Jetty), only supports one type or the other: https://github.com/resteasy/Resteasy/blob/main/resteasy-servlet-initializer/src/main/java/org/jboss/resteasy/plugins/servlet/ResteasyServletInitializer.java#L39-L68

Maybe that could be changed to support both. I guess that if you use RESTEasy Deployer directly, you could set things manually, and it would work.