Reputation: 2545
My PHP application is decoding about 100 json objects each request, I have many requests per secound, and I need to optimize my code. I was wondering if it would be faster to decode one huge json object instead of 100 smaller ones (assuming this big json was made by nesting the small ones). Anyone had similar issue ?
Upvotes: 1
Views: 1752
Reputation: 12137
You will nearly have the same performance with your two methods.
Check your requests time execution and response time with Firebug
or similar.
After your test, it seems that your big json is slower than multiple mini json.
Upvotes: 1