Xampp上的Symfony开发速度很慢,我该怎么办? [英] Symfony on Xampp is very slow in development, what can I do?

查看:104
本文介绍了Xampp上的Symfony开发速度很慢,我该怎么办?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经设置了Symfony,但是每次加载页面都需要40秒。

I have set up Symfony but every page load requires 40 seconds.

如果我的控制器为空,则需要8秒钟的加载时间。如果我开始对数据库进行一些复杂的查询,那就更糟了。我该怎么办?

If I have an empty controller it takes 8 seconds to load. If I start to make some complex queries on the database, it's worse. What can I do?


  • 停用分析器? (这会改变很多吗?)

  • 在开发人员模式下激活APC吗? (但这不是更改代码的问题)

  • 将会话放入APC内吗?

  • 将学说放入垃圾箱?
  • >
  • ....?

  • deactivate the profiler? (will this change a lot?)
  • activate APC on dev mode? (but will this not be a problem for changing the code)
  • put the session inside APC?
  • put Doctrine in the garbage?
  • .... ?

我真的不知道从哪里开始。

I don't really know where to start.

(我正在将Windows 7与Xampp服务器和8g的ram一起使用)

(I am using Windows 7 with Xampp server and 8gb of ram)

推荐答案

一些快速的建议:


  • 安装PHP 5.5.x(更快

  • 使用 mod_fcgid 代替 mod_php 与Apache

  • 提高<$您的 php.ini
  • 中的c $ c> realpath_cache_size 和 realpath_cache_ttl
  • disable XDebug

  • ...

  • install PHP 5.5.x (faster)
  • Use mod_fcgid instead of mod_php with Apache
  • Raise realpath_cache_size and realpath_cache_ttl in your php.ini
  • disable XDebug
  • ...

请参见这个问题此问题这个问题

这篇关于Xampp上的Symfony开发速度很慢,我该怎么办?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆