The destruction of the Batai Mikdash is a prime example of ruin, which is “the state of being damaged irreparably; destroyed.” Yet this ruination is reparable. In fact, the Batai Mikdash will be rebuilt, even better than before, as the Rambam says, “These fasts will be nullified when Mashiach comes; furthermore, they will become joyous and holy days as Zecharia haNavi (8:19) says, ‘Thus said Hashem: the fast of the fourth [month; the 17th of Tammuz] and the fifth [the 9th of Av] … will be to the House of Judah for joy, for gladness and for happy festivals!’”
That these days will be nullified is understandable, but why will they be celebrated?
The destructions and subsequent exiles are part of G-d’s divine scheme. His plans are positive and purposeful though we may not understand them now.
The Talmud says (Psachim 87:b), “The Jews were exiled just to add geirim (converts).” The mystics define geirim as sparks of G-dliness that have fallen into the lands where the Jews were exiled into, that need to be returned to their Source.
Decoding this: Hashem is the ultimate luminary. G-d’s purpose for each entity is a latent spark waiting to be ignited. Our mission is to reveal and connect the sparks to their source. In the eras of the Batai Mikdash the Divine Presence was accessible via the neviim and the miracles in the Batai Mikdash. In exile, the task is upon us, to demonstrate that everything is for Hashem. When we do so, the billions of points of light we have released will glow into a crescendo of light heralding the coming of Mashiach. May we merit to see that now!