-
Notifications
You must be signed in to change notification settings - Fork 142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Getting worse performance with save_comments = 0 and enable_file_override = 1 #64
Comments
hi Ricard, Thank you for the post and good bechmarks :) I've never worked with Symphony myself, but already got few reports, that it doesn't work properly with save_comments=0. This option disables saving/loading doc_coments that used in Symphony for some purpose. enable_file_override=1 may make speedup or slowdown dependent on application. It speedups file_exists(), is_file() and is_readable() for files cached by O+, but makes them a bit slower for the others. Thanks. Dmitry. |
Hi Dimitry Well, Symfony2 uses annotations /comments as one of the ways you can configure your application. There is a CLI command that converts these annotations / comments into plain PHP and of course with save_comments = 0, this just does not work as it is perfectly explained in your documentation. However, once the cache is warmed up, Symfony2 works perfectly :) Regarding enable_file_override... well it might slow down the first request, but not the subsequents right? Symfony2 uses a lot of files and it may slow down autoload the first time, but not the following ones if I understand properly what you mean. Weird indeed! Any other guesses about what might be slowing down the HTTP responses? |
Well, Symfony2 uses annotations /comments as one of the ways you can
No. It may speedup or slowdown not only the first request, but every |
Sorry I may have not explained myself properly about how Symfony deals with annotations and how I did the test. What I did was to set save_comments to 1, warm the cache (annotations are read) set save_comments back to 0, reload apache config and execute ab (once the cache is warm, Symfony does not read annotations any more). So for HTTP requests save_comments was set to 0 But what might explain performance decrease is what you say about enable_file_override, specially if it happens at run time as you mention Thanks for clarifying all this stuff El 15/03/2013, a les 21:56, Dmitry Stogov notifications@github.com va escriure:
|
In case files were already saved with doc comments, the save_comments value Dmitry. On Saturday, March 16, 2013, Ricard Clau wrote:
|
Restarting Apache does not reset Zend Optimizer+? If not, how can this cache be restarted? |
Of course, it resets O+. |
Hi
Some days ago I did some performance tests with a Hello world built up with Symfony2 framework. You can see some metrics here http://www.ricardclau.com/2013/03/apc-vs-zend-optimizer-benchmarks-with-symfony2/
While most of the results were consistent and of course faster than APC those two settings led to worse performance than letting them default values.
I've repeated the test several times on my machine (to discard eventual CPU exhausting processes) and it always gives less performance (about 10%).
I'm using MacOsX, PHP 5.4.12 and I git cloned about 10 days ago.
Might it be an issue with MacOsX? Maybe with Symfony2?
Comments or hints appreciated!
The text was updated successfully, but these errors were encountered: