In the Hebrew, chapter 21 really begins with 20:45, since the topics are related. In the fire of war that the Lord would kindle against the Promised Land, there would be a general suffering, affecting both the "green tree" and the "dry tree" (20:47), which are explained in the corresponding verse of 21:4 as the "righteous" and the "wicked". Some may question, "Why would the Lord allow righteous people to be killed at the time when He used Babylon to be His instrument of war?" We know that He providentially spared the lives of some righteous ones, such as Jeremiah, but evidently He did not save all of them. In their deaths, however, the Lord spared them from the evil aftermath of the war and gave them eternal life in fellowship with Him and complete peace (cf. Isa. 57:1-2).
Many times in Israel's history, the Lord had taken His sword from its sheath but had returned it before causing total destruction (e.g. 1 Chron. 21:16, 27). This time, however, the Lord would not put His sword away until the destruction was complete; there would be no relenting (21:5). The Lord told Ezekiel to perform the dramatic signs of sighing out loud, striking his thigh, and striking his hands together, just as one in mourning would do (21:7,12,14). This was to publicly exhibit his own personal sorrow at what he knew would take place and the sorrow that all the Jews in the exile would feel when they heard that the sword had come against Jerusalem. The Lord had purposed to use the king of Babylon to wield His sword, and God would overrule in Nebuchadnezzar's attempts at the pagan methods of divination in order to decide which direction to go at the fork in the road. God's will prevailed and the appointed road for His sword was the road to Jerusalem (21:21-22). The other road, the road to the Ammonite city of Rabbah (present day Amman, Jordon), was to be taken by Nebuchadnezzar a few years later. The Ammonites, who had mocked and laughed about Jerusalem's destruction, would suffer a worse doom than Israel, for as the Lord had purposed, the Ammonite nation was to become extinct (21:20, 28-32).
With prophetic words directed at wicked Zedekiah, Ezekiel revealed that the Lord's sword had been prepared and was ready to strike Zedekiah and his scepter (21:10b). He would be the last descendant of David to wear the crown and sit upon the throne "until He comes whose right it is" (21:27; cf. Gen. 49:9-10). This is clearly a Messianic prophecy, for the right to the crown and throne of David belongs to the Lord Jesus alone.
The children of Israel did not live up to their responsibilities and obligations as the privileged and chosen children of God. They were to be a light to the Gentiles, so that the pagans would come to know that He alone is God. But the children of Israel continually profaned Him by disobeying Him and worshiping idols, thus lowering Him as though He were just another God among many. Because they had forgotten God (22:12b), all areas of society were corrupted and all classes of people (the king, false prophets, priests, nobles, and common people) were morally decadent, as Ezekiel describes in chapter 22. They were sexually perverted, cruel, unscrupulous (shedding much innocent blood), disrespectful, greedy, and oppressive. Their excessive wickedness made them a reproach, even to the surrounding heathen nations! (22:4-5)
For centuries, the Lord was longsuffering and spared His people from the judgment they deserved, lest the Gentiles say that He could not save them. Now, however, it was necessary for the Lord to vindicate His holiness so that His Name might be hallowed. To accomplish this, the Lord exercised His justice and poured out the fire of His wrath upon the people of Judah. As well as satisfying His justice, the Lord's purpose was to purge for Himself a pure and righteous remnant.
If only King David's successors had been the type of leaders that would promote spiritual growth, this judgment could have been averted. But with the exception of few kings, they were all wicked, rebelled against God, and lead the people astray. They, along with the leadership of Judah, were building a weak and decaying society (the whitewashed wall held together by inferior mortar, 22:28; cf. 13:11-15) that had become full of holes. The Lord had no strong man in leadership to stand in the gap of the wall in order to fight the attacks of the enemy through intercession (cf. 13:5), repair the holes, and possibly spare Jerusalem from destruction.