Confluence 6 识别慢性能的宏

Page Profiling 给你了有关页面在载入的时候操作缓慢的邪教,你可以将下面的内容添加到调试(debug)级别:

Version 3.1 及其后续版本

设置包名字为 com.atlassian.renderer.v2.components.MacroRendererComponent 到 DEBUG 级别。你可以在 管理(Administration) >> Logging and Profiling 中进行设置。

3.1 之前的版本

下载 WikiMarkupParser.class,你可以在 attachments to this page 页面中找到,生成的日志结果如下:

2009 - 04 - 23  10 : 27 : 54 , 789  DEBUG [http- 8080 - 1 ] [atlassian.renderer.v2.WikiMarkupParser] parse Entering macro rendering. Processed text: {spaces}
2009 - 04 - 23  10 : 27 : 55 , 768  DEBUG [http- 8080 - 1 ] [atlassian.renderer.v2.WikiMarkupParser] parse Exiting macro text rendering. Total time: 979ms
2009 - 04 - 23  10 : 27 : 55 , 785  DEBUG [http- 8080 - 1 ] [atlassian.renderer.v2.WikiMarkupParser] parse Entering macro rendering. Processed text: {create-space-button}
2009 - 04 - 23  10 : 27 : 55 , 857  DEBUG [http- 8080 - 1 ] [atlassian.renderer.v2.WikiMarkupParser] parse Exiting macro text rendering. Total time: 72ms
2009 - 04 - 23  10 : 27 : 55 , 862  DEBUG [http- 8080 - 1 ] [atlassian.renderer.v2.WikiMarkupParser] parse Entering macro rendering. Processed text: {recently-updated-dashboard:dashboard|showProfilePic= true }
2009 - 04 - 23  10 : 27 : 56 , 704  DEBUG [http- 8080 - 1 ] [atlassian.renderer.v2.WikiMarkupParser] parse Exiting macro text rendering. Total time: 842ms
2009 - 04 - 23  10 : 27 : 56 , 707  DEBUG [http- 8080 - 1 ] [atlassian.renderer.v2.WikiMarkupParser] parse Entering macro rendering. Processed text: {favpages:maxResults= 10 }
2009 - 04 - 23  10 : 27 : 56 , 889  DEBUG [http- 8080 - 1 ] [atlassian.renderer.v2.WikiMarkupParser] parse Exiting macro text rendering. Total time: 182ms

希望添加类:

  1. 添加下面的行到文件 <confluence-install>/confluence/WEB-INF/classes/log4j.properties 中:
    log4j.logger.com.atlassian.renderer=DEBUG
  2. 添加正确的 WikiMarkupParser.class 到 /confluence/WEB-INF/classes/com/atlassian/renderer/v2。你需要手动创建 renderer 和 v2 文件夹。

在页面属性合并中,这个配置应该能够给你在页面载入的时候那些插件消耗了最多的世界。你也可以使用这个工具来找到你的 Confluence 使用了那些宏: How to Search Confluence for Uses of a Macro

结论

结合 performance tuning 页面中提供的技巧,或者打开指定宏的提高请求。在一些情况下,可能没有系统性能的结论 —— 你需要避免对过多的宏进行日志。

 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值