flames icon indicating copy to clipboard operation
flames copied to clipboard

Reduce list size payload

Open mgwidmann opened this issue 6 years ago • 0 comments

On https://github.com/mgwidmann/slack_coder the payload size can get quite large when a large number of incidents happen. i.e. almost 5000 times a foreign key constraint failed, in addition to about 20 total error objects it produced 8.9MB of JSON returned from the API. Using the inspector, Chrome was having trouble parsing the response body 😄 in the network tab.

To reduce the payload size, instead return just the first message plus the count of how many incidents there are.

mgwidmann avatar Sep 21 '17 19:09 mgwidmann