File tree Expand file tree Collapse file tree 1 file changed +22
-7
lines changed Expand file tree Collapse file tree 1 file changed +22
-7
lines changed Original file line number Diff line number Diff line change @@ -25,9 +25,21 @@ xdebug.client_port=9084
2525
2626[apcu]
2727; 虽然手册里写的默认开启[2025-09-10],但实测时 apcu-5.1.27 版本默认是禁用的
28- apc .enabled =1
28+ apcu .enabled =1
2929; 为 CLI 版本的PHP启用APC,主要用于测试和调试
3030apc.enable_cli =1
31+
32+ ; 开发环境配置
33+ apcu.shm_size =64M
34+ apcu.stat =1 ; 开发时开启文件检查
35+ apcu.ttl =300 ; 短时间缓存,便于调试
36+
37+ ; 生产环境配置
38+ ; apcu.shm_size=256M
39+ ; apcu.stat=0 ; 关闭状态检查提升性能
40+ ; apcu.ttl=7200 ; 长时间缓存
41+ ; apcu.slam_defense=1 ; 防止缓存击穿
42+
3143```
3244
3345``` bash [测试扩展]
@@ -70,18 +82,21 @@ make install
7082```
7183
7284``` ini [配置参考]
73- ; 开发环境配置
85+ ; 虽然手册里写的默认开启[2025-09-10],但实测时 apcu-5.1.27 版本默认是禁用的
7486apcu.enabled =1
87+ ; 为 CLI 版本的PHP启用APC,主要用于测试和调试
88+ apc.enable_cli =1
89+
90+ ; 开发环境配置
7591apcu.shm_size =64M
7692apcu.stat =1 ; 开发时开启文件检查
7793apcu.ttl =300 ; 短时间缓存,便于调试
7894
7995; 生产环境配置
80- apcu.enabled =1
81- apcu.shm_size =256M
82- apcu.stat =0 ; 关闭状态检查提升性能
83- apcu.ttl =7200 ; 长时间缓存
84- apcu.slam_defense =1 ; 防止缓存击穿
96+ ; apcu.shm_size=256M
97+ ; apcu.stat=0 ; 关闭状态检查提升性能
98+ ; apcu.ttl=7200 ; 长时间缓存
99+ ; apcu.slam_defense=1 ; 防止缓存击穿
85100```
86101
87102:::
You can’t perform that action at this time.
0 commit comments