You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by "Jamel-jun (via GitHub)" <gi...@apache.org> on 2024/06/17 02:17:28 UTC

[I] bug: grpc-transcode protobuf 当有 int64 类型的字段时,传入 a 时,转换成了 10 [apisix]

Jamel-jun opened a new issue, #11355:
URL: https://github.com/apache/apisix/issues/11355

   ### Current Behavior
   
   我仅仅使用了 grpc-transcode 插件。
   我自定义了一个 protobuf,里面有 个 int64 类型的字段。
   ![image](https://github.com/apache/apisix/assets/50609931/36daccbf-aed4-46fc-9169-b050e0de4d7d)
   当 我通过 http 调用时,传入
   ```json
   {"currency":"MYR","value":"a"}
   ```
   
   解析到后端,value = 10
   
   ### Expected Behavior
   
   value = 10 是错误的,它应该只允许传入数字类型。
   我希望它 当传入非数字类型时,应该 抛出异常,例:400 bad request
   
   ### Error Logs
   
   _No response_
   
   ### Steps to Reproduce
   
   此场景必现
   
   ### Environment
   
   - APISIX version (run `apisix version`):
   - Operating system (run `uname -a`):
   - OpenResty / Nginx version (run `openresty -V` or `nginx -V`):
   - etcd version, if relevant (run `curl http://127.0.0.1:9090/v1/server_info`):
   - APISIX Dashboard version, if relevant:
   - Plugin runner version, for issues related to plugin runners:
   - LuaRocks version, for installation issues (run `luarocks --version`):
   
   ![image](https://github.com/apache/apisix/assets/50609931/16b5f10e-b32c-464d-bbfc-857652f2d58f)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] bug: grpc-transcode plugin, in Protobuf, when there is a field of type int64, when 'a' is passed in, it is converted to 10. [apisix]

Posted by "moonming (via GitHub)" <gi...@apache.org>.
moonming closed issue #11355: bug: grpc-transcode plugin, in Protobuf, when there is a field of type int64, when 'a' is passed in, it is converted to 10.
URL: https://github.com/apache/apisix/issues/11355


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org