orocrm - ORO 从 3.1.19 迁移到 4.1.2
问题描述
我们正在从 ORO 3.1.19 迁移到 4.1.2,并且遇到了迁移问题。
$ php bin/console --env=prod oro:migration:load --force --show-queries
Process migrations...
> Oro\Bundle\EntityExtendBundle\Migration\LoadEntityConfigStateMigration
> Oro\Bundle\MigrationBundle\Migration\UpdateBundleVersionMigration
> Oro\Bundle\EntityExtendBundle\Migration\RefreshExtendCacheMigration
Prepare entity config
Clear extended entity cache
Dump the configuration of extended entities to the cache
Clear entity metadata cache
Warm up entity metadata cache
In RuntimeReflectionService.php line 63:
Property Oro\Bundle\AttachmentBundle\Entity\Attachment::$account_8d93c122 does not exist
我们尝试清除缓存,实体配置缓存并没有成功
php bin/console --env=prod oro:entity-config:cache:clear
php bin/console --env=prod oro:entity-config:cache:warmup
任何帮助或反馈将不胜感激。
谢谢
编辑
我们可以看到,Attachment::$account_8d93c122
在初始容器创建期间,Reflection 找到了,但在实体缓存预热期间没有
解决方案
当实体元数据未准备好时,请确保您没有使用原则 ORM 服务(@doctrine、@entity_manager 等)。
通常,在编译器传递或迁移中使用 ORM 时会出现错误。
推荐阅读
- excel - VBA 宏删除包含 #N/A 的单元格并向上移动单元格(不是行)
- python - Switching between screens defined in separate .kv (Kivy) files
- ios - Admob 横幅广告最佳做法
- java - Eclipse 未显示 jdk10 的 javadocs
- r - 在 Shiny 应用程序中使用 summarytools::descr() 和 by() 时变量名消失
- c - fseek/fsetpos may discard stream buffer?
- c# - 函数将表名设置为参数并从sqlcommand c#中的XML文件中获取列名和表名
- css - CSS 仅适用于放大的页面
- android - Creating PDF in separate thread STILL making main thread unresponsive
- zapier - Get raw data from the previous step in Zapier