Changeset 394 for binary-improvements2/WebServer/src/WebAPI/AbsRestApi.cs
- Timestamp:
- Aug 8, 2022, 8:07:44 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
binary-improvements2/WebServer/src/WebAPI/AbsRestApi.cs
r391 r394 6 6 namespace Webserver.WebAPI { 7 7 public abstract class AbsRestApi : AbsWebAPI { 8 private static readonly UnityEngine.Profiling.CustomSampler jsonDeserializeSampler = UnityEngine.Profiling.CustomSampler.Create ("JSON_Deserialize"); 9 8 10 public sealed override void HandleRequest (RequestContext _context) { 9 11 JsonNode jsonBody = null; … … 14 16 if (!string.IsNullOrEmpty (body)) { 15 17 try { 18 jsonDeserializeSampler.Begin (); 16 19 jsonBody = Parser.Parse (body); 20 jsonDeserializeSampler.End (); 17 21 } catch (Exception e) { 22 jsonDeserializeSampler.End (); 23 18 24 SendEnvelopedResult (_context, null, HttpStatusCode.BadRequest, null, "INVALID_BODY", e); 19 25 return;
Note:
See TracChangeset
for help on using the changeset viewer.