473,486 Members | 2,427 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

AJAX memory leak(?)

I have an existing asp.net 2.0 webforms app using master/content pages, and
it works fine.

I added some Ajax elements, including some UpdatePanels and modal PopUp
panels which contain asp.net controls like gridviews with selectable rows,
buttons, textboxes. I'm using Ajax 1.0, and the users are still using IE 6.

Some heavy users reported that the application starts to run slowly after a
while, and task manager shows the memory usage for IE increasing to 150 to
170 meg and up.

I have searched google, and read articles like "Understanding and Solving
Internet Explorer Leak Patterns", but I have not added any javascript with
the Ajax controls, so I haven't created any circular references or other
memory leak problems.

Is there a resolution for this apparent memory leak?

Thanks
Bill

Jun 20 '07 #1
8 4155
Some heavy users reported that the application starts to run slowly after
a while, and task manager shows the memory usage for IE increasing to 150
to 170 meg and up.

Are you using few or more iframe's?
If so, see if you have some code like window.obj = item1 || { } or
parent.obj = item1 || { }
This is one of the most common source of memory-leak on IE.

I'm not quite sure if there's any place where these memory-leak cases are
put documented :)

--
Happy Hacking,
Gaurav Vaish | www.mastergaurav.com
www.edujini-labs.com
http://eduzine.edujini-labs.com
-----------------------------------------
Jun 20 '07 #2
but the toolkit controls generate a lot of javascript. you probably need
to break your down to smaller chunks, and test each control to find the
"leak".

-- bruce (sqlwork.com)
BillE wrote:
I have an existing asp.net 2.0 webforms app using master/content pages, and
it works fine.

I added some Ajax elements, including some UpdatePanels and modal PopUp
panels which contain asp.net controls like gridviews with selectable rows,
buttons, textboxes. I'm using Ajax 1.0, and the users are still using IE 6.

Some heavy users reported that the application starts to run slowly after a
while, and task manager shows the memory usage for IE increasing to 150 to
170 meg and up.

I have searched google, and read articles like "Understanding and Solving
Internet Explorer Leak Patterns", but I have not added any javascript with
the Ajax controls, so I haven't created any circular references or other
memory leak problems.

Is there a resolution for this apparent memory leak?

Thanks
Bill


Jun 20 '07 #3
So the javascript generated by the ajax controls is causing the memory leak?

Once I have identified the control can I fix it, or just remove it?

Would it sound like whining if I said that MS should fix this?

"bruce barker" <no****@nospam.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
but the toolkit controls generate a lot of javascript. you probably need
to break your down to smaller chunks, and test each control to find the
"leak".

-- bruce (sqlwork.com)
BillE wrote:
>I have an existing asp.net 2.0 webforms app using master/content pages,
and it works fine.

I added some Ajax elements, including some UpdatePanels and modal PopUp
panels which contain asp.net controls like gridviews with selectable
rows, buttons, textboxes. I'm using Ajax 1.0, and the users are still
using IE 6.

Some heavy users reported that the application starts to run slowly after
a while, and task manager shows the memory usage for IE increasing to 150
to 170 meg and up.

I have searched google, and read articles like "Understanding and Solving
Internet Explorer Leak Patterns", but I have not added any javascript
with the Ajax controls, so I haven't created any circular references or
other memory leak problems.

Is there a resolution for this apparent memory leak?

Thanks
Bill

Jun 20 '07 #4
if its toolkit control (say the modal), then its not MS, its a codeplex
open source project. you can download the source and post a fix.

-- bruce (sqlwork.com)

BillE wrote:
So the javascript generated by the ajax controls is causing the memory leak?

Once I have identified the control can I fix it, or just remove it?

Would it sound like whining if I said that MS should fix this?

"bruce barker" <no****@nospam.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
>but the toolkit controls generate a lot of javascript. you probably need
to break your down to smaller chunks, and test each control to find the
"leak".

-- bruce (sqlwork.com)
BillE wrote:
>>I have an existing asp.net 2.0 webforms app using master/content pages,
and it works fine.

I added some Ajax elements, including some UpdatePanels and modal PopUp
panels which contain asp.net controls like gridviews with selectable
rows, buttons, textboxes. I'm using Ajax 1.0, and the users are still
using IE 6.

Some heavy users reported that the application starts to run slowly after
a while, and task manager shows the memory usage for IE increasing to 150
to 170 meg and up.

I have searched google, and read articles like "Understanding and Solving
Internet Explorer Leak Patterns", but I have not added any javascript
with the Ajax controls, so I haven't created any circular references or
other memory leak problems.

Is there a resolution for this apparent memory leak?

Thanks
Bill

Jun 20 '07 #5
Hi,

BillE wrote:
So the javascript generated by the ajax controls is causing the memory leak?

Once I have identified the control can I fix it, or just remove it?

Would it sound like whining if I said that MS should fix this?
Which versionj of IE are you using? In my previous project, a web
application with a self written AJAX layer (this was before ASP.NET
AJAX), we found memory leaks in IE6 and reported to Microsoft. Most
leaks were solved by Microsoft in a "security patch" which was made
available something like 2 year ago, I guess. Some leaks still remain,
especially handle leaks. The problem is that it's quite easy to create
circular references in the web browser between the JavaScript engine,
the HTML engine and the CSS engine. These leaks are usually cleaned up
when the page is reloaded (because everything is garbage collected), but
with AJAX, pages are often not reloaded for days (in our case, a few
days at least are typical, this can go up to 3 weeks).

HTH,
Laurent
--
Laurent Bugnion [MVP ASP.NET]
Software engineering, Blog: http://www.galasoft.ch
PhotoAlbum: http://www.galasoft.ch/pictures
Support children in Calcutta: http://www.calcutta-espoir.ch
Jun 20 '07 #6
The client is using IE6.

Are these memory leaks caused by Ajax or in IE6? I realize that can't be
answered without identifying the memory leak, but I'm trying to figure out
whether to yank Ajax out of my app, which will be tough because now users
are used to it.

I'm surprised because my usage of Ajax involves just the simplest, most
basic implementation of an update panel and modal popup, yet it doesn't take
long before the thing bogs down and i hate telling users that they should
close IE every now and then to release memory!

"Laurent Bugnion, MVP" <ga*********@bluewin.chwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
Hi,

BillE wrote:
>So the javascript generated by the ajax controls is causing the memory
leak?

Once I have identified the control can I fix it, or just remove it?

Would it sound like whining if I said that MS should fix this?

Which versionj of IE are you using? In my previous project, a web
application with a self written AJAX layer (this was before ASP.NET AJAX),
we found memory leaks in IE6 and reported to Microsoft. Most leaks were
solved by Microsoft in a "security patch" which was made available
something like 2 year ago, I guess. Some leaks still remain, especially
handle leaks. The problem is that it's quite easy to create circular
references in the web browser between the JavaScript engine, the HTML
engine and the CSS engine. These leaks are usually cleaned up when the
page is reloaded (because everything is garbage collected), but with AJAX,
pages are often not reloaded for days (in our case, a few days at least
are typical, this can go up to 3 weeks).

HTH,
Laurent
--
Laurent Bugnion [MVP ASP.NET]
Software engineering, Blog: http://www.galasoft.ch
PhotoAlbum: http://www.galasoft.ch/pictures
Support children in Calcutta: http://www.calcutta-espoir.ch

Jun 21 '07 #7
Hi,

BillE wrote:
The client is using IE6.

Are these memory leaks caused by Ajax or in IE6? I realize that can't be
answered without identifying the memory leak, but I'm trying to figure out
whether to yank Ajax out of my app, which will be tough because now users
are used to it.
JavaScript runs in the IEXPLORE process, so the leaks were in this
process too. Symptoms were that if you left the web application (which
regularly connects to the server for a heartbeat) run too long, the
memory usage would grow uncontrolled, the number of handles too, until
eventually the application was so slow that we had to shut it down manually.

I'm surprised because my usage of Ajax involves just the simplest, most
basic implementation of an update panel and modal popup, yet it doesn't take
long before the thing bogs down and i hate telling users that they should
close IE every now and then to release memory!
I don't have much experience with ASP.NET AJAX. As I said, our flavour
of AJAX was self-made, and we were able to modify it until we were
satisfied.

HTH,
Laurent
--
Laurent Bugnion [MVP ASP.NET]
Software engineering, Blog: http://www.galasoft.ch
PhotoAlbum: http://www.galasoft.ch/pictures
Support children in Calcutta: http://www.calcutta-espoir.ch
Jun 21 '07 #8
Thanks.

"Laurent Bugnion, MVP" <ga*********@bluewin.chwrote in message
news:eW*************@TK2MSFTNGP02.phx.gbl...
Hi,

BillE wrote:
>The client is using IE6.

Are these memory leaks caused by Ajax or in IE6? I realize that can't be
answered without identifying the memory leak, but I'm trying to figure
out whether to yank Ajax out of my app, which will be tough because now
users are used to it.

JavaScript runs in the IEXPLORE process, so the leaks were in this process
too. Symptoms were that if you left the web application (which regularly
connects to the server for a heartbeat) run too long, the memory usage
would grow uncontrolled, the number of handles too, until eventually the
application was so slow that we had to shut it down manually.

>I'm surprised because my usage of Ajax involves just the simplest, most
basic implementation of an update panel and modal popup, yet it doesn't
take long before the thing bogs down and i hate telling users that they
should close IE every now and then to release memory!

I don't have much experience with ASP.NET AJAX. As I said, our flavour of
AJAX was self-made, and we were able to modify it until we were satisfied.

HTH,
Laurent
--
Laurent Bugnion [MVP ASP.NET]
Software engineering, Blog: http://www.galasoft.ch
PhotoAlbum: http://www.galasoft.ch/pictures
Support children in Calcutta: http://www.calcutta-espoir.ch

Jun 21 '07 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
3389
by: ranjeet.gupta | last post by:
Dear All Is the Root Cause of the Memory corruption is the Memory leak, ?? suppose If in the code there is Memory leak, Do this may lead to the Memory Corruption while executing the program ? ...
17
4766
by: José Joye | last post by:
Hi, I have implemented a Service that is responsible for getting messages from a MS MQ located on a remote machine. I'm getting memory leak from time to time (???). In some situation, it is...
20
8016
by: jeevankodali | last post by:
Hi I have an .Net application which processes thousands of Xml nodes each day and for each node I am using around 30-40 Regex matches to see if they satisfy some conditions are not. These Regex...
23
4504
by: James | last post by:
The following code will create memory leaks!!! using System; using System.Diagnostics; using System.Data; using System.Data.SqlClient; namespace MemoryLeak
6
2221
by: petermichaux | last post by:
Hi, Reading the Yahoo! UI AJAX library, there is a unique workaround for an apparent IE 6 memory leak with binding a function to onreadystatechange. Instead of binding a function to...
9
1656
by: CeyloR | last post by:
Hello everyone, I have a problem with my Ajax page. I'm jusing prototype-1.4.0.js as framework. I have a function to populate three listboxes. The items in the listboxes are from a MYSQL...
3
1405
by: HarryA | last post by:
Hello all, what would be a good book or article to learn AJAX with HTML/CSS/javascript on the client side and Perl on the server side? I am NOT interested in XML, PHP, CGI:: AJAX or other...
7
2789
by: =?Utf-8?B?Tmlrb2xheSBFdnNlZXY=?= | last post by:
Hi! I know this topic has been discussed a long way, but I haven't found any apparent solution (maybe I shouldn't be looking for a one :)) I have a very simple application with one page and with...
22
9295
by: Peter | last post by:
I am using VS2008. I have a Windows Service application which creates Crystal Reports. This is a multi theaded application which can run several reports at one time. My problem - there is a...
0
6964
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
1
6842
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7330
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5434
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4865
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4559
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3070
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
1
598
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
262
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.