在CMF项目上安装和配置FOSUserBundle后,“没有managerParameters导致有效名称”异常

时间:2014-05-01 01:42:14

标签: php symfony fosuserbundle symfony-cmf

在将FOSUserBundle安装并配置到CMF项目后,我收到以下错误。

ParameterNotFoundException: You have requested a non-existent parameter "None of the managerParameters resulted in a valid name".

in /var/www/****/vendor/friendsofsymfony/user-bundle/FOS/UserBundle/DependencyInjection/Compiler/RegisterMappingsPass.php line 75
at RegisterMappingsPass->getChainDriverServiceName(object(ContainerBuilder)) in /var/www/****/vendor/friendsofsymfony/user-bundle/FOS/UserBundle/DependencyInjection/Compiler/RegisterMappingsPass.php line 57
at RegisterMappingsPass->process(object(ContainerBuilder)) in /var/www/****/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/Compiler/Compiler.php line 117
at Compiler->compile(object(ContainerBuilder)) in /var/www/****/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/ContainerBuilder.php line 619
at ContainerBuilder->compile() in /var/www/****/app/bootstrap.php.cache line 2492
at Kernel->initializeContainer() in /var/www/****/app/bootstrap.php.cache line 2271
at Kernel->boot() in /var/www/****/app/bootstrap.php.cache line 2302
at Kernel->handle(object(Request)) in /var/www/****/web/app_dev.php line 28

在将FOSUserBundle以相同方式安装到标准symfony2项目中时,我没有任何问题。

感谢您的帮助,我完全不知道问题可能是什么......

1 个答案:

答案 0 :(得分:1)

您的用户实体需要存储驱动程序。此时FOSUserBundle支持doctrine orm,couchdb和mongodb但不支持phpcr。您可以定义自己的映射(也可以在FOSUserBundle上执行PR以添加它)或设置Doctrine ORM来管理ORM中的用户和组。