"Don't worry, don't be mad at yourself for what you've done. God has sent me here to preserve life."
Do we agree with Joseph? Forgiveness is one thing, but attributing to God all actions, including such hurtful ones as done by Joseph's brothers, may be hard to accept.
William Goldingay, in his Old Testament Theology, Israel's Gospel offers an explanation that is helpful to me:
God does not inspire the brothers to their immoral deed, but makes creative use of desires and acts that were self-serving or destructive.... The acts of God include human actions whose results can be made to further God's intentions in the world rather than working against them, p. 258.and
Like other characters in Israel's story, Joseph is a human being with strengths and weaknesses, and God works through both of these--and not merely despite them, p. 281.
We read this story of the reconciliation of Joseph to the brothers who had, in their jealousy, tried to harm him. "God has brought this about. Bring everyone here where I can provide for them."
Centuries later, Joseph's ancestors will form a nation, split it in two, then succumb to defeat by Assyria and then Babylon. Those ancestors can remember Joseph's story when they themselves are in exile. God can turn this terrible thing into something good just as the terrible thing that happened to Joseph turned out to be a saving event for his family.
Even more centuries later, we can also remember Joseph's story of exile and delivery. And we can look in it for hope for our situations.