[CLOSED] Memory Spikes in IE and other browsers

Page 1 of 4 123 ... LastLast
  1. #1

    [CLOSED] Memory Spikes in IE and other browsers

    hi,

    I am seeing very high memory spikes in IE and other browsers when I use Loader to load a view. Is there any way of minimizing the memory impact. see my sample below. I am using EXT.NET MVC. I see the same issue when I use the Loaders sample in the Examples explorer.


    Is there something I am doing incorrectly why I am seeing the memory spikes. Can this be resolved. I use the loader to extensively to load different views in the IFrame. Each time a new view is loaded, there is significant increase in the browsers memory usage which is not release even when a new view is loaded in the IFrame.

    Please advise.



    I am having some issues with my firewall adding my sample as it contains JS code. I will upload as soon as I can. Is there any way for you to assist until I am able to add sample.
    Attached Thumbnails Click image for larger version. 

Name:	columnHeader.png 
Views:	82 
Size:	21.0 KB 
ID:	5910  
    Last edited by Daniil; Apr 09, 2013 at 4:05 AM. Reason: [CLOSED]
  2. #2
    Do you use Loader with Frame mode? If yes then the memory consumption will be high because iframe as separate page, all resources are loaded for iframe also

    I suggest do not use iframes at all because it is very hard for a browser, use partial rendering (it is better approach)
    http://mvc.ext.net/#/Dynamic_Partial...Partial_Items/
    http://mvc.ext.net/#/Dynamic_Partial_Rendering/Add_Tab/
    http://mvc.ext.net/#/Dynamic_Partial...rtial_Content/
    http://mvc.ext.net/#/Dynamic_Partial_Rendering/Window/
  3. #3
    Hi,

    Is there any way of releasing the resource in the IFrame. We have done some major development using iframe. Is there a temporary fix for releasing the resources.
  4. #4
    Unfortunately, ExtJS has an old issue with releasing memory when iframe is destroyed
    It is not fixed still by Sencha
    http://www.sencha.com/forum/showthre...-in-IE9-iframe

    Therefore please consider to avoid iframes at all
  5. #5
    Hi,

    we are about to release and this is not an option at this point. We recognized this issue late in our process. Please let me know if you have any ideas or fix we could use until we are able to make this change which we will have to schedule as part of future release or patch.

    Any help would be welcome.
  6. #6
    Unfortunately, we don't have a fix . The bug seems to lay deep inside ExtJS.

    If you can provide a sample to reproduce, we would be happy to investigate. Maybe, we could come up with something in your case.

    Could you also clarify how much memory leaks?
  7. #7
    Hi,

    I sent you an email with my sample as we are having some issues with our firewall which is preventing me from posting with JS and HTML content in the pots.
  8. #8
    Thank you. I am reposting here.

    [Master]

    <%@ Master Language="C#" Inherits="System.Web.Mvc.ViewMasterPage" %>
     
    <%@ Import Namespace="Ext.Net.MVC" %>
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
     
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head id="Head1" runat="server">
        <title>
            <asp:ContentPlaceHolder ID="TitleContent" runat="server" />
            <asp:ContentPlaceHolder ID="MainContent" runat="server" />
        </title>
        <script src="/Scripts/jquery-1.5.1.js" type="text/javascript"></script>
        <script type="text/javascript" src="/Scripts/Monitor.js"></script>
    </head>
    <body>
        <form id="form1" runat="server" class="x-hidden">
        <div style="display: none">
            <cutewebui:uploader runat="server" />
        </div>
        </form>
        <ext:ResourceManager ID="MasterResourceManager" runat="server" Theme="Gray">
        </ext:ResourceManager>
        <ext:Viewport ID="TheViewPoint" EnableTheming="True" runat="server" IDMode="Explicit"
            Layout="BorderLayout">
            <Items>
                <ext:Panel runat="server" ID="NorthPanel" Region="North" AutoHeight="True">
                    <Items>
                        <ext:Toolbar ID="MainToolBar" runat="server">
                            <Items>
                                <ext:Button runat="server" ID="btn" Height="50" Text='Open View Port'>
                                    <Listeners>
                                        <Click Handler="Monitor.MenuItemOnClick({ title: 'Sample', linkurl: '/Grid/Index', icon: null, passParentSize: true})" />
                                    </Listeners>
                                </ext:Button>
                            </Items>
                        </ext:Toolbar>
                    </Items>
                </ext:Panel>
                <ext:Panel ID="MainContentPanel" Layout="Fit" runat="server" BodyPadding="0" AutoScroll="false"
                    Border="False" Title="1" Region="Center">
                    <Loader ID="MainContentPanelLoader" runat="server" Mode="Frame" DisableCaching="true"
                        AutoLoad="false" Scripts="false">
                    </Loader>
                    <Items>
                        <ext:Panel runat="server">
                        </ext:Panel>
                    </Items>
                    <Listeners>
                        <AfterRender Handler="App.MainContentPanel.setTitle('');">
                        </AfterRender>
                    </Listeners>
                </ext:Panel>
            </Items>
        </ext:Viewport>
    </body>
    </html>

    Controller


    public class GridController : Controller
        {
            //
            // GET: /Grid/
     
            public ActionResult Index()
            {
             
     
                return View("Index");
            }
     
        }

    View Loaded by Loader

    <%@ Page Language="C#" Inherits="System.Web.Mvc.ViewPage" %>
     
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
     
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head id="Head1" runat="server">
        <title></title>
        <meta content="NO-CACHE" http-equiv="CACHE-CONTROL" />
        <%-- Override the default label seperator and set to ""--%>
        <ext:ResourcePlaceHolder runat="server" Mode="ScriptFiles" />
         
    </head>
    <body>
        <ext:ResourceManager runat="server">
        </ext:ResourceManager>
     
        <ext:Viewport ID="viewportResultView" runat="server" Layout="border" IDMode="Static">
            <Items>
                <ext:Panel ID="Panel2" runat="server" Title="Sample" Height="100" Region="Center">
                    <Items>
                        <ext:Button ID="Button1" runat="server" Text="Show Upload Dialog">
                            <Listeners>
                              
                            </Listeners>
                        </ext:Button>
                    </Items>
                </ext:Panel>
                </Items>
            <Listeners>
     
           </Listeners>
        </ext:Viewport>
    </body>
    </html>

    JS

    Monitor = {
     
        MenuItemOnClick2: function (config) {
     
            //        App.MainContentPanel.clearContent();
     
            App.MainContentPanel.load(
                {
                    showMask: false,
                    url: config.linkurl,
                    disableCaching: true,
                    renderer: "frame",
                    passParentSize: config.passParentSize,
                    params: config.data,
                    scripts: "false"
                }
                );
        },
     
     
        MenuItemOnClick: function (config, item) {
            if (Ext.isEmpty(config.isPopup)) {
                config.isPopup = "false";
            }
            if (config.isPopup.toString().toLowerCase() == "false") {
                var numericId = "452316466989"; // this.hashCode(config.linkUrl);
                var id = "panel" + numericId;
                var panel = App.MainContentPanel.getComponent(id);
     
                if (App.MainContentPanel.items.length == 1) {
                    if (App.MainContentPanel.items.items[0].id == id) {
     
                        return;
                    }
                }
     
                var existingpanel = App.MainContentPanel.items.items[0];
                if (existingpanel && existingpanel.configData) {
                    var page = Monitor.GetActiveTabBody();
                    if (page.ClearAllComponent) {
                        page.ClearAllComponent();
                    }
                }
     
                App.MainContentPanel.removeAll();
     
                Ext.Function.defer(function () {
                    var panel = Ext.create('Ext.panel.Panel', {
                        id: id.toString(),
                        border: false,
                        configData: config,
                        loader: {
                            autoLoad: true,
                            renderer: "frame",
                            url: config.linkurl,
                            params: config.data
                        },
                        layout: "fit",
                        bodyPadding: 0
                    });
                    App.MainContentPanel.add(panel);
     
     
                    Ext.Function.defer(function () {
                        var iframe = $(panel.el.dom).find("iframe");
                        if (iframe.length > 0) {
                            var newId = "Iframe" + numericId;
                            iframe.attr("id", newId);
                        }
                    }, 100);
                }, 100);
     
            }
        },
     
     
     
    }
  9. #9
    Hi,

    Thank you.

    When you click the Open View Port button when viewing IE mostly, you will see the memory for the IE process increasing between 10-50MB. Please let me know if you are able to see this.
  10. #10
    Unfortunately, the code that I reposted throws exceptions. So, I can't run it.

    I am trying to run the project. It appears that it loads the default page well, but I can't see the "View port" button.

    So, what view within the project should I open?
Page 1 of 4 123 ... LastLast

Similar Threads

  1. [CLOSED] Behavior of 'Empty text' in different browsers
    By supera in forum 2.x Legacy Premium Help
    Replies: 7
    Last Post: Sep 13, 2012, 1:26 PM
  2. INSERT KeyMap (all browsers)
    By David Pelaez in forum 1.x Help
    Replies: 1
    Last Post: Jan 25, 2011, 2:36 PM
  3. [CLOSED] display difference between browsers
    By Stefanaccio in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: Dec 29, 2010, 6:43 AM
  4. [CLOSED] [1.0] Officially supported browsers
    By jmcantrell in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Sep 22, 2010, 12:55 PM
  5. [CLOSED] Hidden tab in IE7, but visible in other browsers
    By juanpablo.belli@huddle.com.ar in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: Mar 18, 2009, 1:32 PM

Posting Permissions