Several posts on this blog recently have assumed that some passages in the OT look forward to a Messiah, that is a future Davidic king. This idea of a Messiah in the OT has a long history in Christianity, and one may say it has a long history of abuse. Christians often like to see Jesus everywhere in the OT. I don't mind seeing Jesus everywhere, if in doing so I'm following the example of Paul (as articulated by someone like Richard Hays), but I do want to understand what meaning these same passages might have had for the ancient Israelites, who would not have wanted to look for Jesus in every verse.
I have just finished reading an essay by J.J.M. Roberts on this topic, and I thought it would be helpful to summarize here some of the things he says. The essay is titled, "The Old Testament's Contribution to Messianic Expectations," and it is reprinted in Roberts' collection, The Bible and the Ancient Near East (Eisenbrauns, 2002), 376-89.
First, the word messiah (מָשִׁיחַ) cannot serve as a guide to the messianic passages in the OT, because its 39 appearances in the HB never look forward to a future Davidic king. It mostly refers to a contemporary Israelite or Judaean king, sometimes to priests or prophets, and once to the Persian king Cyrus (Isa. 45:1). Note that Roberts agrees with the majority of scholars (but not the majority of Christian tradition) in interpreting the two appearances of 'messiah' in Dan. 9:25-26 in terms of Jewish figures before the first century.
Second, some passages that have usually been interpreted throughout Christian history as involving a messianic hope actually probably did not originally carry this meaning but were rather written as a reflection on the contemporary monarch. Into this class, Roberts places Psalm 2, Psalm 110, and Isa. 8:23b-9:6 (Hezekiah).
Third, Roberts does identify some texts that "do in fact envision a future ruler not yet on the scene" (p. 381). These texts begin to appear in 8th-cent. documents. Roberts imagines that "the political disasters of the late eighth century, including the destruction of the northern kingdom and the deportation of a significant portion of the population of the southern kingdom, produced widespread longing for the unity, strength, and justice of the idealized united monarchy of the past" (p. 381). And so we have the legitimately messianic texts (without the word 'messiah') in Isa. 11; 32:1-8; Hos. 3:5; Amos 9:11-12; Mic. 5:1-5; Zech 9:1-10. This hope is also found later in Jeremiah (23:5-8; 30:9; 33:14-26) and Ezekiel (17:22-24; 34:23-24; 37:15-28).
While Zech. 3-4 has contemporary figures in view (Zerubabbel and Joshua), the linking of royal and priestly figures here (reflecting the earlier Jer. 33:14-26) probably became an inspiration for later conceptions of a priestly Messiah either alongside the Davidic Messiah (Qumran) or identical to him (Christianity).
One more thing worth mentioning from this essay. There is nothing in the OT that indicates that the coming Davidic king would himself rule forever. Rather, what seems to be in view in these passages of hope for a Messiah is the re-establishment of the Davidic dynasty, which would function like any dynasty, with sons replacing fathers on the throne. Hardly any other meaning can be gotten out of Jer. 33:22, where God promises to "multiply the seed of David," that is, give him a long line of descent, which would be valuable only if death still comes even to the Davidic king. This assumes, of course, that the Israelites did not consider the coming king to be the Second Person of the Trinity. That seems like a reasonable assumption!