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

请教下srv和web请求参数的处理问题。 #68

Open
2lingnil opened this issue Jun 17, 2020 · 1 comment
Open

请教下srv和web请求参数的处理问题。 #68

2lingnil opened this issue Jun 17, 2020 · 1 comment

Comments

@2lingnil
Copy link

按照教程中的微服务架构,一个请求中的数据流整个流程大概是这个样子的:客户端请求->web->srv->db
那么这里有个问题,是常见web架构中不会遇到的问题:需要把客户端请求的参数转化为proto定义的参数,然后再传递到srv中。这个转化过程正常的单体web应用是不需要的。不知道有没有更好的处理方案?

PS:响应数据流也有一个把(proto)response转化为http response的过程。

谢谢。

@2lingnil
Copy link
Author

感觉这两个转化过程特别繁琐,特别是有很多字段的响应体和请求体的情况下。

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