I want to make my architecture better but i don't know how to resolve dependency trouble.
What i have:
- class library CoreService witch have a lot of interfaces
IMail
,Ilog
,ISession
- In app start i created
IMail
,Ilog
,ISession
based classes and pass it to CoreService class - base controller class with CoreService instance (property
CoreService Services {get;}
) - user plugin use CoreService interfaces
The problem: Every time i need to add new service i must edit app start, CoreService. Ideally I would like just create a class lib for IMail (or any other service) and register it in web.config or in app start.
I would appreciate for any advice or links that will help me.
Thanks for all so users!