No, I've never done any socket programming. I just read the wikipedia article on the term in general. The closest I've ever come to caring is when I have to add a port number to an address and even then, I don't really get it.
Thanks for your answers, good to know.
As for an indefinite connection, I guess the practical thing I was curious about was just having something open a very long period. Like if an app had a dashboard to show real time events and it was being shown on a monitor for most of a day. Firebase documentation says it handles interrupts/disconnects and automatically reconnects.
So, maybe changing the subject... how do push notifications work? Like on a mobile device, how does Google Cloud Messaging or Apple push notification service instantly connect to your phone? Is there an open internet socket open all the time waiting to receive the message?