First time posting, hope I can provide enough information that this makes sense. Sorry if this gets verbose, but I am sure someone will ask me an unrelated question before helping me, so I figure I might as well explain it all now.
I am a Jr. developer at a small company working in as sort of an apprentice to an older developer (coding for 30+ years). The program is for internal use by employees as a ticket tracking system running as a front end for a SQL database. I noticed recently that a small group of users will periodically (once a week) get memory exceptions, so I got a profiling tool to look into the problem. I am having trouble working with the wealth of information it is supplying, and unfortunately the problem is not yet a large enough concern to my lead developer for him to pull away from his current project. I am hoping to be able to handle this without forcing him to stop what he is doing.
The Problem:
A commonly used form (MDI child) to view/edit tickets does not collect ANY of the gen 2 memory it is consuming when it is closed within a reasonable amount of time. It eventually must collect, or this issue would be affecting everyone, but in the shorter tests I have done (10-15 minutes) it does not collect at all.
The profiler shows that the largest remnant from the form is datarows, referenced by the MDI parent from through a System.Windows. Forms.PropertyS tore+ObjectEntr y[]. I've read that this is due to .net not collecting the last MDI child. However, even if I open 3 forms, then close them all, none of the memory from ANY of them releases. The memory use in gen 2 just continues to grow. Gen 0 and 1 collect.
In the MDI parent a dataset that stores a number of tables used for relations is copied by this MDI child form so that we aren't making continuous calls to the SQL server for them. I think this may be what the reference that is keeping the form alive is. I am not sure though. If this is the case, how do I remove this reference when or after closing the form?
If this is not the case, how can I find what is being referenced?
I know that is a lot, I appreciate any help you guys can give.
I am a Jr. developer at a small company working in as sort of an apprentice to an older developer (coding for 30+ years). The program is for internal use by employees as a ticket tracking system running as a front end for a SQL database. I noticed recently that a small group of users will periodically (once a week) get memory exceptions, so I got a profiling tool to look into the problem. I am having trouble working with the wealth of information it is supplying, and unfortunately the problem is not yet a large enough concern to my lead developer for him to pull away from his current project. I am hoping to be able to handle this without forcing him to stop what he is doing.
The Problem:
A commonly used form (MDI child) to view/edit tickets does not collect ANY of the gen 2 memory it is consuming when it is closed within a reasonable amount of time. It eventually must collect, or this issue would be affecting everyone, but in the shorter tests I have done (10-15 minutes) it does not collect at all.
The profiler shows that the largest remnant from the form is datarows, referenced by the MDI parent from through a System.Windows. Forms.PropertyS tore+ObjectEntr y[]. I've read that this is due to .net not collecting the last MDI child. However, even if I open 3 forms, then close them all, none of the memory from ANY of them releases. The memory use in gen 2 just continues to grow. Gen 0 and 1 collect.
In the MDI parent a dataset that stores a number of tables used for relations is copied by this MDI child form so that we aren't making continuous calls to the SQL server for them. I think this may be what the reference that is keeping the form alive is. I am not sure though. If this is the case, how do I remove this reference when or after closing the form?
If this is not the case, how can I find what is being referenced?
I know that is a lot, I appreciate any help you guys can give.
Comment