我怎么能在我的JS /更新面板现场调试此内存使用/ DOM使用率增加 [英] How can I debug this memory usage / dom usage increase in my JS/Update panel site

查看:183
本文介绍了我怎么能在我的JS /更新面板现场调试此内存使用/ DOM使用率增加的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望一些JavaScript / ASP.Net大师能给我一些提示在这里。

I'm hoping some Javascript/ASP.Net gurus can give me some hints here.

我写这(不幸)使用的UpdatePanel的应用程序(是的,我知道这是一个愚蠢的想法,现在太晚了,虽然,我现在更了解它 - 即使它的一个内部网站,我有麻烦用它)

I've written an application which (unfortunately) uses UpdatePanel (yes, I'm aware that was a dumb idea, too late now though, I understand it more now - even though its an intranet site I'm having troubles with it)

该网站是一个基于Web的时间表网站,那种表格格式。总之,它基本上保存在这一切都在一个更新面板,自动保存和每分钟一次。这似乎为我工作很好,但我使用Firefox。其他的用户提供了更多的时间表项,和IE7有IE浏览器的内存使用情况不断增加,他们的浏览器变慢的问题。

The site is a web based timesheet site, kind of tabular format. Anyhow, it basically saves everything in it in an update panel, and autosaves once a minute. This seems to work fine for me, but I use firefox. Other users with more timesheet entries, and IE7 have problems with IE memory usage increasing and their browser slowing down.

我跑筛(网站上检查内存泄漏),它是pretty明显这是不好的:

I ran Sieve (checks for memory leaks on a website) and it was pretty obvious it was bad:

这就是我的网站加载并运行留下了位,刷新其在陷落,离开它,你可以看到,一旦它跳起来一点点一分钟。当我击中保存按钮一点,这样其明显的是什么原因造成它浸前在时间轴上的面积。该DOM节点和存储都上去了。

Thats my site loaded up and left running for a bit, refreshed it at the dip and left it and you can see once a minute it jumps up a little bit. THe area on the timeline before the dip was when i was hitting the save button a bit, so its obvious what is causing it. The DOM nodes and memory both go up.

我使用的Page_Load一个ScriptManager.RegisterClientScriptBlock的(主要是为了获得控制clientID的的,所以我可以做的JavaScript总计),也是一个ScriptManager.RegisterStartupScript获取将焦点​​设置为一个局部回传后的相同。也许他们都贡献?

I'm using a ScriptManager.RegisterClientScriptBlock's (mainly to get the clientID's of controls so I can do javascript totals) and also a ScriptManager.RegisterStartupScript on page_load to get set the focus to be the same after a partial postback. Maybe they are contributing?

有没有什么工具可以帮助我进一步呢?筛报道空div的很多,当回发时正在取得?位我从未使用过滤网之前,所以也许这总是会发生?

Is there any tools that can help me out further to this? Sieve reported alot of empty divs being made when the postback occurs? bit I've never used sieve before so maybe this always happens?

是否有某种code分析我能做的,什么的,至少让我看到每次创建新的DOM节点.​​..

Is there some sort of code analysis I can do, or something that at least lets me see the new DOM nodes created each time...

我想兴田问题可能是跟在后面两轮牛车我的code做的就是客户端的ID,这将它们存储在一个数组,然后重新创建在每次回发taht阵列,也许事情错了吗?
我上传我的JS文件,这是否两轮牛车,也落后于code的情况下,有人需要更多的信息。
http://rodh.org/images/Programming/javascript.txt
http://rodh.org/images/Programming/$c$cbehind.txt

I'm thinking hte problem might be to do with my code behind hackery to get the client id's, it stores them in an array, and then recreates taht array on each postback, perhaps something is going wrong there? I've uploaded my JS file which does that hackery, and also the code behind in case anyone needs more info. http://rodh.org/images/Programming/javascript.txt http://rodh.org/images/Programming/codebehind.txt

所以我想我的问题是:
- 任何人都可以马上想到的任何东西,会导致什么呢?
- 什么是DOM增加使用上的UpdatePanel(使用Jquery太BTW)的一些常见原因
- 我可以使用什么工具来调试?

So I guess my question is: - Can anyone think of anything immediately that would be causing this? - what are some common causes of increased DOM usage on UpdatePanels (using Jquery too btw) - what tools can I use to debug?

推荐答案

我可以告诉你第一手微软知道IE的问题(的 KB 2000262 )与UpdatePanel的。它是一种DOM解析器问题。我有一阵运行得很好,直到某一页内容的大小,然后IE浏览器(所有版本)的网站。 FF等浏览器处理同样的网页提供方便。

I can tell you first hand Microsoft knows about the IE problem(KB 2000262) with UpdatePanels. Its a DOM parser issue. I had a site that ran fine up until a certain page content size and then IE(all versions) had a fit. FF and other browsers handled the same pages with ease.

事情我没有让我的网页的速度更快:

Things I did to make my pages faster:


  • 使用的UpdateMode =条件尽可能

  • 实施KB 2000262修复

<一个href=\"http://cooldotnetstuff.word$p$pss.com/2009/09/01/updatepanel-async-postsback-slow-in-ie%e2%80%a6part-3/\"相对=nofollow>的UpdatePanel异步Postsback在IE慢... 3部分

这篇关于我怎么能在我的JS /更新面板现场调试此内存使用/ DOM使用率增加的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆