I get an OutOfMemoryException while executing the following code, there are 584678 MyState entries:
The pseudo schema below:
Is that the expected behaviour ? |
Hello Benoit! I can't say exactly with provided information. However here are some ideas:
Our bulk operations extension supports server-side removal of entities. However it is incapable of processing paired assocation logic, so you will need to do this by manually (if you have paired assocations). Also executing bulk operation resets your session cache. This will degrade performance if you plan to access entities after that. Alternatively you could try to remove entities in smaller batches:
|
Hello Denis, Thanks for your quick answer. As this is the expected behaviour and the removal using Session.Current.Remove processes every entity one by one, I am going to use the bulk operations extension. |