Hi, I have been memory analysing one of our programs that uses .net remoting and seems to be consuming more and more memory over time.
Doing a single snapshot (after is has been running for some time), if I sort by Live bytes, the largest number of bytes are being held by strings.
Many of these strings seem to be namespace names of our objects, and the instance graphs typically look like the attached.
Does anyone know why we have so many of these strings, and why the remoting proxy seems to have them rooted?
Thanks in advance for any suggestions.
regards, Peter
strings: Indirect delegate roots in remoting object
-
- Posts: 1030
- Joined: Wed Mar 02, 2005 7:53 pm
Re: strings: Indirect delegate roots in remoting object
If you have many strings that are rooted by remoting proxies, you probably also have many remoting proxies. A remoting proxy keeps information about the remoted object, and some of this information is stored in strings, and thus the proxies will keep the strings alive.
In your case I would focus on the proxies rather than the strings. As the memory analyzer says, the strings are indirectly held by a delegate. On the other hand, the proxies are directly held by the delegates, so I suggest that you investigate whether these delegates might cause a memory leak.
In your case I would focus on the proxies rather than the strings. As the memory analyzer says, the strings are indirectly held by a delegate. On the other hand, the proxies are directly held by the delegates, so I suggest that you investigate whether these delegates might cause a memory leak.
Best regards,
Andreas Suurkuusk
SciTech Software AB
Andreas Suurkuusk
SciTech Software AB
Re: strings: Indirect delegate roots in remoting object
Thank you for that Andreas, I will look into this.
regards Peter
regards Peter
Who is online
Users browsing this forum: Bing [Bot] and 15 guests