Re: GWT memory management
you would at least lead code and the version of GWT raised. In GWT 1.4 I have a fairly complex application with a similar not experienced, but the leakage was not significant.
Re: GWT memory management
Yes GWT 1.5.2. We have leaks, too small at first, but considering that the application runs without rebooting and has an Entry Point, over time, after intensive work leaks are visible.
Re: GWT memory management
Quote:
Originally Posted by
Protector
The question for the guru of Google Web Toolkit : "How to write GWT code that does not receive a continuous flow of memory for IE?" We have a medium-sized application (~ 10-15 s). The problem is that working with the application in IE, the browser is always using more and more memory. In doing so, it either does not relieve the memory, or are not fully exempt. It was observed this fact: when you click refresh, IE frees all memory, and returns to the indicators that were at the opening page.
Reached the point that we write a simple test: to create the panel, adding to it a few thousand different standard components (buttons, checkbox text boxes, etc.), then we add this panel in RootPanel, and remove it from there. When creating and adding to the panel RootPanel, the browser further alotsiruet ~ 5 MB of memory, after the removal of the panel relieve ~ 4.8 MB. Ie for each cycle is not relieved order 200KB. In the test does not use Event-s, listeners, DOM class, there is no native methods. Neither Microsoft js memory leaks detector, does not show memory leaks in javascript, but the fact remains that, after 20 minutes, the repetition of cycles of testing, the browser is the addition of 10 to 15 MB of memory.
Who face similar problems and knows how to solve them the way your help would be useful
Try to create a smaller interface, instead of creating new elements, try to replace the contents of the old.
Re: GWT memory management
Quote:
Originally Posted by
Protector
The question for the guru of Google Web Toolkit : "How to write GWT code that does not receive a continuous flow of memory for IE?" We have a medium-sized application (~ 10-15 s). The problem is that working with the application in IE, the browser is always using more and more memory. In doing so, it either does not relieve the memory, or are not fully exempt. It was observed this fact: when you click refresh, IE frees all memory, and returns to the indicators that were at the opening page.
Reached the point that we write a simple test: to create the panel, adding to it a few thousand different standard components (buttons, checkbox text boxes, etc.), then we add this panel in RootPanel, and remove it from there. When creating and adding to the panel RootPanel, the browser further alotsiruet ~ 5 MB of memory, after the removal of the panel relieve ~ 4.8 MB. Ie for each cycle is not relieved order 200KB. In the test does not use Event-s, listeners, DOM class, there is no native methods. Neither Microsoft js memory leaks detector, does not show memory leaks in javascript, but the fact remains that, after 20 minutes, the repetition of cycles of testing, the browser is the addition of 10 to 15 MB of memory.
Who face similar problems and knows how to solve them the way your help would be useful
Here, two problems:
- Fragmentation Heap.
- Circular references.
Fragmentation Heap has gradually led to an increase in his memory. The second problem - this is cyclical links that cause the diversion of COM-objects. GWT can pull them, but this requires a transition between pages
Re: GWT memory management
Quote:
Originally Posted by
MindSpace
Here, two problems:
- Fragmentation Heap.
- Circular references.
Fragmentation Heap has gradually led to an increase in his memory. The second problem - this is cyclical links that cause the diversion of COM-objects. GWT can pull them, but this requires a transition between pages
In general, the first problem is quite simple - if we create and remove a lot of objects in the contiguous block of memory that are used for the distribution of these objects, we can show "holes."
The second problem - complicated. All GUI-objects and DOM nodes in IE represented as COM-objects. A COM-e is counting links. And if you make a series of objects, using reference-counting, they will live forever.
Re: GWT memory management
Try this article as a starting point in understanding IE memory leaks. Internet Explorer is far worse than other browsers in memory managment.
http://msdn.microsoft.com/en-us/library/bb250448.aspx
If your application uses "pure" GWT you will be somewhat protected from leaks, but perhaps you have some native methods that employ function closures (by far the easiest way to incur major leaks).
Re: GWT memory management
Considering the natives, we have prepared test application, where weexclude all natives, DOM class method calls, and even eventListeners. Sometimes browser frees some memory, but not all (after memory release, total browser's memory allocation is greater then before allocation).