As we follow the story of Joseph we see his life has many commonalities or perhaps prophecies of Messiah's first coming.
In the Old Testament there are prophecies about Messiah who will suffer while on earth. In His first coming He empties Himself, in humility becomes a mere man living by every word from the mouth of God in His intimate relationship with His Father. Joseph too suffered and learned to live a life of humility, glorifying God with His words and His actions - and speaking the words given by God via his dreams and visions.
Joseph was a shepherd. Messiah also is referred to as a shepherd. Isaiah 40:11 says "He tends His flock like a shepherd. He gathers the lambs in His arms and carries them close to His heart."
Joseph was sent by His father to see if all was well with his brethren. Messiah was sent by God as His Son to His brethren the descendants of Abraham, Isaac and Jacob to seek out their welfare, and bring the Good News of Salvation to them. God just as then and also now has never taken His eye or His hand off His chosen people.
Joseph was rejected by his brothers and sent out of the land promised to Abraham and his descendants for a time. When his brothers went looking for help they were reunited with Joseph. So too with Messiah, many of His brethren in His day did not accept Him or His message, and so the way of Salvation was also opened to those outside of Israel until a time when again all His brethren will seek Him out and find Him. Even in sending Joseph to a gentile nation, God's plans were for helping HIs chosen ones. Also true of Messiah.
These are just some of the commonalities between Joseph and Yahshua Messiah. Can you find more?