How much does using htaccess files slow down website performance (especially with solid state disks)?

后端 未结 6 1013
盖世英雄少女心
盖世英雄少女心 2020-12-15 04:38

The Apache docs say (http://httpd.apache.org/docs/2.4/howto/htaccess.html),

\"You should avoid using .htaccess files completely if you have access t

6条回答
  •  时光说笑
    2020-12-15 05:23

    From an answer on Quora by Jonathan Klein, 12ms for a 1500 line .htaccess file:

    Having a large .htaccess does have a cost. Ours is currently ~1500 lines and we benchmarked the time spent parsing it at around 10-12ms on a production webserver. Hardware makes a difference obviously, but you can fairly safely assume that the cost of that 3000 line .htaccess is around 25-35ms per request.

提交回复
热议问题