bytedance / go-tagexpr

An interesting go struct tag expression syntax for field validation, etc.
Apache License 2.0
1.66k stars 142 forks source link

支持gzip的request json body #36

Closed XIELongDragon closed 3 years ago

XIELongDragon commented 3 years ago

为了减少传输量,对请求body进行了gzip压缩,通过Content-Encoding进行标识。go-tagexpr是否准备支持?

如果需要提交实现PR,是引入一个新的bodycode,还是在binding内对Content-Encoding进行处理?

andeya commented 3 years ago

考虑一下在 *httpRequest.GetBody() 中直接处理,是否合理?

XIELongDragon commented 3 years ago

考虑一下在 *httpRequest.GetBody() 中直接处理,是否合理?

好的

andeya commented 3 years ago

https://github.com/bytedance/go-tagexpr/commit/3c3e845064ec5ac9e6bc5bed8a17cf8180bf447d