A
A
Andrey2019-08-09 11:13:12
ASP.NET
Andrey, 2019-08-09 11:13:12

How to check if ASP.NET server is running?

Hello! It's time to start learning how to make servers for games for me. I chose ASP.NET because I found some lessons on the Internet on ASP.NET in conjunction with Unity3D and SignalR2 ...
In general, according to the lessons, I made a hub, made a connection to the hub in Unity, the problem is as follows:
If the server is running, then I have the unit calmly clings to the hub, but if you start the project when the server is not running, Unity just hangs dead and that's it, how should it be in this case? How to check the server's performance before connecting to the hub so that it does not freeze? Thank you all for your answers... there is very little information on servers on the Internet (or I'm not looking well).

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
alstin, 2019-08-09
@AkaruZ

Create a test route, if the response is 200, then the server is running, you can run Unity scripts. In Net Core, by default, when generating an Api project, a Value controller is created, so let’s go to it and make a request at localhost:5000/value (your port may not be 5000 but another)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question