用于分析 GWT 应用程序的工具
我有相当大的 GWT 应用程序。在多个 Firefox 选项卡中打开,它会占用大量内存。第一个待办事项是尽量减少 UI 中创建的小部件数量。
您使用什么工具来控制应用程序的内存使用、在页面中显示多个小部件或进行常规分析?
I got rather large GWT application. Opened in several Firefox tabs, it eats huge amount of memory. The first ToDo thing is to minimize number of widgets created in UI.
What instruments do you use to control memory usage of application, show a number of widgets in the page or do general profiling?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我不知道现在有什么工具可以对 Javascript 应用程序进行内存分析,但希望有人可以纠正我。
至于一般分析,我使用 Firefox Firebug 插件,当我需要准确了解 Internet Explorer 如何让我失败时, IE8 开发人员工具栏 还有一个很好的分析器。这两个都可以让您查看方法调用以及在各个区域花费的时间量。两者还允许您遍历 DOM 以了解当前附加的数量。
我强烈建议使用“漂亮的”GWT 选项编译您的应用程序,否则分析器将显示许多混淆的方法名称,这在您隔离热点时不会有太大帮助。我在这里闲聊了一些但要小心在托管模式下在应用程序上运行 Java 分析器。如果您遇到算法问题,它们可能会出现在那里,但 Javascript 引擎往往会以与 JVM 不同的方式进行优化。
I do not know of any tools that will do memory profiling of a Javascript application right now, but hopefully someone can correct me.
As for general profiling, I use the Firefox Firebug plugin and when I need to see exactly how Internet Explorer is failing me, the IE8 developer toolbar also has a good profiler. Both of these let you see method calls and the amount of time spent in various areas. Both also let you traverse the DOM to get an idea of how much you currently have attached.
I highly recommend compiling your application with the 'pretty' GWT option otherwise the profilers will show a number of obfuscated method names which won't help you overly much when you do isolate hotspots. I rambled a little bit about it here but be wary of running a Java profiler on your application in hosted mode. If you have algorithmic problems, they might turn up there, but Javascript engines tend to be optimized in different ways than the JVM.