-
Notifications
You must be signed in to change notification settings - Fork 9
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
verbose console output #38
Comments
I can do this in tests, e.g. I can change the config in GrpcAcceptanceTest, adding a notifier:
Strangely, I also needed to create a new Wiremock object in the init method, similarly to the test in wiremock-grpc-demos
I'm using the standalone in a dockerfile, though, and I'd like to set up request logging there. I can't figure out how to do that. My dockerfile is quite simple. I set some options in the entrypoint, but there's no way I can see to add a notifier.
|
I've been hacking around with the source code, and I've got something that works for me. I don't know whether it's the best way to do it, though. In the GrpcHttpServerFactory. we can pass the configured notifier into the GrpcFilter: The GrpcFilter stores that as a new field, and then passes it on to the handlers that it builds. (I've only tested this with the UnaryServerCallHandler.) The handlers also store the notifier as a new field, and then set the it in the LocalNotifier thread-local before invoking
I 'll create a pull request if I find time next week. |
Proposal
It would be great to see gRPC requests in the console just like http requests with the '-v' flag
References
No response
The text was updated successfully, but these errors were encountered: