0

I’m developing Single page application where all content on the portal is swap by JavaScript and get by AJAX call. Main content of the page is interactive canvas where the content of the 5 layers of canvas with redrawing content based on data get by AJAX call.

Problem:
I make about 30 click on the canvas and allocated system memory grew by 1,5 GB. None of the process in the task manager don’t show that allocate this memory. When I reload (F5) the page the allocated system memory immediately return to normal (free the 1.5GB).
Second way to retrieve the allocate memory is to stay on the page without any activity for about 30min and the allocated system memory return to normal. It is decrease steadily, not like on reloading the page.
Of course closing the web browser also ‘help’.

What could help me:
- How to check with process allocate the memory?
- Any idea what could allocate the memory?
- Any idea how to force memory to free ?

Environment:
- Windows 7 Enterprise (64bit)
- IIS 7
- SQL Server 2012 (11.0.2100)
- Chrome 27.0.1453.94
- Application is develop in Visual Studo 2010 with:
  - MVC 4

EDIT 06-06-2013
hear some example from tab chrome://memory-redirect/ after enter the application

 Memory Virtual memory PID Name Private Shared Total Private Mapped 2116 Browser 72608k 29688k 102296k 81680k 74404k 4756 GPU 55184k 13088k 68272k 69604k 21216k 4068 Tab (Chrome) - About Memory 9456k 65352k 74808k 16224k 17628k 176 Tab - Applicastion tab 29876k 66552k 96428k 39700k 19684k Σ 167124k 341804k 207208k 132932k 

Phisical memory usage - Task Manager: 2,59 GB

After 30 interactions on canvas

 Memory Virtual memory PID Name Private Shared Total Private Mapped 2116 Browser 81976k 42104k 124080k 89964k 95596k 4756 GPU 68136k 14176k 82312k 81548k 21452k 4068 Tab (Chrome) - About Memory 10816k 65408k 76224k 17372k 17632k 176 Tab - Applicastion tab 56180k 67644k 123824k 66224k 19688k Σ 217108k 406440k 255108k 154368k 

Phisical memory usage - Task Manager: 4.63 GB

From this calculation tables I see that java- leel can’t by larger then 64636 kB => 64MB => 0,064 GB. So my question is what for are allocate the rest of the memory almost 2 GB.
I guess it is connected with Chrome because this memory is release on page reload

1 Answer 1

1

Overview how one could produce javascript memory leaks:

Possible tools: (Some taken from here)

Sign up to request clarification or add additional context in comments.

3 Comments

I know that my application may have memory leek in java script. I want to take care of it later. But if it was just memory leek in java script ti would see rising memory allocation in "java run-time environment" or "Chrome" and it not happen. Or I thing wrong?
If you see increasing memory for each click you do not free all resources while requesting new memory. That's a leak :) Java run-time environment sounds like Java, not JavaScript. You could try to take a look at chrome://memory-redirect/ in your Chrome for more information about the memory usage of chrome.
I edit the main question and add data form chrome://memory-redirect/

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.