Revamp Bootstrap #1495
Revamp Bootstrap #1495
Conversation
@@ -58,7 +58,37 @@ public function createService(ServiceLocatorInterface $serviceLocator) | |||
$configuration = $serviceLocator->get('ApplicationConfiguration'); | |||
$listenerOptions = new ListenerOptions($configuration['module_listener_options']); | |||
$defaultListeners = new DefaultListenerAggregate($listenerOptions); | |||
$serviceListener = new ServiceListener($serviceLocator); | |||
|
|||
$serviceConfig = array( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know this is not where this should be defined -- it will be defined in a more appropriate location.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where are you thinking of putting it instead? I'm not 100% against this, tbh, particularly since you can specify an alternate ModuleManager factory in the application config.
Fix EventManagerAwareInterface so that it does not force injection of a new event manager if one already exists. - can you provide this bugfix as separated PR, please? So this one can get merged into master already. |
Thanks. For the rest, looks good to me! :-) |
@@ -19,7 +19,7 @@ | |||
* @category Zend | |||
* @package Zend_Module | |||
*/ | |||
interface ModuleManagerInterface extends EventManagerAwareInterface, EventsCapableInterface | |||
interface ModuleManagerInterface extends EventManagerAwareInterface |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't forget to remove "use Zend\EventManager\EventsCapableInterface;"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done, thanks.
I personally am +1 to this, once rebased. ;-) I'm not sure how much discussion we need to make the change -- but it'd be great to get this in for beta5. |
beta5 is coming... ;-) |
…epenency between ModuleManager and Configuration
Also no need to md5() the service manager keys in ServiceListener.
This will enable us to provide useful debugging tools in regards to config merging.
This allows for overridding the few "core" services that are configured by default by the MVC stack for those who really need to override them.
I think this is ready to be reviewed. I'm still not completely happy with where I stuck the default service configuration (in the ModuleManagerFactory as a property), but that's an implementation detail that does not affect the public API. Travisbot should be commenting wit the build status shortly. |
Fixing Zend\View tests now... |
This is useful for unit testing. Edited Zend\View\Helper\Navigation\AbstractTest to use this.
- Removes the loadModules.pre event - Adds a loadModules event - Use constants for event names to match Zend\Mvc - All work contained within listeners now Listeners that need to do things after modules are loaded, but do some work that modules should be able to assume is complete in loadModules.post should attach to the loadModules event with a negative priority.
I love you, @travisbot. |
Goals / features of this PR:
index.php after this PR:
Please merge ZendSkeletonApplication PR #82 after this.