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

handling message objects with package names and protoc-gen-go style M param #44

Open
quinn opened this issue Aug 23, 2021 · 3 comments
Open

Comments

@quinn
Copy link
Contributor

quinn commented Aug 23, 2021

Hi, I'm reviewing the implementation and I don't think it would work for multiple services / endpoints. I can put in some time to add this functionality, but I would need to know a good starting point of how this might work. Right now the graphql handler expects to be in the same go package as the generated GRPC code, so for this to work this assumption would need to change, I think. Would love to know your thoughts on this, thank you!

@quinn
Copy link
Contributor Author

quinn commented Aug 23, 2021

a few more comments:

  • I get a cryptic parse error on any name with a namespace, e.g. rpc GetAddress(shipping.GetAddressRequest) returns (shipping.Address) { outputs a contextless error expected ; found . message. go and grpc-go plugins are able to compile it.
  • How do you develop this module? Specifically, there are no tests, and I'm not clear how to integrate this into the protoc pipeline in development. Is there a way to use a debugger while receiving the stdin pipe from protoc?

@quinn
Copy link
Contributor Author

quinn commented Aug 23, 2021

sorry, one more thing: specifying the host in the proto seems inflexible. ideally there would be a way to change the host after the code is generated, to allow for an image that works in dev, staging, and prod.

@quinn
Copy link
Contributor Author

quinn commented Aug 29, 2021

I understand the runtime code a bit better now, and it seems like multiple services is supported with the muxer, which is great! So, i'm working on some patches to make it work with protobuf's with namespaces:

service Something {
  rpc CreateThing(somepkg.RequestMessage) returns (somepkg.ResponseMessage) {
  ...

currently this breaks on the code formatter step in the generator.

@quinn quinn changed the title single gateway for multiple services handling message objects with package names Aug 29, 2021
@quinn quinn changed the title handling message objects with package names handling message objects with package names and protoc-gen-go style M param Aug 29, 2021
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

1 participant