Upgrading laminas/laminas-servicemanager 3 to 4
Breaking3.24.0 → 4.5.1Breaking21Platform3New5Changed6Fixed2Other16
BreakingUpgrade verdict
17 breaking changes and 3 platform requirement changes.
In plain terms
- Removes deprecated AbstractFactoryInterface, FactoryInterface, InitializerInterface and DelegatorFactoryInterface.
- Removes vendor/bin CLI commands in favor of laminas-cli integration, accessible via vendor/bin/laminas servicemanager:<command>.
- Removes deprecated ConfigInterface and Config class, which only proxied the configuration array without validation.
- Removes AbstractPluginManager#validate and $instanceOf; use AbstractSingleInstancePluginManager for single-instance plugin managers.
Must act Top 5 of 20 that need code or config changes
Adds brick/varexporter ^0.3.8 || ^0.4.0 || ^0.5.0 || ^0.6.0.
Moves psr/container ^1.0 → ^1.1 || ^2.0. Your build may pick other versions.
What you must change
Breaking17
Removes deprecated AbstractFactoryInterface, FactoryInterface, InitializerInterface and DelegatorFactoryInterface.
Laminas\ServiceManager\AbstractFactoryInterfaceLaminas\ServiceManager\FactoryInterfaceLaminas\ServiceManager\InitializerInterfaceLaminas\ServiceManager\DelegatorFactoryInterfaceRemoves vendor/bin CLI commands in favor of laminas-cli integration, accessible via vendor/bin/laminas servicemanager:<command>.
vendor/bin/laminasRemoves deprecated ConfigInterface and Config class, which only proxied the configuration array without validation.
ConfigInterfaceConfigRemoves AbstractPluginManager#validate and $instanceOf; use AbstractSingleInstancePluginManager for single-instance plugin managers.
AbstractPluginManager#validateAbstractPluginManager::$instanceOfAbstractSingleInstancePluginManagerAbstractPluginManager no longer provides validate; extend AbstractSingleInstancePluginManager or implement validate yourself.
AbstractPluginManagerAbstractSingleInstancePluginManagervalidate$instanceOfAbstractPluginManager#get no longer accepts options; use AbstractPluginManager#build to create instances with options.
AbstractPluginManager#getAbstractPluginManager#buildRemoves the deprecated ServiceManager#getServiceLocator method.
ServiceManager#getServiceLocatorRemoves AbstractPluginManager#validate.
AbstractPluginManager#validateRemoves deprecated factories.
Removes the container-interop/container-interop polyfill.
container-interop/container-interopServiceManager and AbstractPluginManager no longer validate configuration at runtime; psalm types enforce the schema statically.
ServiceManagerAbstractPluginManagerServiceManager#__constructServiceManager#configureAbstractPluginManager#__constructAbstractPluginManager#configureCLI commands move from vendor/bin to laminas-cli, callable via vendor/bin/laminas once laminas/laminas-cli is required.
vendor/bin/laminasModernizes the codebase as part of the 4.0.0 BC break release.
Adds support for psr/container v2, an incompatible major version of the container interface.
psr/containerConverts old CLI standalone commands to laminas-cli commands.
Converts commands to laminas-cli symfony commands.
Adds strict type declarations across the codebase.
Platform3
Removes support for PHP 8.1 and adds support for PHP 8.5.
Adds support for PHP 8.4.
Drops support for PHP versions below 8.1.