NServiceBus with Unity 2.0?

隐身守侯 提交于 2019-12-03 10:35:58

Unity, by default, behaves different from what NSB expects. That's why there is a need for some custom extensions to make it compatible with ObjectBuilder contract. There are two major differences:

  • Unity requires DependencyAttribute to inject dependency into the property. NSB expects ObjectBuilder to inject in any property that with matching type
  • When doing property injection unity treats property dependencies as mandatory whereas NSB expects them to be optional.

I believe that these features are preserved in version 2.0 and it will be easy to migrate them. I should have some time this week and I hope I will create a Unity v2 implementation. I'll let you know when it's finished.

Edit: Done. The Unit 2 object builder is in the trunk.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!