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

Ambiguous Module Name for quarkus-security #25795

Closed
rmanibus opened this issue May 25, 2022 · 9 comments · Fixed by quarkusio/quarkus-security#20 · May be fixed by #29370
Closed

Ambiguous Module Name for quarkus-security #25795

rmanibus opened this issue May 25, 2022 · 9 comments · Fixed by quarkusio/quarkus-security#20 · May be fixed by #29370
Assignees
Labels
area/security kind/bug Something isn't working triage/duplicate This issue or pull request already exists

Comments

@rmanibus
Copy link
Contributor

Describe the bug

io.quarkus:quarkus-security and io.quarkus.security:quarkus-security artifacts share the same automatic module name.

This make it extremelly painful to customize security features in a modularized application (I was trying to extend HttpAuthenticationMechanism which use classes from both modules).

With gradle I was able to do it with the following config for the moduleplugin:

modularity.patchModule("quarkus.security", "quarkus-security-2.9.1.Final.jar")

compileJava {
    moduleOptions {
        addExports = ['quarkus.security/io.quarkus.security.runtime': 'yourModule']
    }
}

Expected behavior

HttpAuthenticationMechanism can be extended without additional configuration

Actual behavior

No response

How to Reproduce?

No response

Output of uname -a or ver

No response

Output of java -version

17

GraalVM version (if different from Java)

No response

Quarkus version or git rev

2.9.1.Final

Build tool (ie. output of mvnw --version or gradlew --version)

gradle

Additional information

No response

@rmanibus rmanibus added the kind/bug Something isn't working label May 25, 2022
@quarkus-bot
Copy link

quarkus-bot bot commented May 25, 2022

/cc @sberyozkin

@sberyozkin
Copy link
Member

Not sure what can be done now, @aloubyansky, @stuartwdouglas, can you recommend something apart from for example, renaming io.quarkus.security:quarkus-security to io.quarkus.security:quarkus-security-core or something like that (which probably won't happen) ?

@rmanibus
Copy link
Contributor Author

@sberyozkin yeah I think this would be the proper solution. Also the hot reload is completely broken with this setup. I guess when quarkus recompile it does not take in account the module related options passed by gradle to javac.

@stuartwdouglas
Copy link
Member

We could maybe rename it to quarkus-security-api

@sberyozkin
Copy link
Member

@stuartwdouglas Hi Stuart, quarkus-security-api sounds good

@rmanibus
Copy link
Contributor Author

rmanibus commented May 27, 2022

@sberyozkin yeah I think this would be the proper solution. Also the hot reload is completely broken with this setup. I guess when quarkus recompile it does not take in account the module related options passed by gradle to javac.

@sberyozkin should I open another issue for that ? or is it a known problem ? I can't find anything about it in the github issues.

EDIT: I created #25836

@maxandersen
Copy link
Member

@sberyozkin is there something blocking us for doing this rename + relocation of artifacts?

benkard added a commit to benkard/quarkus-security that referenced this issue Nov 20, 2022
Adds an explicit automatic module path of io.quarkus.security, which
matches the root package name.

Fixes quarkusio/quarkus#25795.
benkard added a commit to benkard/quarkus that referenced this issue Nov 20, 2022
Baby steps toward Java Modules.

Fixes quarkusio#25795.
benkard added a commit to benkard/quarkus-security that referenced this issue Nov 21, 2022
Adds an explicit automatic module name of io.quarkus.security, which
matches the root package name.

Fixes quarkusio/quarkus#25795.
@sberyozkin sberyozkin self-assigned this Nov 27, 2023
@sberyozkin
Copy link
Member

Assigning ti myself to keep it more visible to myself

@sberyozkin
Copy link
Member

Closing as duplicate as we have a newer issue: #40417

@github-project-automation github-project-automation bot moved this from Todo to Done in Quarkus Roadmap/Planning May 3, 2024
@sberyozkin sberyozkin added the triage/duplicate This issue or pull request already exists label May 3, 2024
gsmet pushed a commit to benkard/quarkus-security that referenced this issue Jun 6, 2024
Adds an explicit automatic module name of io.quarkus.security, which
matches the root package name.

Fixes quarkusio/quarkus#25795.
gsmet pushed a commit to benkard/quarkus-security that referenced this issue Jun 6, 2024
Adds an explicit automatic module name of io.quarkus.security, which
matches the root package name.

Fixes quarkusio/quarkus#25795.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/security kind/bug Something isn't working triage/duplicate This issue or pull request already exists
Projects
Status: Done
4 participants