
I would like to share some impressions about some of the products of Zend ltd. Very pleased that now they are not only The PHP Company, but also manufacturers of related products. Previously, I, as well as, perhaps, a large part of me, sat on Zend Studio 5.5, as it successfully coped with all that was required of it, but the tasks in it were solved mostly for one developer, despite the “friendly team” . In principle, nothing but codefolding and syntax highlighting was required, all sorts of templates, such as foreach and information about functions / arguments, etc., obtained from DocBlock, as well as their convenient creation were very useful. SVN was used as a backup and didn’t interact from IDE, but recently switched to Zend Studion 7.0, which is more and more pleased every day, yes there are a lot of minuses, and sometimes hangs due to project analysis, unusual hot keys, etc. but it's all customizable.

Just want to note if you do not need a comprehensive solution to all problems - use the editor you like, if you want to apply any new development methods - feel free to put Zend Studio 7.0 and experiment from time to time, as a result, after a while will give its fruits.
One of the drawbacks is that it is not very convenient to work with a small resolution on a non-widescreen monitor, but this problem is solved by maximizing the active panel (Ctrl + M). The next problem you may encounter is wizards, at first it may not be clear what wizard is required for, but having dealt with them you will be able to speed up the development process, even the same templates will serve very well for the same purposes.
Now, what I still wanted to say - this is a real integration of the IDE and the server out of the box (php + web server + database). You do not need to edit configs to fix something in the settings, of course, third-party extensions will need to be connected manually, but most of the basic operations are conveniently done through the web interface. So, along with Zend Server, Zend Controller is installed which sometimes can be played.
')
In order to integrate Zend Server and Zend Studio, you need to first start Server, then studio and accept the integration in the pop-up window and enter the password (this is if you have a Zend Server locally). After that, you can immediately begin to more constructive debugging, tracing and profiling. For example, a couple of application images on the Zend Framework (by the way, the corresponding perspective displays the MVC panel in which models / views / controllers are displayed neatly)

This illustration shows that the preparation (bootstraping) of an application takes up 46% of the operating time, and this is mainly a parsing of configuration files and the creation of appropriate objects that are the same ... time and again there is a real lack of hashing for this whole thing, though in the example almost all resources are available by default, there are 11 of them. “Useful actions” - read dispatching takes only 27% of the time, which looks just disgusting, that is, 3/4 of the execution time is spent on the same uniform in most cases actions.
The following image shows the same report, but from a different tab in the form of a pie chart:
From here we once see that the new loader, although very convenient, is the first victim to be shot. Even in the debugging perspective, there is a panel with a console, which also helps you find conflicting places, in my case - the loader tries to load resources and view assistants from user paths, and not / library / Zend, plus reports on file accesses - the amount spent time, processed lines, missing lines and the entire lines of code in the file, see for yourself - I promise it will be interesting. The URL was profiled. There is no time to try any other possibilities, there will be something new in the future, perhaps we will consider working with Zend Debuger in more detail.
PS
The first illustration with Zend Controller shows the number of requests per second when accessed by the same URL as when profiling.
If someone installed PHP on the same host with simultaneous support for xDebug and Zend Debugger and experienced any difficulties, and solved them - tell about it in the comments if you find time.
It will be necessary to try to wrap Zend_Application with a standard cache for objects.
Before connecting Zend_Cache
Profile URL: | example.com |
Query: | debug_host = 192.168.1.195% 2C127.0.0.1 & debug_fastfile = 1 |
Path: | C: / Program Files / Zend / Apache2 / htdocs / example.com / htdocs / index.php |
Total Request Time: | 839.07 |
Number of Files: | 136 |
Profile Date: | Tue Jul 21 00:45:51 MSD 2009 |
/**
* index.php Zend_Application
* Autoloader,
*
*
*/
$application = new Zend_Application(
APPLICATION_ENV,
APPLICATION_PATH . DIRECTORY_SEPARATOR . 'data' . DIRECTORY_SEPARATOR . 'application.ini'
);
$application->bootstrap()->run();
* This source code was highlighted with Source Code Highlighter .
After connecting Zend_Cache
Profile URL: | example.com |
Query: | debug_host = 192.168.1.195% 2C127.0.0.1 & debug_fastfile = 1 |
Path: | C: / Program Files / Zend / Apache2 / htdocs / emample.com / htdocs / index.php |
Total Request Time: | 636.28 |
Number of Files: | 89 |
Profile Date: | Tue Jul 21 00:33:55 MSD 2009 |
/**
* index.php Zend_Application
* Autoloader,
*
*
*/
$frontendOptions = array(
'cached_entity' => new Zend_Application(
APPLICATION_ENV,
APPLICATION_PATH . DIRECTORY_SEPARATOR . 'data' . DIRECTORY_SEPARATOR . 'application.ini'
)
);
$backendOptions = array(
'cache_dir' => APPLICATION_CACHE,
'hashed_directory_level' => 2
);
$cache = Zend_Cache::factory( 'Class' , 'File' , $frontendOptions, $backendOptions);
$cache->bootstrap();
$cache->run();
/**
* : . .:
* $cache->bootstrap()->run();
*
* . :
* Debug Error:
* C:\Program Files\Zend\ZendServer\share\ZendFramework\library\Zend\Application\Bootstrap\Bootstrap.php
* line 69 - Call to a member function getDefaultModule() on a non-object
*/
* This source code was highlighted with Source Code Highlighter .
Findings:
Using Zend Studio in conjunction with Zend Server made it possible to optimize the application in an hour (from the beginning of writing the article - creating screenshots, typing, formatting, a couple of mobile calls) by an average of a quarter: the runtime was reduced by 24%, the number of connected files - by 34% . Of course, there may be some subtle points or potential problems, but this problem is covered by the use of unit testing.
PPS:
Upon detailed consideration, it turned out that everything is cached tightly, which in principle was suspected, but in the same way you can still optimize the process of preparing the application by expanding the Zend_Application class and adding the necessary logic.
And now the correct conclusion - you need to sleep at night.