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

qbit doesn't support service created by guice with method interceptor module. #596

Closed
maratfdrv opened this issue Dec 19, 2015 · 6 comments

Comments

@maratfdrv
Copy link

I have warning in my log.

ServiceBuilder: QBit does not support method overloading methods in Service Queues problem name check is overloaded [CGLIB$findMethodProxy, longPollingBuilder, CGLIB$check$5, react, handleRuntimeException, CGLIB$SET_THREAD_CALLBACKS, check, CGLIB$SET_STATIC_CALLBACKS] from class com.stedify.core.util.test.ThrowHandlerEndpoint$$EnhancerByGuice$$40f5be55

@RichardHightower
Copy link
Member

should be fine. annoying warning but the generated guice methods should not hurt QBit.

@maratfdrv
Copy link
Author

I investigated this problem.

I had error "Unable to find body" in StandardRequestTransformer. Seems somewhere thinks that request should pass json or post param but I call http get method with request params.

@RequestMapping("/changeState")
public void changeState(
final Callback callback,
@RequestParam("id") final String pubId,
@RequestParam("state") final String state
) {

I found that MethodAccess class return same name for CGLIB$changeState$5 and changeState method and in this code in ServiceMetaBuilder.

requestMetaBuilder.addParameters(rootPath, servicePath, path, methodAccess)

calculates request types by CGLIB$changeState$5 but it doesn't have any RequestParam annotations.

@RichardHightower
Copy link
Member

hmm.. not sure how it does that. Can you add sample code somewhere in github so I can take a look? If I can reproduce it, I can likely fix it.

@maratfdrv
Copy link
Author

I've created PR with broken test. If you delete @Auth annotation from UserEndpoint class then guice method interceptor module will be disable and GuiceTest passes.

@maratfdrv
Copy link
Author

I've added brute fix for it.... Maybe you like it.

@RichardHightower
Copy link
Member

you patch fixed this.. so can I close this now?

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