調(diào)試到這一步,解析控制器的時(shí)候卡住了好久
執(zhí)行php start.php status結(jié)果;沒(méi)有報(bào)錯(cuò)
我試了一下自己的第一次啟動(dòng)請(qǐng)求,在瀏覽器里看到的等待時(shí)間:
不連數(shù)據(jù)庫(kù)大概600~900毫秒,
連數(shù)據(jù)庫(kù)大概1000~2000毫秒
第二次以后就比較快了,基本在50~80毫秒左右。但如果長(zhǎng)時(shí)間不請(qǐng)求再次請(qǐng)求就又是600多毫秒。
我的環(huán)境是windows使用wsl2安裝Ubuntu20,php8.1。
如果不使用wsl,直接windows上運(yùn)行就非???,基本是個(gè)位數(shù)的響應(yīng)時(shí)間。
php start.php status顯示的響應(yīng)實(shí)際是挺快的:
Workerman version:4.0.37 PHP version:8.1.6
start time:2022-05-26 15:27:02 run 0 days 0 hours
load average: 0.15, 0.45, 0.5 event-loop:\Workerman\Events\Select
2 workers 17 processes
worker_name exit_status exit_count
webman 0 0
monitor 0 0
----------------------------------------------PROCESS STATUS---------------------------------------------------
pid memory listening worker_name connections send_fail timers total_request qps status
18584 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18585 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18586 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18587 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18588 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18589 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18590 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18591 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18592 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18593 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18594 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18595 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18596 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18597 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18598 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18599 3.35M http://0.0.0.0:8787 webman 0 0 1 0 0 [idle]
18600 2.94M none monitor 0 0 2 0 0 [idle]
----------------------------------------------PROCESS STATUS---------------------------------------------------
Summary 50M - - 0 0 18 0 0 [Summary]
今天裝了strace測(cè)試了,好像一直在跑
lstat("/www/order-webman/app/vue3/node_modules/element-plus/dist/locale/sr.min.mjs", {st_mode=S_IFREG|0777, st_size=4688, ...}) = 0