i have a scenario where in before i write any data to the RabbitMq queue i should check whether queue is alive or not.
If not i should save the data into the localDb but and my thread code should be keep on pooling into the connection status to know whether the connection is up or not.
Once the connection is up the data saved in localDb should be dumped into the queue for the consumption.
if(check_connection_existsOrNot())
true:--->dump into the queue
false:--->create a thread to pool onto the connection status.