To say, "This too is for the best," is hardly the same thing as superficial optimism.
It is a recognition of the reality of pain and evil and an attempt to get to the root of suffering, to get beyond the fact that everything bad has something good in it, and that salvation often emerges from tribulation.
There is no longer any consideration of the ultimate profit or hidden goodness in the reality of suffering.
Besides, what kind of release or consolation resides in the thought that the pain will pass?
One who is in agony of body or spirit can hardly be made to feel better by philosophic or religious ideas.
The Jew who sincerely faces suffering does not seek an accounting with God-he does not reproach Divine justice or defend his own innocence.
Nor does he seek ways of reaping some advantage.
He relates entirely to the present, to that which is now, not to what was in the past, or what is liable to be in the future.
No solace is sought or vain imaginings. If God wills it, the situation will improve; otherwise, it's none of my business.
The argument is that since suffering is something that comes from God, it is in the nature of a gift, or at least something that is given.
Because, to be sure, not everything that is given can, at first sight, be recognized as something positive.
And this takes a lot of time, a great deal of tumultuous repudiation before one reaches a relatively peaceful
state of equilibrium.
–Rabbi Adin Steinsaltz
From "The Meaning of Sadness" in The Long Shorter Way by Rabbi Adin Steinsaltz