New to this

Topics: Web Client Software Factory
Feb 16, 2007 at 8:00 PM
I have a module created to isolate a business area. I have a foundation module created to hol all service agents wrapping remote services - in case these are required across more than one business module.

So my questions are...

1. How would I reference and insantiate an instance of the service agent class from the separate business module.
2. Is this the right way to go about things?
3. I was reading up on 'Services' under the factory but I can't work out if that notion has any weight here.

Thanks so much!
Mar 29, 2007 at 12:47 PM
Hi Shaitan,

Putting shared services in a service module seems to be fine. But if they are tightly related to your business module’s logic, you might want to keep them in the business module and register them as global services. And if you want to do a clear separation, you could store the service agents and or service proxies in a separate project, referenced by the business module main project and by other modules that consume the services. We usually recommend users to store infrastructure services (like auth, authn, logging, etc) in foundational modules and to leave business logic-related services inside business modules. But nothing really prevents you from putting any kind of service in foundational modules, though.

Please take into account that if you want to separate service contracts from their implementations (to decouple your modules from the concrete service implementations), you could put your services contracts in a separate project, and then from your Business Modules you reference this project.

You can see the topic “How to: Register and Use Services” in the WCSF Help. (ms-help://MS.VSIPCC.v80/ms.practices.wcsf.2007dec/wcsf/html/03-210-HowToRegisterAndUse_Services.htm)

Let me know if this helps,
Ezequiel Jadib