HighTechTalks DotNet Forums  

Dynamic updates of remote object without service interruption

Dotnet Framework (CLR) microsoft.public.dotnet.framework.clr


Discuss Dynamic updates of remote object without service interruption in the Dotnet Framework (CLR) forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
Nick
 
Posts: n/a

Default Dynamic updates of remote object without service interruption - 03-02-2006 , 11:18 AM






Hi,

I need some help regarding the mecanism to put in place to be able to
dynamically update a remote object when the assembly where it is
defined is
modified, and this whitout having service interruption.

Basically what I'm missing is how do we re-expose a remote object when
assembly has changed, and this without any interruption to the callers.

I have an application that exposes a remoting object (Well known
service -
Singleton or singlecall).

It works as follows:

1. Console application starts
2. Console application creates an application domain
3. Shadow copy is enabled on this application domain (so that the
assembly
can be changed, it is not locked)
4. Register a HTTP channel in this appDomain.
5. It then loads a specific assembly in the newly created appDomain and
register a well known service using a type found in this assembly.
6. Use FileWatcher to be notified on assembly file change.

Later, the assembly is modified. i now want to restart the service
using the
new assembly.

Currently, i just unload the appDomain, then redo step 2 to step 5.
Problem
is that there is a short time where the service becomes un-available
and
where requests are interrupted.

Questions: How can i restart the service without having service
interruption.
The idea is to process current request with old application domain, and
forward new request to new application domain.
Then once all old requests have been processed, the old application
domain
can be safely unloaded.
I think i may have to use channel sink but I'm not sure.

How can i achieve this ? I know ASP.NET is using this mecanism
extensively
to handle dynamic assembly changes.
Any help, ideas, code samples, etc will be greatly appreciated

--
Nick


Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.