Skip to content
This repository was archived by the owner on Jan 29, 2020. It is now read-only.

Commit 52f0d80

Browse files
committed
Remove zend-hydrator dependency
As of zend-hydrator 2.2.0, the component now exposes its own hydrator plugin manager factory and wires it with the zend-modulemanager `ServiceListener`; it no longer is a requirement of zend-mvc.
1 parent 9677140 commit 52f0d80

File tree

8 files changed

+32
-99
lines changed

8 files changed

+32
-99
lines changed

composer.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@
2525
},
2626
"require-dev": {
2727
"zendframework/zend-form": "^2.7",
28-
"zendframework/zend-hydrator": "^1.1 || ^2.1",
2928
"zendframework/zend-inputfilter": "^2.6",
3029
"zendframework/zend-json": "^2.6.1 || ^3.0",
3130
"zendframework/zend-log": "^2.7.1",

composer.lock

Lines changed: 15 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

doc/book/migration/to-v3-0.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,23 @@ $ composer require zendframework/zend-filter
117117
Note: the above assumes you have already installed zend-component-installer, per
118118
the section above on [dependency reduction](#dependency-reduction).
119119

120+
## Hydrator integration
121+
122+
In version 2, zend-mvc exposed a `HydratorManager` service by default, and
123+
provided specifications to zend-modulemanager's `ServiceListener`
124+
to allow modules to provide hydrator configuration.
125+
126+
This functionality is now removed from zend-mvc. It is now exposed directly by
127+
the [zend-hydrator](https://zendframework.github.io/zend-hydrator/) component
128+
itself. To add it, install zend-hydrator:
129+
130+
```bash
131+
$ composer require zendframework/zend-hydrator
132+
```
133+
134+
Note: the above assumes you have already installed zend-component-installer, per
135+
the section above on [dependency reduction](#dependency-reduction).
136+
120137
## i18n integration
121138

122139
Internationalization tooling, including:

src/Service/HydratorManagerFactory.php

Lines changed: 0 additions & 17 deletions
This file was deleted.

src/Service/ModuleManagerFactory.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -79,12 +79,6 @@ public function __invoke(ContainerInterface $container, $name, array $options =
7979
'Zend\ModuleManager\Feature\RouteProviderInterface',
8080
'getRouteConfig'
8181
);
82-
$serviceListener->addServiceManager(
83-
'HydratorManager',
84-
'hydrators',
85-
'Zend\ModuleManager\Feature\HydratorProviderInterface',
86-
'getHydratorConfig'
87-
);
8882
$serviceListener->addServiceManager(
8983
'InputFilterManager',
9084
'input_filters',

src/Service/ServiceListenerFactory.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@ class ServiceListenerFactory implements FactoryInterface
7676
'HttpMethodListener' => 'Zend\Mvc\Service\HttpMethodListenerFactory',
7777
'HttpRouteNotFoundStrategy' => HttpRouteNotFoundStrategyFactory::class,
7878
'HttpViewManager' => 'Zend\Mvc\Service\HttpViewManagerFactory',
79-
'HydratorManager' => 'Zend\Mvc\Service\HydratorManagerFactory',
8079
'InjectTemplateListener' => 'Zend\Mvc\Service\InjectTemplateListenerFactory',
8180
'InputFilterManager' => 'Zend\Mvc\Service\InputFilterManagerFactory',
8281
'LogProcessorManager' => 'Zend\Mvc\Service\LogProcessorManagerFactory',

test/Service/HydratorManagerFactoryTest.php

Lines changed: 0 additions & 32 deletions
This file was deleted.

test/Service/TestAsset/CustomForm.php

Lines changed: 0 additions & 31 deletions
This file was deleted.

0 commit comments

Comments
 (0)