Disable automatic property injection?

We’re using NSB.Ninject. To maintain compatibility with existing code, we’d like to disable the automatic property injection. We’ve been able to work around the issue by using reflection to remove the module that’s added to our container. I believe automatic property injection is not needed for the NSB core, correct? I would expect this functionality to be something configurable.

Hi Bryce

The problem as of today is that NServiceBus as well as the downstream packages use the user container sometimes as well to resolve components. Because property injection has been around for years it could very well be that one of the downstream component assumes it being there and throws an exception. In general we are trying to move away from property injection and in general from using the user container internally as much as we can but it is a long winded process.

If you have acceptance tests or something similar I’m guessing it is fine to disable property injection for now like you did. You should detect issues with downstream packages of NServiceBus then in your QA environments and you can always raise issues on those repositories and we’ll see how we can improve the situation. Just be aware that the answer could be “sorry we are currently not fixing this because it is not our highest prio”. At this stage I have no better answer unfortunately other than saying we are moving in that direction in very tiny steps with giant gaps between each other :wink:

Regards
Daniel