synchronization – Building a custom index on top of a Bitcoin full-node

I want to build a custom index on top of my full-node. I am not looking for answers that insist it’s a bad idea. Fact of the matter, a full-node simply lacks in the way in indexes.

I can listen to incoming blocks and transactions via ZMQ when running a full node, which is great. I can build my own indexes off the back of those notifications.

But what if my node goes offline for a while? How will I tap into it syncing back up, so I can catch-up my custom index?

My last dilemma is what if my service, listening to the ZMQ notifications, goes down. But I will leave that semi-out the scope of this question.