Out of Memory Exception during serialization : <p>I am fetching 300k+ records in a object from database. I am trying to serialize the heavy object below:</p>

<pre><code>List&lt;user&gt; allUsersList = businessProvider.GetAllUsers();
string json = JsonConvert.SerializeObject(allUsersList);
</code></pre>

<p>I am getting following exception while serializing the list - allUsersList.</p>

<p><em>Out of memory exception</em></p>

<p>i am using newtonsoft.json assembly to deserialize it.</p>
