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

Add Stereotypes and Mixins (and more) #316

Open
t1 opened this issue Jul 11, 2020 · 13 comments
Open

Add Stereotypes and Mixins (and more) #316

t1 opened this issue Jul 11, 2020 · 13 comments
Assignees
Labels
Client This issue applies to the Client side Server This issue applies to the Server side

Comments

@t1
Copy link
Collaborator

t1 commented Jul 11, 2020

I added power-annotations to the typesafe client as a PoC.

There are two tests that show using a Stereotype and a Mixin.

Maybe you can take a look?

It's in a branch in my fork. I didn't want to create a PR to master, yet, as I think we should work on a branch first; and it seems like I can't create a PR for a new branch in the GitHub UI.

@t1
Copy link
Collaborator Author

t1 commented Jul 11, 2020

This fixes eclipse/microprofile-graphql#111

@phillip-kruger
Copy link
Member

I like it. I spoke to @radcortez to see if we should move power-annotations to SmallRye. @radcortez see examples mentioned above

@phillip-kruger
Copy link
Member

@t1 - we can move power annotation to smallrye commons. Let's chat on gitter to discuss

@phillip-kruger phillip-kruger added Client This issue applies to the Client side Server This issue applies to the Server side labels Sep 1, 2020
@t1
Copy link
Collaborator Author

t1 commented Oct 11, 2020

Another option would be to merge it directly into Jandex. In that way, all implementations using Jandex would benefit without needing to change their code.

t1 added a commit to t1/smallrye-graphql that referenced this issue Nov 25, 2020
…h power-jandex-maven-plugin

Signed-off-by: Rüdiger zu Dohna <[email protected]>
@t1
Copy link
Collaborator Author

t1 commented Nov 25, 2020

Now it already works without any change to the Smallrye GraphQL server code base! I have tested it with a class that uses a Stereotype for the @GraphQLApi annotation and a Mixin for the @Query annotation here.

@t1
Copy link
Collaborator Author

t1 commented Nov 25, 2020

We may want to update all MP GQL annotations to allow them to be used in Stereotypes by adding @Target(ANNOTATION_TYPE).

@phillip-kruger
Copy link
Member

Will you log an issue in mp ?

phillip-kruger added a commit that referenced this issue Nov 25, 2020
#316: add power annotations with power-jandex-maven-plugin
@t1
Copy link
Collaborator Author

t1 commented Nov 25, 2020

Will you log an issue in mp ?

sure :-)

@t1
Copy link
Collaborator Author

t1 commented Nov 25, 2020

How would this work if you do not use maven to get the Jandex index ? (i.e jandex index is available, like with WF and Quarkus?)

I've already extracted the actual resolution code to a commons module, so we can easily add it to a runtime scanner.

t1 added a commit to t1/smallrye-graphql that referenced this issue Dec 8, 2020
t1 added a commit to t1/smallrye-graphql that referenced this issue Dec 8, 2020
t1 added a commit to t1/smallrye-graphql that referenced this issue Dec 8, 2020
Signed-off-by: Rüdiger zu Dohna <[email protected]>
t1 added a commit to t1/smallrye-graphql that referenced this issue Dec 9, 2020
t1 added a commit to t1/smallrye-graphql that referenced this issue Dec 9, 2020
t1 added a commit to t1/smallrye-graphql that referenced this issue Dec 9, 2020
Signed-off-by: Rüdiger zu Dohna <[email protected]>
t1 added a commit to t1/smallrye-graphql that referenced this issue Dec 10, 2020
t1 added a commit to t1/smallrye-graphql that referenced this issue Dec 10, 2020
@t1
Copy link
Collaborator Author

t1 commented Dec 11, 2020

#569 still keeps the implementation separate, i.e. you'll have to use the power-jandex-maven-plugin to see any effect.

Next, I'll integrate it into the servlet and the schema maven/gradle plugins, so the behavior is available everywhere.

@Pilpin
Copy link

Pilpin commented Jul 14, 2023

Hello, would you consider making a plugin for gradle as well ?
FYI, the link to where the project has moved to on https://github.com/t1/power-annotations is down.

@t1
Copy link
Collaborator Author

t1 commented Jul 15, 2023

@Pilpin : power-annotations is currently dormant. I currently just can't find the energy to push it forward, as it would make most sense, if it was adopted by, e.g., Jakarta. So I archived it. Feel free to pick it up and use it as you may find suitable.

@Pilpin
Copy link

Pilpin commented Jul 16, 2023

Sorry to here that, is there a discussion somewhere to have the project adopted ?
I'll try and make a gradle plugin when I have enough time.

Thank you for your great work and your quick response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Client This issue applies to the Client side Server This issue applies to the Server side
Projects
None yet
Development

No branches or pull requests

3 participants