Issue 35 in jayrock: JsonWriter doesn't flush on Dispose/Close

8 views
Skip to first unread message

jay...@googlecode.com

unread,
Jun 10, 2011, 9:27:30 AM6/10/11
to jayrock...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 35 by DanielLP...@gmail.com: JsonWriter doesn't flush on
Dispose/Close
http://code.google.com/p/jayrock/issues/detail?id=35

What steps will reproduce the problem?
1. create JsonTextWriter in using block
2. encode a large json object

What is the expected output? What do you see instead?
content not flushed / malformed JSON

What version of the product are you using? On what operating system?
I checked the latest code checked in and I don't see a call to flush.

jay...@googlecode.com

unread,
Jun 10, 2011, 12:48:26 PM6/10/11
to jayrock...@googlegroups.com
Updates:
Labels: Component-JSON

Comment #1 on issue 35 by azizatif: JsonWriter doesn't flush on
Dispose/Close
http://code.google.com/p/jayrock/issues/detail?id=35

Can you attach a stand-alone sample console that demonstrates this problem?

jay...@googlecode.com

unread,
Jun 17, 2011, 9:08:38 AM6/17/11
to jayrock...@googlegroups.com

Comment #2 on issue 35 by DanielLP...@gmail.com: JsonWriter doesn't flush
on Dispose/Close
http://code.google.com/p/jayrock/issues/detail?id=35

I can't currently, but I found another instance where this causes a problem
that you might be able to reproduce more easily:

HttpWebRequest request = WebRequest.Create(_uri_) as HttpWebRequest;
request.Method = "POST";
request.Headers.Add(HttpRequestHeader.ContentEncoding, "application/json;
charset=UTF8");
using ( JsonWriter writer = new JsonTextWriter(new StreamWriter(
request.GetRequestStream())))
{
JsonConvert.Export(RegistrationData_, writer);
}

HttpWebResponse response = request.GetResponse() as HttpWebResponse;

This code will hang because the request stream is never closed/flushed


jay...@googlecode.com

unread,
Aug 25, 2015, 5:24:46 AM8/25/15
to jayrock...@googlegroups.com

Comment #3 on issue 35 by azizatif: JsonWriter doesn't flush on
Dispose/Close
https://code.google.com/p/jayrock/issues/detail?id=35

This issue has been migrated to:
https://github.com/atifaziz/Jayrock/issues/35
The conversation continues there.
DO NOT post any further comments to the issue tracker on Google Code as it
is shutting down.
You can also just subscribe to the issue on GitHub to receive notifications
of any further development.

--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings
Reply all
Reply to author
Forward
0 new messages