[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.dotnet.framework.remoting

Starting/Stopping/Checking State on Remoted Objects

Alex Maghen

8/28/2004 1:27:00 AM

Hi. I'm a little confused about how to control the availability of an object
that I make available from my server software. In all of the examples, I
follow these steps to make a class available...
1. Create a Channel
2. Register the channel
3. Do a RegisterWellKnownServiceType()

This works fine. But now here's what I don't really understand: Let's say I
want the application to keep running but I want the remote object to be
unavailable. How do I "shut it off" or make it "un-published"? Also, is there
some object/class that I can query to determine the state of the server
software (i.e. what objects are "published," what is there state, etc)?

Thanks
1 Answer

Sam Santiago

8/28/2004 6:17:00 AM

0

Check out the RemotingConfiguration class, it has methods that can get
information about published objects:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfsystemruntimeremotingremotingconfigurationmember...

I don't think there's a way to unpublish an object. Check out this chat
that made the statement below:

Remoting Chat
http://msdn.microsoft.com/chats/vstudio/vstudio_...

"Q: Is there a way to unregister WellKnownServiceObjects?
A: Nope. But you can do it through manually calling Marshal (with a uri) &
Disconnect(). "

Thanks,

Sam

--
_______________________________
Sam Santiago
ssantiago@n0spam-SoftiTechture.com
http://www.SoftiTe...
_______________________________
"Alex Maghen" <AlexMaghen@discussions.microsoft.com> wrote in message
news:D961F996-49BC-43B6-9F43-62ECE95A5DD8@microsoft.com...
> Hi. I'm a little confused about how to control the availability of an
object
> that I make available from my server software. In all of the examples, I
> follow these steps to make a class available...
> 1. Create a Channel
> 2. Register the channel
> 3. Do a RegisterWellKnownServiceType()
>
> This works fine. But now here's what I don't really understand: Let's say
I
> want the application to keep running but I want the remote object to be
> unavailable. How do I "shut it off" or make it "un-published"? Also, is
there
> some object/class that I can query to determine the state of the server
> software (i.e. what objects are "published," what is there state, etc)?
>
> Thanks