-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RESTEasy Classic - annotation on abstract jakarta.ws.rs.core.Application class is not ignored #42963
Comments
I don't think it has anything to do with Quarkus. I also am not sure it's a bug. You would have to check the spec and if it had to be changed, I would expect the change to be in RESTEasy itself? |
@geoand did https://github.com/quarkusio/quarkus/pull/41465/files to ignore abstract jakarta.ws.rs.core.Application classes. So that's why I assume annotation on such abstract classes should not make any impact to the app. Quarkus REST ignores @jamezp what's your view on this? |
The annotation is not set as |
Same for Quarkus |
Cool, kind of what I assumed :) So it's likely somewhere in Quarkus it needs to be fixed then. |
Okay, no I see what the problem is. @jamezp just to clarify, on WildFly if a class like package org.acme;
import jakarta.ws.rs.ApplicationPath;
import jakarta.ws.rs.core.Application;
@ApplicationPath("/rest")
public abstract class AbstractApplication extends Application {
} exists, then |
#44195 is what I have in mind |
@geoand Correct. Any abstract classes are simply ignored. TBH I can't think of a use-case for an abstract application class though. |
Properly handle `@ApplicationPath` and `Application` in RESTEasy Classic
Describe the bug
RESTEasy Classic - annotation on abstract jakarta.ws.rs.core.Application class is not ignored
#41465 should ensure abstract jakarta.ws.rs.core.Application classes are ignored
But it's not the case when I put
@ApplicationPath
on it. Path gets unfortunately reflected.E.g. endpoint is available on http://localhost:8080/rest/hello instead of http://localhost:8080/hello.
Expected behavior
Annotation on abstract jakarta.ws.rs.core.Application class is ignored
Actual behavior
annotation on abstract jakarta.ws.rs.core.Application class is NOT ignored
How to Reproduce?
mvn clear verify
mvn quarkus:dev
and access http://localhost:8080/rest/hello and http://localhost:8080/helloOutput of
uname -a
orver
macOS
Output of
java -version
Java 21
Quarkus version or git rev
Quarkus 3.14.1
Build tool (ie. output of
mvnw --version
orgradlew --version
)No response
Additional information
No response
The text was updated successfully, but these errors were encountered: