2

let's suppose my WCF service is deployed on ineternet then how can I verify at run time that if particular service is up or not?

let's say my service can be accessed through url:

http://ipaddress/URI

Ashish Ashu
  • 14,169
  • 37
  • 86
  • 117

3 Answers3

5

Check the below links:

Community
  • 1
  • 1
Ghyath Serhal
  • 7,466
  • 6
  • 44
  • 60
2

You would have to have some kind of a "ping" function or something on your service - which would e.g. return some arbitrary text (possibly the version number of your service or something).

This will work ....

But: how does this really help you?? A split fraction of a second later, when another call comes in, the network could be clogged or a cable disconnected or something.

Such a "keep alive" or "ping" function doesn't really help much - in reality, when calling a service, you must always be prepared for it to fail. No matter how many times you check for the service to be alive beforehand - when you make your actual service call, it might still fail miserably. Be prepared for that and handle it properly!

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
  • Thanks Marc!! thru my expereince I also realize the same issue and handle cases where service fails to reply and give proper message at the client end. – Ashish Ashu Jan 31 '11 at 04:31
0

How about using the expected client of your service to call the WCF service pointing to the URL. If client is not available try using a generic testing tool like SOAPUI.

softveda
  • 10,858
  • 6
  • 42
  • 50