The underlying table has a int, guid and Filestream column in SQL Server 2008 R2. The filestream shows up as byte[]. What I observe is that the memory consumption keeps on increasing. What should I do?
MyEntities bh = new MyEntities ();
foreach (var s in bh.TaskGraphs)
{
try
{
using (var x = new MemoryStream(s.TaskGraph1))
{
//var t = TaskGraph.Load(x);
//Validate(t);
}
}
catch (Exception e)
{
}
}
Here's the memory usage pattern
I now observed that doing bh.TaskGraphs.Select(p => new { p.TaskGraph1, p.StreamId } makes the exception go away. Is it due to the child table linked to this table?
BTW, each BLOB is ~ 3MB