radu-matei / websocket-manager

Real-Time library for ASP .NET Core
https://radu-matei.com/blog/real-time-aspnet-core/
MIT License
452 stars 183 forks source link

How do I keep a long connection? #33

Closed leeolevis closed 1 year ago

leeolevis commented 7 years ago

How do I keep a long connection? My android app is easy to disconnect

radu-matei commented 7 years ago

What client are you using in your Android app?

leeolevis commented 7 years ago

Is it normally possible to disconnect? Commands such as ping or pong need to be maintained Android was developed by other colleagues, and I don't know yet,

leeolevis commented 7 years ago

Do you need to return ping or pong?

RobSchoenaker commented 7 years ago

Connection management is handled on a lower level. You do not need to do ping/pong. If you answer radu's question, maybe he is able to help. How is the Android app connecting? If it is using a local connection in an Activity, the connection will drop when your activity is recycled. If you do not want this, you need to use a Service.