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

NPE thrown when trying to discover annotations on AOP Proxy objects #28

Closed
pluppens opened this issue Oct 31, 2016 · 6 comments
Closed

Comments

@pluppens
Copy link

In version 0.0.6, the org.lognet.springboot.grpc.GRpcServerRunner#run method tries to discover the @GRpcService annotation. However, this fails if the bindableService is wrapped as an AOP proxy.

A possible fix would be to check if the bindableService is a Proxy, and use its target class instead to find the @GRpcService annotation.

pluppens added a commit to pluppens/grpc-spring-boot-starter that referenced this issue Oct 31, 2016
@jvmlet jvmlet closed this as completed in b12c228 Nov 2, 2016
@jvmlet
Copy link
Collaborator

jvmlet commented Nov 2, 2016

Hi @pluppens
I've released version 0.0.7 with the fix, you are welcome to upgrade.

@pluppens
Copy link
Author

pluppens commented Nov 2, 2016

@jvmlet Awesome, thanks. I'll give it a spin later today.

@jvmlet
Copy link
Collaborator

jvmlet commented Nov 2, 2016

Would you please share your AOP configuraltion ?
I've managed to have proxied services, but the proxy is never called ... See AopServiceMonitor.java and DemoAppTestAop.java in demo project.

@pluppens
Copy link
Author

pluppens commented Nov 4, 2016

Hi @jvmlet, unfortunately, I didn't have time yet to verify things (will probably happen during the weekend). But just as a heads up - we're using Javanica annotations on our service methods, which caused the behaviour reported above.

@jvmlet
Copy link
Collaborator

jvmlet commented Nov 4, 2016

Thanks for the update. I'll give Javanica a try.

@pluppens
Copy link
Author

pluppens commented Nov 4, 2016

Other than that, I can confirm that things are working fine for us in 0.0.7. Thanks again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants