Baoyuantop commented on issue #13417:
URL: https://github.com/apache/apisix/issues/13417#issuecomment-4549990361

   Thanks for the question @myhgc. APISIX does not guarantee that JSON object 
key order is preserved after a plugin parses and re-serializes the request 
body, JSON objects should not semantically depend on key order. Internally, 
JSON objects are decoded into Lua tables and then encoded again, and that 
process does not preserve the original textual key order.
   
   If you must preserve the exact original body bytes, the route should avoid 
plugins or custom code that parse and rewrite the JSON body. If you need to 
transform the JSON and also require a specific output order, the plugin/custom 
logic needs to generate the output using an explicit template/order rather than 
relying on the input object's original order. If you believe the body changes 
even with pure proxying and no body-related plugins, please provide the route 
config, plugin list, and a minimal reproduction.


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to