To add to Tom’s point, depending on the API you are using you can configure callbacks on your session/messaging service incase any interruption happens. So for example, if you are using the PubSub+ Python API you simple register the service interruption listener to your messaging service and that is your health check for “the application can connect”
solace-samples-python/direct_subscriber.py at master · SolaceSamples/solace-samples-python
Solace PubSub+ Messaging API for Python. Join the Solace community for further discussions - solace-samples-python/direct_subscriber.py at master · SolaceSamples/solace-samples-python