我对应用程序的响应时间有一些抱怨,所以我正在研究哪些方面可以加快速度。使用分析阶段监听器和一些分析包装器,我希望找到一些需要缓存的东西。然而,情况似乎并非如此。典型的示例运行看起来像这样:
Controller>afterRestoreView completed in 0:00.000.044769
PhaseProfiler>LIFECYCLE>RESTORE_VIEW completed in 0:00.017.090231
PhaseProfiler>LIFECYCLE>APPLY_REQUEST_VALUES completed in 0:00.012.076884
PhaseProfiler>LIFECYCLE>PROCESS_VALIDATIONS completed in 0:00.003.804324
PhaseProfiler>LIFECYCLE>UPDATE_MODEL_VALUES completed in 0:00.002.898762
PhaseProfiler>LIFECYCLE>INVOKE_APPLICATION completed in 0:00.000.113143
Controller>beforeRenderResponse completed in 0:00.000.012222
Controller>afterRenderResponse completed in 0:00.000.003143
Counted resolves: 4975
Top ten most expensive resolves:
Total took a total of 0:00.020.281386s
flashScope took a total of 0:00.006.770973s
caseBean took a total of 0:00.004.517358s
caseFilter took a total of 0:00.003.038453s
row took a total of 0:00.001.741708s
session took a total of 0:00.001.026528s
compositeData took a total of 0:00.000.983215s
uiService took a total of 0:00.000.641919s
requestScope took a total of 0:00.000.391530s
options took a total of 0:00.000.176558s
PhaseProfiler>LIFECYCLE>RENDER_RESPONSE completed in 0:02.900.494895
PhaseProfiler>LIFECYCLE completed in 0:02.936.944360
因此RenderResponse中的内容大约需要2.9秒,但它不是我的事件处理程序,它不是我的变量绑定。使用System.nanoTime并不是完全相同的,但与System.currentTimeMillis相比,它似乎增加了大约一秒或更少,所以我仍然缺少相当多的时间。我只能占不到21毫秒。
是否有深入挖掘的技术?
答案 0 :(得分:3)
使用此项目:https://www.openntf.org/main.nsf/project.xsp?r=project/XPages%20Toolbox
虽然我无法让代理在R9上运行,但它的CPU分析器做得很好。它可以查明特定SSJS,Java方法或Notes API调用的瓶颈。强烈推荐。