Last post Dec 09, 2010 04:13 PM by atconway
Nov 30, 2010 01:56 PM|koss|LINK
I have been searching for solution for this issue for a while, but did not find a satisfying answer. I am hoping if there might be a new solution out there.
Basically, we have a number of ASP.NET web applications. We are trying to create and implement some sort of portal class to provide data and common classes to these applications. I have created a prototype class (compiled as an assembly dll) and it worked
very well with a single application. We expect this portal class to be updated frequently and need it to be visible to all apps. However, I am trying to implement it with other application.
From what I've researched on web, you basically need to use GAC, XCOPY to each local BIN directories, NTFS Junction Point, DEVPATH, or Dynamic Assembly Loading (requires interfaces and specialized instantiating for each class use). None of them seem to
have the ease of management enough for me to be feasible. Why can't we just create some kind of global "includes" directory and have each application probe the directory specified in each web.config files? I suppose the standard Microsoft method is to use
GAC, but it's not well-suited for frequent changes and signing each assembly and using strong name is very cumbersome. It baffles me how there is no convenient solution to such common issue.. Perhaps I am lacking in knowledge in this area.
If there is anyone would like to enlighten me, I would appreciate it. I am working with .Net 3.5.
Nov 30, 2010 03:10 PM|sachingusain|LINK
Nov 30, 2010 03:20 PM|rareddy|LINK
Why not create these classes and expose them via a web service? That way only 1 thing needs to be updated when you make any changes. If you add functionality, it will automatically be available to existing applications that consume the web service.
Nov 30, 2010 04:55 PM|thangchung|LINK
As rareddy said, you can expose all API through web service. I think it is really strong in your case. Microsoft SAAS also base on Web service, if you use .NET 3.5 or above, you can use WCF and you can make many things from it. SOA is a architecture that
you should consider. Don't use shared dll if it is not necessary. DLL hell in past was a example.
That is my opinion.
Dec 01, 2010 10:09 AM|atconway|LINK
Basically, we have a number of ASP.NET web applications. We are trying to create and implement some sort of portal class to provide data and common classes to these applications.
The current methodology for sharing common functionality among multiple applications would be to host that data in a WCF service that all applications can consume. This creates a single point of update and access making maintenance and accessibility a
much better option than installing binaries in the GAC on all of the required servers. Using the GAC is a more appropriate choice for packaged software (i.e. a reporting tool and its referenced binaries), but not so much for shared custom logic
that might span boundaries.
WCF offers a plethora of binding, security, and hosting options which makes it a fantastic and customizable technology for these scenarios. I highly recommend porting that code into a WCF service to be shared for your applications. And as an fyi... don;t
bother creating a .asmx web service. They technically still can be made, but the security model (WSE 3.0) is obsolete and they can only be hosted in IIS using HTTP. WCF has been around since .NET Framework 3.0 and should be the defacto service hosting
method at this point. Take a look to the following page to get started with WCF:
Windows Communication Foundation:
Hope this helps!
Dec 09, 2010 12:29 PM|koss|LINK
Why is web service and WCF the only viable method authorized by Microsoft? It seems rather counter-intuitive having the application reach out to IIS, refter to itself, and access the assembly when the files are local in the same server. It would add layers
of copmlexity and would also expose the assemblies directly on web. I wish each applications can designate any directory (not just sub directory) in the config file and have Fusion probe the directory for assembly.
Dec 09, 2010 04:13 PM|atconway|LINK
Why is web service and WCF the only viable method authorized by Microsoft?
Its not; you could write all of the plumbing code, SOAP, Socket Calls, whatever, but who in the world wants to do that.
And with WCF you are not constrained to hosting in just IIS; it can be a Windows Service, console app, WAS, or IIS. And on top of that multiple types of communication protocols other than just IIS are allowed. This is why WCF far outweighs any service
need requirements vs. a becoming obsolete. asmx web service. With a low level protocol binding like netTCP you have some seriously good performance which should make a lot of these types of conversations not holding water anymore.