Click here to Skip to main content
15,890,741 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
I have a multi tenant application mvc4 with modules.what I want to do is to hide complexity from modules, I want to not having some references like ninject in modules and manage dependency injection in core application .in just a modular system without lieutenant feature,i use ninject.extenion.xml for this purpose and load xml file in kernel and everything works well.but when i want to implement multi tenant system with hierarchy kernels(i have a parent kernel and some child kernel in it)in the childkernel loading xml file to child kernel dose not occurs.how can i solve this problem??
C#
DirectoryInfo directoryInfo = new DirectoryInfo(bpath);
var modules = directoryInfo.GetFiles("ModuleName.dll");
Assembly assembly = Assembly.LoadFrom(modules[0].FullName);
AppDomain.CurrentDomain.Load(assembly.GetName());

Kernel.Load(Assembly.LoadFile(modules[0].FullName));
Kernel.Load(XMLFile);
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900