简体   繁体   English

使用 MVC2 DI 和迁移遗留系统的建议

[英]Suggestion with MVC2 DI and migrating a legacy system

I have an old legacy system (more than 10 years) made in MVC 2 with structuremap(2.6.1.0) as DI.我有一个用 MVC 2 制作的旧遗留系统(超过 10 年),结构图(2.6.1.0)作为 DI。 We have begun migrating the back with nHibernate (also 10 years old) to entity framework core in a standard library.我们已经开始将带有 nHibernate(也有 10 年历史)的背面迁移到标准库中的实体框架核心。

But this doesn't work so easy, this old structure map wants to map everything in standard library also and that wont work.但这并不容易,这个旧结构 map 想要 map 标准库中的所有内容也行不通。 I would need to make it ignore the standard library, any suggestion how I should do that?我需要让它忽略标准库,有什么建议我应该怎么做?

This cant be done.这是做不到的。 Structuremap doesn't support standard 2.0.. Went back to EF6 and will do the migration to EF core once the MVC is upgraded to core(and stucturemap is not needed in mvc2 anymore) Structuremap 不支持标准 2.0.. 回到 EF6,一旦 MVC 升级到核心,将迁移到 EF 核心(mvc2 中不再需要结构图)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM