I got a little differently with it. But there's two parts, for me.
One part is emotional: attempted empathy
Current, alive me regrets not seeing the continued beauty of humanity on continental plates in O'Neill cylinders in belt nations strewn around the Sun inhabited by trillions, but I take solace in something "higher than myself" or more significant, stepping out of myself, than my own experience: the experience of everyone else.
As in: don't be so self-obsessed; it sucks that you won't be there to see miracles in the year 3,000, but countless future generations will, so that suck is only a drop of bad in an infinite ocean of good. Be grateful for what you are here for, and be happy for other people, whether they exist now or not.
NIN, In This Twilight, black-is-really-white shit na mean xD
The second part is more rational: deprecation of consciousness
This one's harder to think or talk about and more philosophical and probably has veins running into the first part. I kind of feel like, "objectively", all consciousness is unified in its reductive, anthropic-principle-nothingness. All consciousness seems to be is a runtime with memory data. In the future, or when you wake up tomorrow, is your consciousness then still "your" consciousness? Still the same consciousness as now? And, if not, what's the difference between that and the consciousness of a completely separate person?
Think a clone or an uploaded, digital clone (a la the game Soma), whose experience you don't share and, despite being a clone, seems as alien to your qualia as any non-clone. But they're still a clone. So then extend that to other people.
Fetishizing your own consciousness is like fetishizing the NAND gates in the SSD that your OS runs on. In the end, it's just as good as another OS running on different hardware.
These two things make my death a miraculously beautiful, globally happy ending, rather than a bleak, local tragedy. It's just a shift in focus, and I think a sober, reasonable one.
... Until heat death, when everyone dies, but that's even farther out. xD And, hey, we don't even know what the majority of matter or energy in the Universe are yet; that buys some leeway in being tied down to predicted cosmic tragedies, r-right??
AND if you're feeling so astrophysicsy, there's always the emergency lever of multiple universes, which inductively follows the same reasoning for self-among-others, just at a slightly larger scale.