Is the Json.NET JsonSerializer threadsafe?

后端 未结 4 867
孤城傲影
孤城傲影 2021-01-07 16:29

I\'m trying to reduce the amount of garbage my web service generates, and I noticed that we\'re creating a new Json.NET JsonSerializer instance for each request

4条回答
  •  慢半拍i
    慢半拍i (楼主)
    2021-01-07 16:34

    According to the Feature Comparison on the Newtonsoft site, it is thread safe, as are DataContractJsonSerializer and JavaScriptSerializer.

提交回复
热议问题