This repository was archived by the owner on Dec 14, 2018. It is now read-only.
This repository was archived by the owner on Dec 14, 2018. It is now read-only.
Unable to read big json file from Request.Body #3235
Closed
Description
I'm trying to read big JSON file (UTF8) from Request.Body
stream:
string content;
using (var sr = new StreamReader(Request.Body, Encoding.Default))
content = sr.ReadToEnd();
At the beginning it's ok, but content
variable contains invalid character sequence after some offset.
Sample repo: https://github.com/anfomin/DNX-MVC-bigfile. There is file sample.json
. Just run dnx kestrel
and make:
POST http://localhost:5000
with body = sample.json
file.
You will find mismatches since line 84.
I've tried latest DNX 1.0.0-beta8-15736 from https://www.myget.org/F/aspnetvnext/api/v2 and 1.0.0-rc1-15775 from https://www.myget.org/F/aspnetcidev/api/v2.