dsapkqaduj6718493 2010-01-29 13:56 采纳率: 100%
浏览 24
已采纳

是否有可用于计算MediaWiki文章创建时间的钩子?

I want to time how long it takes the server to build a MediaWiki article. That is, the start time will be as close as possible to the time the server receives the request (not the time the client issues request). The end time will be when the server sends the page (again, not when the client receives the page).

Is there any Apache function I can access from PHP that gives me the time it took for the server to build the page?

Is there a MediaWiki hook that I can use to determine the static server time as early in the article-building process as possible? This looks promising but is for a future version of MediaWiki. I know I can determine the server time at the end of page creation. With those two times, I can generate a delta.

Thanks.

==Appended=== I've just discovered "mod_headers" (http://prefetch.net/blog/index.php/2007/01/02/measuring-apache-request-processing-time/) and its ability to create a header with the time it took to serve the request, in microseconds. However, I do not know how I could use that information since javascript cannot read it. I would love to be able to send it back to my server via AJAX and log it.

  • 写回答

1条回答 默认 最新

  • douken1726 2010-01-29 15:25
    关注

    This information is embedded in every page MediaWiki generates - look for something like:

    Served in 0.770 secs

    in the HTML source. Is this not what you're looking for?

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 计组这些题应该咋做呀
  • ¥60 更换迈创SOL6M4AE卡的时候,驱动要重新装才能使用,怎么解决?
  • ¥15 让node服务器有自动加载文件的功能
  • ¥15 jmeter脚本回放有的是对的有的是错的
  • ¥15 r语言蛋白组学相关问题
  • ¥15 Python时间序列如何拟合疏系数模型
  • ¥15 求学软件的前人们指明方向🥺
  • ¥50 如何增强飞上天的树莓派的热点信号强度,以使得笔记本可以在地面实现远程桌面连接
  • ¥20 双层网络上信息-疾病传播
  • ¥50 paddlepaddle pinn