I need to implement watchdog in my go daemon

I need to implement watchdog in my go daemon.

So, the function is StartUpdateCycle() I call from my main function. The function runs infinite for loop but due to some networking issue the process gets hang and it doesn’t recover. So I need to watch the StartUpdateCycle, and it should recover by itself if there are hang, panic, stuck and runtime error issues.

func StartUpdateCycle(){

//infinite loop

for {

    //connecting to redis cluster

    // runs commands on linux machines and collect output

    //push into redis cluster

    //sleep for 1 min

}

}

func main(){

StartUpdateCycle()

}