Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / Remoting / December 2004

Tip: Looking for answers? Try searching our database.

How to check if Remoting Server is Active?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Kannan.V [MCSD.net] - 31 Dec 2004 07:03 GMT
hi.....

I have a scenario here.
I have an app which is client server app which communicate each other thro
remoting.
am trying to add another server for logging the user actions.
the user can chose to have logging enabled or disabled.
If the logging is disabled, the log server app is not started.
How do i chek in the client app if the log server app is running.

I can create an instance of the object using activator.getobject or the
connect method and try to catch the exception if the server is not running.
but this approach induces an unwanted delay, and affects the performance
very badly, especially when the logserver is on a different system.

Is there any way to do a simple check to find if the server is active, so if
the server is active, then i can proceed, else can continue with the other
process.

Thanks in advance for any help

Signature

Kannan.V
Blog : http://kannanv.blogspot.com

"Any one who has never made a mistake has never tried anything new" - Einstein

M.Posseth - 31 Dec 2004 07:57 GMT
well i had a simular problem

wanted to know from the client wich servers are online before i connect

turned out that there isn`t a way included in .Net remoting to acomplish
that

see my post "is there a way for a client to detect a server on the network"

well i found my way now ,,i have already found some example code wich i can
easily convert

the way i found is sending a multicast notification throughout the network

for instance :

client sends as a multicast message  "AS"    ----- Availlable Servers

servers sends back  as a multicast message  "SA| server IP | Sever name | nr
of current connected clients "

the nice thingy about multicasting is that you do not have to know the IP
range on wich you are currently running

you just use a multicast IP

like this

<appSettings>
 <add key="GroupAddress" value="224.0.1.1" />
 <add key="LocalPort" value="7777" />
 <add key="RemotePort" value="7777" />
 <add key="TTL" value="32" />
</appSettings>

all apps that are listening in the groupadress range and on the specific
broadcast and receive ports will receive the message

well if you need more info ,,, just ask    i am currently bussy implementing
this technique ( converting a multicast chat application to do the Job )

Signature

Met vriendelijke groet
Kind regards,

Michel Posseth
Software Developer
Microsoft Certified Professional

Company                 : Nohau Systems B.V.
Division                    : Systems Development
E-mail                        : michelp@nohausystems.nl
MSN Messenger       : michelp@autotaal.nl

> hi.....
>
[quoted text clipped - 16 lines]
>
> Thanks in advance for any help

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.