Click here to Skip to main content
15,887,027 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi!

I have an extensible WCF web service that employs a plug-in style architecture. The available plug-ins, also homegrown, inherit from a C# interface that is baked into the service. The plug-ins themselves exist in a well-known folder which is a sub-folder of where the core service assemblies are located. The service fetches the identity of the plug-in folder from the configuration, iterates the assemblies in the folder, determines which ones do and do not implement the interface, loads the ones it needs on demand, and uses them.

The plug-ins are currently in one or more Visual Studio solution files separate than the one containing the core service. I have tried putting them all in the same solution as the service as well, but it didn't matter. The result is the same -- when I deploy the service using Visual Studio the plug-ins do not get deployed. My assumption is that this is due to the fact that they are referenced dynamically, not statically (pardon me if I'm using incorrect terminology, most of my background is from the C++ realm.)

What I want is for the deployment process to pick up any and all assemblies from the folder containing the plug-ins, which would include any assemblies upon which the plug-ins are dependent, and deploy the entire thing with the service using the desired folder structure. I want the plug-ins and any other assemblies they need to exist in a separate folder to minimize the number of assemblies the service needs to examine (for performance reasons) and simply because I feel it is a cleaner structure.

The entire scheme works well -- except that I have to first deploy the service, then hand-deploy the plugins. Obviously, this is quite undesirable. I have not figured out how to convince Visual Studio to cooperate and deploy everything in one fell swoop.

What do I need to do to coax Visual Studio into deploying this stuff as desired?

Thanks in advance for the help!!

What I have tried:

I have tried:

1. Hand editing the PUBXML file
2. Adding a folder referencing the plugins to the website project in VS
3. Placing each plug-in project in the same .sln as the core service
4. Posting on CodeProject hoping for sound advice!! ;)
Posted
Updated 22-Sep-16 10:59am
v2

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