Skip to content
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

javax.ws.rs.core.Application Marked for Removal, but required #1914

Closed
dansiviter opened this issue Apr 8, 2019 · 6 comments
Closed

javax.ws.rs.core.Application Marked for Removal, but required #1914

dansiviter opened this issue Apr 8, 2019 · 6 comments
Labels
area/arc Issue related to ARC (dependency injection) area/resteasy-classic kind/bug Something isn't working triage/duplicate This issue or pull request already exists

Comments

@dansiviter
Copy link

  • Version: 0.13.0
  • Extensions: resteasy, smallrye-jwt

It appears Application instances are removed although they have useful contents. E.g. if wanting to use Microprofile @LoginConfig annotation:

@ApplicationPath("/")
@LoginConfig(authMethod = "MP-JWT", realmName = "jwt-jaspi")
@ApplicationScoped
public class MyApplication extends Application { }

Is marked for removal:

2019-04-08 13:59:47,175 WARN  [io.qua.arc.run.ArcDeploymentTemplate] (main) Bean matching class acme.MyApplication was marked as unused and removed during build.
Extensions can eliminate false positives using:
	- a custom UnremovableBeanBuildItem
	- AdditionalBeanBuildItem(false, beanClazz)

Is seems the only way to do this is by using quarkus.smalllrye-jwt.auth-mechanism and quarkus.smalllrye-jwt.realm-name properties.

@geoand
Copy link
Contributor

geoand commented Apr 8, 2019

@gsmet @mkouba I vaguely remember talking about this somewhere. Would you like me to take this if you haven't fixed it already?

@gsmet
Copy link
Member

gsmet commented Apr 8, 2019

Yes, I mentioned the issue to @mkouba the other day.

@mkouba I know I'm a bit repetitive on the subject but with this removable bean feature, it looks like we need to think about all the possible features of each framework and tweak things for each framework as they might rely on unused beans. It really seems fragile to me and a lot of work for the future. Am I mistaken?

I think I fail to see why this feature is so useful because if it's just removing beans that the user explicitly declared, I think it's going to be a Pandora box. Could you explain it once and for all so that I'm fully aware of the why and I don't bother you anymore with this?

Thanks!

@gsmet gsmet added kind/bug Something isn't working area/arc Issue related to ARC (dependency injection) area/resteasy-classic labels Apr 8, 2019
geoand added a commit to geoand/quarkus that referenced this issue Apr 8, 2019
@geoand
Copy link
Contributor

geoand commented Apr 8, 2019

In any case, I have opened a (small) PR for this specific issue.

geoand added a commit to geoand/quarkus that referenced this issue Apr 8, 2019
@mkouba
Copy link
Contributor

mkouba commented Apr 8, 2019

This issue duplicates #1880.

As for the @LoginConfig annotation - it's not CDI-related and I don't think that the bean removal affects processing of this annotation.

@mkouba
Copy link
Contributor

mkouba commented Apr 9, 2019

@dansiviter Could you pls verify whether this issue is solved by #1924?

@mkouba mkouba closed this as completed Apr 12, 2019
@gsmet gsmet added the triage/duplicate This issue or pull request already exists label Apr 15, 2019
@dansiviter
Copy link
Author

Apologies for slow reply. Yes, looks better in v0.13.3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/arc Issue related to ARC (dependency injection) area/resteasy-classic kind/bug Something isn't working triage/duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

4 participants