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

Is any method to access the raw request body in metadata? #1908

Closed
lonng opened this issue Jan 19, 2021 · 1 comment
Closed

Is any method to access the raw request body in metadata? #1908

lonng opened this issue Jan 19, 2021 · 1 comment

Comments

@lonng
Copy link

lonng commented Jan 19, 2021

Hi, everyone,

I am using the grpc-gateway in my production environment. And I encountered some issues when I try to access the raw request body via the metadata.

The following is my scenarios:

  • I defined an API for the PATCH request.
  • The patch API callback method will use the structure that contains all fields.
  • The request JSON body only contains part fields of it.
  • I want to get the raw request JSON body to determine which fields are patched and an unmarshalled struct.

If is there a solution for that, please leave comments on the issue, thanks very much.

@lonng
Copy link
Author

lonng commented Jan 19, 2021

Sorry, there is an existing solution for this issue.
see: https://grpc-ecosystem.github.io/grpc-gateway/docs/mapping/patch_feature/

@lonng lonng closed this as completed Jan 19, 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