StrataFrame Forum

EnterpriseDataSourceException

http://forum.strataframe.net/Topic26492.aspx

By Derek Price - 3/15/2010

During one of our CRUD unit tests we are getting an Enterprise Server exception related to out of memory:



~~~

System.IO.MemoryStream.EnsureCapacity(Int32 value)

System.IO.MemoryStream.Write(Byte[] buffer, Int32 offset, Int32 count)

System.IO.BinaryWriter.Write(String value)

MicroFour.StrataFrame.Data.Enterprise.RequestProcessor.ExecuteDataTable(ExecuteDataTableParams params)

MicroFour.StrataFrame.Data.Enterprise.EnterpriseDataSourceItem.GetDataTable(DbCommand Command, OnChangeEventHandler CallBack)

OHR.SYSTOC.Base.OHREnterpriseSourceItem.GetDataTable(DbCommand Command, OnChangeEventHandler CallBack) in C:\projects\SYSTOC.NET\MAIN\CODE\OHR.SYSTOC.Base\OHRDataSourceItems.cs: line 130

MicroFour.StrataFrame.Data.DataLayer.GetDataTable(DbCommand Command, Boolean RegisterNotification)

MicroFour.StrataFrame.Business.BusinessLayer.FillDataTable(DbCommand CommandToExecute)

OHR.SYSTOC.Base.BaseBO.FillDataTable(DbCommand CommandToExecute) in C:\projects\SYSTOC.NET\MAIN\CODE\OHR.SYSTOC.Base\BaseBO.cs: line 750

OHR.SYSTOC.Base.BaseBO.FillAll() in C:\projects\SYSTOC.NET\MAIN\CODE\OHR.SYSTOC.Base\BaseBO.cs: line 337

OHR.SYSTOC.Business.Test.Scheduling.ProcitemTest.CallFillMethod(Object sender) in C:\projects\SYSTOC.NET\MAIN\CODE\OHR.SYSTOC.Business.Test\Scheduling\ProcitemTest.cs: line 125

OHR.SYSTOC.Base.Tests.BaseBOTest.TestCRUD() in C:\projects\SYSTOC.NET\MAIN\CODE\OHR.SYSTOC.Base.Tests\BaseBOTest.cs: line 124

OHR.SYSTOC.Business.Test.Scheduling.ProcitemTest.TestCRUD() in C:\projects\SYSTOC.NET\MAIN\CODE\OHR.SYSTOC.Business.Test\Scheduling\ProcitemTest.cs: line 105

~~~



Based on this call stack can you tell if this the out of memory exception is happening when writing to the Enterprise Server or when the Enterprise Server is writing back? Ever seen this one before? I know the T-SQL is valid as it runs with no errors in SSMS. Any ideas on what to check?



Thanks,

Derek
By Trent L. Taylor - 3/15/2010

Well, how many records are you retrieving, what is the size of the query, and how much memory is on your machine running the unit test? This is a pretty hard question to answer without more information. I noticed that there was a FillAll method and it is writing to the memory stream. So most likely there is a limit being hit on the physical machine. But without all of the facts it is hard for me to tell.