weixin_33717298 2018-09-10 19:44 采纳率: 0%
浏览 63

IIS和大型JSON请求

I have a large JSON object of about 8 MB. If I cut down the name of variables that are duplicated in these lists will that help on the size? It’s an AJAX request coming from IIS.

{ “VenueLocationID” : 12 }

{ “vid” : 12 }
  • 写回答

1条回答 默认 最新

  • 10.24 2018-09-11 01:18
    关注

    I'm assuming that you have a lot of repetition of property names in your large JSON response. Instead of sacrificing the readability of your property names, I would try enabling gzip compression on your response. The gzip algorithm is particularly good at compression when there are repetitive strings fed to it.

    You can enable this compression in IIS, your application's web.config file, or in code. See this MSDN article for examples.

    评论

报告相同问题?