smocker-dev / smocker

Smocker is a simple and efficient HTTP mock server and proxy
https://smocker.dev
MIT License
1.16k stars 61 forks source link

If TLS/HTTPS is added, what about gRPC support? #236

Open comerford opened 2 years ago

comerford commented 2 years ago

I realise it is not as easy as just dropping in a protobuf and gRPC library, but given that smocker is written in Go, I think it is in an excellent spot to be able to mock gRPC services too. The only options I know of for this are commercial and (the one I have actually seen) Java based. I think this would be a very attractive feature, especially for people writing Go based services (like we are) which tend to use gRPC over REST a lot.

Thiht commented 2 years ago

Hi, We (me and @gwleclerc) have not added gRPC support for the simple reason that we've never used it :D I'm not sure we'd be able to implement a good user experience, or useful features for that matter, for a technology we don't actively use. In comparison we dogfood a lot what we do on Smocker as it currently is.

I agree it would be a great feature, but we're not ready to implement it yet.

comerford commented 2 years ago

That's fair - we are only starting to use it ourselves (we have to implement gRPC in C++ first - ick) but it is very prevalent in Golang in general. While researching options, I found this:

https://github.com/Adven27/grpc-wiremock

That's an interesting approach, it translates to HTTP so that the original mock server can still be used as usual