Skip to content
This repository was archived by the owner on Dec 14, 2018. It is now read-only.

System.Buffers + Json.NET everywhere #4092

Closed
JamesNK opened this issue Feb 14, 2016 · 4 comments
Closed

System.Buffers + Json.NET everywhere #4092

JamesNK opened this issue Feb 14, 2016 · 4 comments
Assignees
Milestone

Comments

@JamesNK
Copy link
Member

JamesNK commented Feb 14, 2016

The JSON input and output formatters use array pooling from System.Buffers.

Other places to add System.Buffers:

@Eilon
Copy link
Member

Eilon commented Feb 18, 2016

Will discuss tomorrow with a few folks. Sorta kinda related to the mess described in #3992.

@Eilon Eilon added the invalid label Feb 19, 2016
@Eilon
Copy link
Member

Eilon commented Feb 19, 2016

Discussed with @dougbu and @rynowak (The Outlaw):

In #3992 we decided to remove JsonViewComponentResult, so that's not an issue here.

For JsonResultExecutor we took a look at the code and it already uses pooling by virtue of IHttpResponseStreamWriterFactory, which in its implementation uses the pooling feature.

@Eilon Eilon closed this as completed Feb 19, 2016
@JamesNK
Copy link
Member Author

JamesNK commented Feb 19, 2016

Json.NET doesn't automatically use pooling for its internal buffer because of IHttpResponseStreamWriterFactory.

From JsonOutputFormatter:

@rynowak
Copy link
Member

rynowak commented Feb 19, 2016

Ah ok yeah, you're right. We should do this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants