Although this expression has come to mean to most people something along the lines of WOW this/this life/my life sucks(with the implication of weariness at that fact), the passage of scripture from which the expression is drawn has rich theological content both for Jews and Christians and echoes a much more severe statement than they likely intend.
This expression finds its origins in the book of Isaiah chapter 6 in what is commonly referred to as the calling of Isaiah. Isaiah, who has been a prophet of God, has his eyes opened to the throne room of God. Overawed by the majesty and holiness of God and repulsed by his own sin He has a nervous breakdown and pronounces an oracular curse on himself (essentially calling down God's just punishment on himself). Then he is cleansed of his sin by having a red hot coal pressed to his lips by an angel (who ever said that the Bible is boring?)
The King James version of the Bible renders it "Then said I, Woe is me! for I am undone; because I am a man of unclean lips, and I dwell in the midst of a people of unclean lips: for mine eyes have seen the King, The LORD of hosts." As a prophet of God it was a part of Isaiah's job to pronounce God's blessings and curses on Israel, making them aware of how God felt on any given subject and what was going to happen good or bad as a result. Isaiah was in fact pronouncing God's punishment on himself for the sins of his lips. I like the expression "undone" because I feel it captures most dramatically what it feels like to experience the reality of one's own sinfulness in the presence of a perfect and perfectly holy God.
So when someone casually uses the expression "oy vey" they are actually echoing a self curse and laying claim on the Wrath of God.