How we need to manage the App Secret expiry without having any downtime

I have have been working with remote event receivers for long time but i have never thought that they actually get expired, so based on this link @ we can renew the app secret after been expired.. but my question is that the steps inside the link assume that the App secret is already expired and we can renew the App secret and then update the web.config with the new App Secret.. but my question is how we can prevent the App from been expired? and renew it before expiry .. as seems we can not use the new App Secret unless the old one already expired.. any advice on this please?