Fadelis/grpcmock

Docker support and remote java client

dtuchs opened this issue · 3 comments

First of all I want to thank you for this simple solution for grpc mocking, it's really useful in unit tests!
But sometimes we would like the grpcmock to be called not directly from tests, but from another service (yep, I'm talking about end-2-end tests for several microservices)
WireMock and mock-server already support running as stateful service in docker, and I'm sure many developers will be happy to get a similar solution for gRPC.
Also, gripmock already supports standalone running in docker, but they don't have a remote client, there is only REST API. Of course, it is possible to implement “WireMock-style” simple client for gripmock,
but first I wanted to ask if you have any plans to do something like that in the future?
Thanks!

Hey @dtuchs, I glad you've found grpcmock useful!
Initially for me it was only about mocking gRPC services in unit/it tests, and I've never though about creating a client for e2e. But I think that definitely should be possible. Tho it would have reduced matching possibilities (you can't jsonize a predicate), probably similar to gripmock - equals and contains. Also not sure about bidistreaming api definitions (that's a thing to improve on the DSL as well).
I didn't get the part were gripmock doesn't have a remote client? I seems it does provide a Dockerfile, which could be used to run the client?

Hi @Fadelis

Yes Docker support is something which will be highly useful.
Is there any near future plan for this to get Docker support to run remotely via a java client ?

Hi @Fadelis

Yes Docker support is something which will be highly useful. Is there any near future plan for this to get Docker support to run remotely via a java client ?

Hi @nitink007 I have no plans for it atm, since it would require quite a different structure to support this (loading proto files to docker container, parsing and loading json scenarios and etc). As mentioned in the other linked issue you could check out https://github.com/Adven27/grpc-wiremock project, maybe it will suit your needs.