Hi,
To check if a service is up, system will establish a TCP connection to the host on the specified port how to do with C#
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Jenith ThakkarPosted Jul 16, 2020, 11:15 PM
I have a good option for that
you can create a self host service
Please have a look this link
https://www.c-sharpcorner.com/UploadFile/b1df45/web-api-self-hosting-using-windows-service/
Self hosted service has a hosting and port as well and it works as a service so you can use it as a monitoring purpose
Thank you
ThilanPosted Jul 16, 2020, 11:08 PM
"Design and implement a solution in .net to monitor services. Design and implement in (.net) a service monitoring class. This monitor will be used to monitor the status of multiple services. A service is defined as a host/port combination. To check if a service is up, the monitor will establish a TCP connection to the host on the specified port. If a connection is established, the service is up, if the connection is refused, the service is not up."
Jenith ThakkarPosted Jul 16, 2020, 10:22 PM
Thank you
"Please mark as a answer if it's working for you"
Santhakumar MunuswamyPosted Jul 16, 2020, 10:19 PM