<span id="mktg5"></span>

<i id="mktg5"><meter id="mktg5"></meter></i>

        <label id="mktg5"><meter id="mktg5"></meter></label>
        最新文章專(zhuān)題視頻專(zhuān)題問(wèn)答1問(wèn)答10問(wèn)答100問(wèn)答1000問(wèn)答2000關(guān)鍵字專(zhuān)題1關(guān)鍵字專(zhuān)題50關(guān)鍵字專(zhuān)題500關(guān)鍵字專(zhuān)題1500TAG最新視頻文章推薦1 推薦3 推薦5 推薦7 推薦9 推薦11 推薦13 推薦15 推薦17 推薦19 推薦21 推薦23 推薦25 推薦27 推薦29 推薦31 推薦33 推薦35 推薦37視頻文章20視頻文章30視頻文章40視頻文章50視頻文章60 視頻文章70視頻文章80視頻文章90視頻文章100視頻文章120視頻文章140 視頻2關(guān)鍵字專(zhuān)題關(guān)鍵字專(zhuān)題tag2tag3文章專(zhuān)題文章專(zhuān)題2文章索引1文章索引2文章索引3文章索引4文章索引5123456789101112131415文章專(zhuān)題3
        問(wèn)答文章1 問(wèn)答文章501 問(wèn)答文章1001 問(wèn)答文章1501 問(wèn)答文章2001 問(wèn)答文章2501 問(wèn)答文章3001 問(wèn)答文章3501 問(wèn)答文章4001 問(wèn)答文章4501 問(wèn)答文章5001 問(wèn)答文章5501 問(wèn)答文章6001 問(wèn)答文章6501 問(wèn)答文章7001 問(wèn)答文章7501 問(wèn)答文章8001 問(wèn)答文章8501 問(wèn)答文章9001 問(wèn)答文章9501
        當(dāng)前位置: 首頁(yè) - 科技 - 知識(shí)百科 - 正文

        MixPHP、Yii和CodeIgniter的并發(fā)壓力測(cè)試小結(jié)實(shí)例分享

        來(lái)源:懂視網(wǎng) 責(zé)編:小采 時(shí)間:2020-11-27 20:05:46
        文檔

        MixPHP、Yii和CodeIgniter的并發(fā)壓力測(cè)試小結(jié)實(shí)例分享

        MixPHP、Yii和CodeIgniter的并發(fā)壓力測(cè)試小結(jié)實(shí)例分享:MixPHP 是一個(gè)基于 Swoole 的高性能框架,CodeIgniter 是一個(gè)元老級(jí)的輕量級(jí)框架,Yii 是一個(gè)非常流行的框架。本文主要給大家介紹了關(guān)于MixPHP、Yii和CodeIgniter的并發(fā)壓力測(cè)試的相關(guān)資料,文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的
        推薦度:
        導(dǎo)讀MixPHP、Yii和CodeIgniter的并發(fā)壓力測(cè)試小結(jié)實(shí)例分享:MixPHP 是一個(gè)基于 Swoole 的高性能框架,CodeIgniter 是一個(gè)元老級(jí)的輕量級(jí)框架,Yii 是一個(gè)非常流行的框架。本文主要給大家介紹了關(guān)于MixPHP、Yii和CodeIgniter的并發(fā)壓力測(cè)試的相關(guān)資料,文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的

        MixPHP 是一個(gè)基于 Swoole 的高性能框架,CodeIgniter 是一個(gè)元老級(jí)的輕量級(jí)框架,Yii 是一個(gè)非常流行的框架。本文主要給大家介紹了關(guān)于MixPHP、Yii和CodeIgniter的并發(fā)壓力測(cè)試的相關(guān)資料,文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)學(xué)習(xí)吧。

        前言

        由于Yii/CodeIgniter 是基于 Apache/PHP-FPM 的傳統(tǒng)框架,如果使用 MixPHP 的正常 Swoole 部署方式來(lái)對(duì)比,顯得有些不公平,由于 MixPHP 同時(shí)支持在 Apache/PHP-FPM 中運(yùn)行,所以此次測(cè)試的 MixPHP 是部署在 Apache 之中。

        環(huán)境

        虛擬機(jī): 4 核,1G

        使用 ab 工具壓測(cè),命令:ab -n 5000 -c 100 URL

        Yii

        Yii 關(guān)閉了 debug,并設(shè)置為 pro 環(huán)境。

        默認(rèn)控制器代碼如下,輸出一個(gè) Hello World。

        <?php public function actionIndex() { return 'Hello World'; }

        CodeIgniter

        默認(rèn)控制器代碼如下,輸出一個(gè) Hello World。

        <?php public function index() { echo 'Hello World'; }

        MixPHP

        默認(rèn)控制器代碼如下,輸出一個(gè) Hello World。

        public function actionIndex() { return 'Hello World'; }

        開(kāi)始測(cè)試

        1、測(cè)試Yii, QPS: 56.40

        C:/Server/apache24vc11/bin>ab -n 5000 -c 100 http://www.b.com/ This is ApacheBench, Version 2.3 <$Revision: 1757674 $> Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ Licensed to The Apache Software Foundation, http://www.apache.org/ Benchmarking www.b.com (be patient) Completed 500 requests Completed 1000 requests Completed 1500 requests Completed 2000 requests Completed 2500 requests Completed 3000 requests Completed 3500 requests Completed 4000 requests Completed 4500 requests Completed 5000 requests Finished 5000 requests Server Software: Apache/2.2.32 Server Hostname: www.b.com Server Port: 80 Document Path: / Document Length: 9 bytes Concurrency Level: 100 Time taken for tests: 88.659 seconds Complete requests: 5000 Failed requests: 0 Total transferred: 1080000 bytes HTML transferred: 45000 bytes Requests per second: 56.40 [#/sec] (mean) Time per request: 1773.170 [ms] (mean) Time per request: 17.732 [ms] (mean, across all concurrent requests) Transfer rate: 11.90 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 0 1.0 1 29 Processing: 14 1765 4200.5 688 48084 Waiting: 14 1610 3741.9 682 46690 Total: 14 1766 4200.5 688 48084 WARNING: The median and mean for the initial connection time are not within a normal deviation These results are probably not that reliable. Percentage of the requests served within a certain time (ms) 50% 688 66% 1087 75% 1400 80% 1657 90% 3029 95% 7665 98% 14760 99% 24300 100% 48084 (longest request)

        2、測(cè)試 CodeIgniter , QPS: 144.42

        C:/Server/apache24vc11/bin>ab -n 5000 -c 100 http://www.c.com/ This is ApacheBench, Version 2.3 <$Revision: 1757674 $> Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ Licensed to The Apache Software Foundation, http://www.apache.org/ Benchmarking www.c.com (be patient) Completed 500 requests Completed 1000 requests Completed 1500 requests Completed 2000 requests Completed 2500 requests Completed 3000 requests Completed 3500 requests Completed 4000 requests Completed 4500 requests Completed 5000 requests Finished 5000 requests Server Software: Apache/2.2.32 Server Hostname: www.c.com Server Port: 80 Document Path: / Document Length: 8 bytes Concurrency Level: 100 Time taken for tests: 34.621 seconds Complete requests: 5000 Failed requests: 0 Total transferred: 1075000 bytes HTML transferred: 40000 bytes Requests per second: 144.42 [#/sec] (mean) Time per request: 692.419 [ms] (mean) Time per request: 6.924 [ms] (mean, across all concurrent requests) Transfer rate: 30.32 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 0 0.7 1 22 Processing: 8 689 1014.3 480 13324 Waiting: 8 686 1012.2 478 13324 Total: 9 689 1014.3 480 13325 WARNING: The median and mean for the initial connection time are not within a normal deviation These results are probably not that reliable. Percentage of the requests served within a certain time (ms) 50% 480 66% 673 75% 810 80% 902 90% 1238 95% 1808 98% 3336 99% 6037 100% 13325 (longest request)

        3、測(cè)試 MixPHP, QPS: 440.48

        C:/Server/apache24vc11/bin>ab -n 5000 -c 100 http://www.a.com/ This is ApacheBench, Version 2.3 <$Revision: 1757674 $> Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ Licensed to The Apache Software Foundation, http://www.apache.org/ Benchmarking www.a.com (be patient) Completed 500 requests Completed 1000 requests Completed 1500 requests Completed 2000 requests Completed 2500 requests Completed 3000 requests Completed 3500 requests Completed 4000 requests Completed 4500 requests Completed 5000 requests Finished 5000 requests Server Software: Apache/2.2.32 Server Hostname: www.a.com Server Port: 80 Document Path: / Document Length: 12 bytes Concurrency Level: 100 Time taken for tests: 11.351 seconds Complete requests: 5000 Failed requests: 0 Total transferred: 1025000 bytes HTML transferred: 60000 bytes Requests per second: 440.48 [#/sec] (mean) Time per request: 227.026 [ms] (mean) Time per request: 2.270 [ms] (mean, across all concurrent requests) Transfer rate: 88.18 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 1 0.9 1 25 Processing: 4 222 822.4 15 10376 Waiting: 4 221 822.4 14 10376 Total: 4 222 822.4 16 10376 Percentage of the requests served within a certain time (ms) 50% 16 66% 69 75% 214 80% 364 90% 561 95% 762 98% 978 99% 1829 100% 10376 (longest request)

        結(jié)論

        虛擬機(jī)文件IO性能太差,Yii 做300并發(fā)直接不響應(yīng),只好降低到100并發(fā)數(shù),同樣架構(gòu)的測(cè)試結(jié)果 MixPHP 領(lǐng)先。

        你也來(lái)測(cè)試一下吧,https://github.com/mixstart/mixPHP

        ITEMDESC
        Yii56.40 QPS
        CodeIgniter144.42 QPS
        MixPHP440.48 QPS

        聲明:本網(wǎng)頁(yè)內(nèi)容旨在傳播知識(shí),若有侵權(quán)等問(wèn)題請(qǐng)及時(shí)與本網(wǎng)聯(lián)系,我們將在第一時(shí)間刪除處理。TEL:177 7030 7066 E-MAIL:11247931@qq.com

        文檔

        MixPHP、Yii和CodeIgniter的并發(fā)壓力測(cè)試小結(jié)實(shí)例分享

        MixPHP、Yii和CodeIgniter的并發(fā)壓力測(cè)試小結(jié)實(shí)例分享:MixPHP 是一個(gè)基于 Swoole 的高性能框架,CodeIgniter 是一個(gè)元老級(jí)的輕量級(jí)框架,Yii 是一個(gè)非常流行的框架。本文主要給大家介紹了關(guān)于MixPHP、Yii和CodeIgniter的并發(fā)壓力測(cè)試的相關(guān)資料,文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的
        推薦度:
        標(biāo)簽: php 并發(fā) 壓測(cè)
        • 熱門(mén)焦點(diǎn)

        最新推薦

        猜你喜歡

        熱門(mén)推薦

        專(zhuān)題
        Top
        主站蜘蛛池模板: 亚洲熟女少妇一区二区| 亚洲AV无码国产剧情| 亚洲一区二区三区电影| 亚洲国产综合在线| 精品亚洲国产成人av| 夜夜爽妓女8888视频免费观看| 皇色在线免费视频| 亚欧色视频在线观看免费| 午夜私人影院免费体验区| 亚洲国产成人精品女人久久久 | 999久久久免费精品国产| 日本免费一区二区三区最新| 亚洲人成无码网站久久99热国产| 亚洲AV永久无码区成人网站| 亚洲一级毛片在线播放| 成人免费夜片在线观看| 最近中文字幕高清免费中文字幕mv| 成年美女黄网站色大免费视频| 亚洲成a人片在线观看日本麻豆| 亚洲午夜久久久精品影院| 久久精品国产亚洲av品善| 性无码免费一区二区三区在线| 免费无码又爽又刺激高潮 | 成人毛片免费网站| 久久亚洲精品无码观看不卡| 91午夜精品亚洲一区二区三区| 鲁啊鲁在线视频免费播放| 2019中文字幕免费电影在线播放 | 亚洲婷婷天堂在线综合| 未满十八私人高清免费影院| 99re热免费精品视频观看| 久久亚洲精品视频| 欧美激情综合亚洲一二区| 182tv免费视视频线路一二三 | 亚洲狠狠婷婷综合久久久久 | 中文字幕 亚洲 有码 在线| 国内精品免费久久影院| 精品久久久久久久免费人妻 | 久久www免费人成看国产片| 成人免费a级毛片无码网站入口 | 国产精品免费无遮挡无码永久视频|