Joseph had to believe what he said, that although his brothers intended evil, God used it for good. Today we need that faith to believe that God can take something negative in our lives and bring good of it. It doesn’t minimize the pain or hurt but it maximizes the power of God to work in a situation.
I think it also took a level of contentment to let go of certain things he had lost (time with his father, his homeland, freedom) and appreciate what was being given now and had been given to him- the opportunity for redemption. I think Joseph got a glimpse into the role he played in the grander scheme of God’s story. It is amazing what we can do when we feel we serve a greater purpose.