nqkk58 发表于 2024-10-6 09:41:10

WordPress 5/6 性能大退步(附 AB性能测试数据)


    <p style="font-size: 16px; color: black; line-height: 40px; text-align: left; margin-bottom: 15px;">WordPress自引入古腾堡之后,性能全方面大退步。笔者在本地利用Apache新能测试(俗<span style="color: black;">叫作</span> AB 测试)做了对比。测试站点数据如下:<span style="color: black;">文案</span>内容不超过50篇,且均已开启 opcache。</p>
    <h1 style="color: black; text-align: left; margin-bottom: 10px;">WordPress 6 原生性能</h1>
    <p style="font-size: 16px; color: black; line-height: 40px; text-align: left; margin-bottom: 15px;">在windows xampp<span style="color: black;">研发</span>环境下,<strong style="color: blue;">默认wp 6 的并发性能居然<span style="color: black;">仅有</span>30<span style="color: black;">上下</span></strong>:</p>
    <div style="color: black; text-align: left; margin-bottom: 10px;"><img src="https://p3-sign.toutiaoimg.com/tos-cn-i-qvj2lq49k0/11b8fc54aa4a427dad37cb4464ba74c9~noop.image?_iz=58558&amp;from=article.pc_detail&amp;lk3s=953192f4&amp;x-expires=1728357757&amp;x-signature=3vcdJMxVCq9evH2U7Tdv1jvF124%3D" style="width: 50%; margin-bottom: 20px;"></div>
    <h1 style="color: black; text-align: left; margin-bottom: 10px;">WordPress 6 启用 wnd-frontend 插件加速版性能</h1>
    <p style="font-size: 16px; color: black; line-height: 40px; text-align: left; margin-bottom: 15px;">笔者自己<span style="color: black;">研发</span>的插件 wnd-frontend 中内置加速功能,原理<span style="color: black;">便是</span>重写wp-setting.php文件,移除古腾堡等文件加载。【<span style="color: black;">重视</span>从加载层面移除,并非<span style="color: black;">经过</span><span style="color: black;">各样</span>钩子禁用】。启用插件的加速后,<span style="color: black;">咱们</span>看到<strong style="color: blue;">性能得到了<span style="color: black;">很强</span>幅度的<span style="color: black;">提高</span>,并发达到132</strong>,<span style="color: black;">实质</span>上<span style="color: black;">亦</span><span style="color: black;">便是</span>基本恢复到wp4的性能。</p>
    <div style="color: black; text-align: left; margin-bottom: 10px;"><img src="https://p26-sign.toutiaoimg.com/tos-cn-i-qvj2lq49k0/033e3ff0c5584147a102916a8f9e46b8~noop.image?_iz=58558&amp;from=article.pc_detail&amp;lk3s=953192f4&amp;x-expires=1728357757&amp;x-signature=pvjP0A6c0Nef7BCQutLO7d8qh9Y%3D" style="width: 50%; margin-bottom: 20px;"></div>
    <p style="font-size: 16px; color: black; line-height: 40px; text-align: left; margin-bottom: 15px;">笔者<span style="color: black;">始终</span>是相当反对古腾堡的,并不仅是这种<span style="color: black;">所说</span>的编辑器对笔者<span style="color: black;">这般</span>的<span style="color: black;">研发</span>者<span style="color: black;">来讲</span>,毫无用处,更<span style="color: black;">重点</span>的是它严重拖慢了wp的速度,<span style="color: black;">经过</span><span style="color: black;">实质</span>数据测试,<span style="color: black;">咱们</span>验证了这一观点。</p>
    <h1 style="color: black; text-align: left; margin-bottom: 10px;">笔者基于 WP 设计模式 原创 CMS性能</h1>
    <p style="font-size: 16px; color: black; line-height: 40px; text-align: left; margin-bottom: 15px;"><span style="color: black;">做为</span>一个从 08年<span style="color: black;">起始</span><span style="color: black;">运用</span>wp,目睹wp官方<span style="color: black;">研发</span>团队将<span style="color: black;">将来</span>的几年计划全都集中在古腾堡编辑器后,<span style="color: black;">亦</span>感到心灰意冷,虽然<span style="color: black;">日前</span><span style="color: black;">经过</span>自己的插件还能做好加速。于是从年初就<span style="color: black;">起始</span>构造自己的cms系统,而这套系统<span style="color: black;">亦</span>正是基于wp的基本框架,只是做了<span style="color: black;">海量</span>代码重构和精简,虽然<span style="color: black;">日前</span>还有较多用户权限,模板函数方面尚未完工,但基本的内容内容读写增删改等功能,均已完成,<strong style="color: blue;">实测并发达到 329</strong>,附上测试数据:</p>
    <div style="color: black; text-align: left; margin-bottom: 10px;"><img src="https://p3-sign.toutiaoimg.com/tos-cn-i-qvj2lq49k0/1cf2f2b002f74096be60151239f335eb~noop.image?_iz=58558&amp;from=article.pc_detail&amp;lk3s=953192f4&amp;x-expires=1728357757&amp;x-signature=VImAl%2F1zyrJdvU3T8O1irZ6tHRA%3D" style="width: 50%; margin-bottom: 20px;"></div>




wrjc1hod 发表于 2024-10-8 04:44:32

感谢您的精彩评论,为我带来了新的思考角度。

wrjc1hod 发表于 2024-10-23 08:41:59

“BS”(鄙视的缩写)‌
页: [1]
查看完整版本: WordPress 5/6 性能大退步(附 AB性能测试数据)