It's an interesting one.
I think I'm pretty resilient - I've overcome a lot of trauma/ difficulties and am fairly good at letting things go, although I've had periods in my life where I've needed support for anxiety and depression, but they've never quite defeated me and even in the thick of them I was able to compartmentalise and still function to some degree. But I do think there's times in your life when your resilience is higher, and times when your defences are down a bit so it's harder to be resilient - and that's perfectly normal and you do need to be kind to yourself when that's the case.
I've always kept in mind that however horrific things feel at the time, I know I won't feel that bad in a week/ month/ year/ 5 years (select as appropriate to the situation). Nothing is permanent, good or bad, everything passes.
I have found reading and learning about something called the inside out/ three principles approach to mental health really helpful. Might be worth giving it a google - although there's a lot of very American, slightly woo stuff out there on it, there's also a lot of useful stuff in there.
Being comfortable with discomfort basically. Accepting you're going to have millions of thoughts a day, good, bad and indifferent - but they're just thoughts, they're not true, you don't have to believe them or give them any more significance. You also don't have to 'fix' them or change them or interrogate them - just let them pass. I sometimes think of a snowglobe - when it's all shaken up your thoughts are just swirling around in there, making it all cloudy and hard to see, and the more you try to DO something to fix it, the more you're just shaking it up more. So just put it down, let it settle, it will soon enough.
Something I'm trying to do more of too, is tell myself 'I'm really lucky and everything tends to work out for me' - trying to train my brain to look for confirmation of that! And if I am stressing or fretting over something, I'm training myself to think, 'well that was shit, but I'm generally a really lucky person and things always work out for me in the end, so this will too'. Might stray a little bit into the whole toxic positivity trope, but worth a shot? To be clear, I don't always believe this! I've had a great number of 'unlucky' and painful things happen to me, but on the other hand things HAVE generally worked out - I'm healthy, have a beautiful DC, a good husband, am gainfully employed with a roof over my head and food in my fridge - so it is true, I am lucky and things do work out for me. Takes a while to train yourself into that way of thinking but then when you start to see evidence of it everywhere.