OutOfMemoryException

Please enter any bugs here. We will check this daily!

OutOfMemoryException

Postby cminorm on Tue Oct 23, 2007 8:12 pm

When I try to generation for all tables in the database I get an OutOfMemoryExcpetion Error. If I run 10 tables at a time, everything works fine. I modified my templates to add some functionality. Here is the entire error message. Does anyone have any suggestions?

----
OutOfMemoryException

Void EngineExecuteCode(Zeus.IZeusCodeSegment, Zeus.IZeusContext)

Exception of type 'System.OutOfMemoryException' was thrown.

at Zeus.DotNetScript.DotNetScriptExecutioner.EngineExecuteCode(IZeusCodeSegment segment, IZeusContext context)
at Zeus.ZeusExecutioner.ExecuteCode(IZeusExecutionHelper helper, IZeusTemplate template, IZeusContext context, ArrayList templateGroupIds)
at Zeus.ZeusExecutioner.ExecuteCode(IZeusExecutionHelper helper, IZeusTemplate template, IZeusContext context, ArrayList templateGroupIds)
at Zeus.ZeusExecutioner.ExecuteCodeSegment(IZeusCodeSegment segment, IZeusContext context)
at Zeus.ZeusCodeSegment.Execute(IZeusContext context)
at MyGeneration.TemplateBrowser.ExecuteTemplate(ZeusTemplate template)
cminorm
Lurker
 
Posts: 5
Joined: Tue Oct 23, 2007 8:05 pm

Postby mike.griffin on Wed Oct 24, 2007 11:53 am

Is there any chance you are making a recursive call causing it to run infinitely? Or perhaps it's something with foreign keys that cause an infinite loop. Was it one of our templates to start out with?
User avatar
mike.griffin
Site Admin
 
Posts: 3290
Joined: Sat Apr 03, 2004 6:10 am
Location: Indianapolis, IN

Postby cminorm on Wed Oct 24, 2007 1:14 pm

It was one of the Entity Spaces Templates. I added a special Many To Many collection that has an Association bindable property. So if you have a classroom it would show you a list of all the student with the Associated column having a true for every row in the many to many ClassroomStudent table. The new collection also has properties to the ClassRoom Name and the student name. It even supports ManyToMany tables with attributes.

There does appear to be some runaway logic. Reviewing the generated code, the file is appending instead of closing at the end of this template.
cminorm
Lurker
 
Posts: 5
Joined: Tue Oct 23, 2007 8:05 pm

Postby mike.griffin on Wed Oct 24, 2007 3:51 pm

Ahh, cool, so does that mean you were able to fix it?
User avatar
mike.griffin
Site Admin
 
Posts: 3290
Joined: Sat Apr 03, 2004 6:10 am
Location: Indianapolis, IN

Postby cminorm on Wed Oct 24, 2007 4:00 pm

I put an if condition around a section of code so that it would not if it was not a ManyToMany code. When I pulled the following line outside the if condition, everything worked fine.

output.write(outputBuffer);
cminorm
Lurker
 
Posts: 5
Joined: Tue Oct 23, 2007 8:05 pm


Return to Defect Reporting (DON'T Post dOOdad bugs HERE)

Who is online

Users browsing this forum: Google [Bot] and 1 guest

cron