Discipleship

David uses the same phrase later on, too. Just after he was anointed king, and had subdued the lands that were promised to them by God, he brought the ark of the covenant to Jerusalem, and throws a big party to celebrate all this. He breaks into a "song of thanks to the Lord":

He gave [the promise] to Jacob as a decree, to Israel as a lasting promise, 18 saying, “To you I will give the land of Canaan as the portion of your inheritance.” 19 When they were few in number, just a very few, and foreign residents within it, 20 they wandered from nation to nation, and from one kingdom to another. 21 He let no one oppress them, he disciplined kings for their sake, 22 saying, “Don’t touch my anointed ones! Don’t harm my prophets!”
1 Chronicles 16:17–22 (NET)

Notice this use of "don't touch my anointed ones" is saying that Israel is the anointed one—the chosen one.

As chosen by God, they have favour and protection from God against other nations (16:21). Given God had covenanted with Israel to bring them into the Canaanite lands, God made them untouchable. No one was going to thwart God's plans, and anyone who stood against them would suffer the consequences.

Being applied to the nation as a whole, it allows for those who were punished because they foolishly went ahead of God or rebelled against him (see for example Achan's sin in Joshua 7; the rebellion of Korah, Numbers 16; and even Moses for his actions at Meribah, Numbers 20). They were part of the anointed Israel, but while they were personally judged, Israel lived on to see the promised land, and to see rest from the wars. This again affirms the fact that no one is above criticism, even if they are part of the chosen Church. Individual elements that need pruning will be pruned (John 15:2). Those who stand against God's will, will not be tolerated.

God sometimes chooses non-Christians for his purposes: "Thus says the Lord to Cyrus His anointed, Whom I have taken by the right hand, To subdue nations before him..." (Isaiah 45:1). Cyrus is called "anointed", taking the meaning of "chosen". So, was Cyrus, a pagan king, above criticism? Clearly, God is using Cyrus for his purposes (which was to bring Israel back from exile, 2 Chronicles 36:22-23). Nobody can thwart God's purposes! Therefore we can affirm some sort of "do not get in the way of God's plans" principle here. But "do not criticise" finds no place.

Similarly, in the midst of the exile, Isaiah proclaims that they will taunt the king of Babylon (Isaiah 14:4) because God will strike them down, break them, with other armies (14:24-27). "Who can possibly frustrate [this plan]? His hand is ready to strike, and who can possibly stop it?" (14:27) In Daniel we learn the armies of the Persians and Medes took over from the Babylonians (Daniel 5:30-31), in the kings of Darius and Cyrus (6:28). It was Cyrus a Persian king who enabled some Israelites to go back to Israel, and Artaxerxes, another Persian king, who gave them all they needed to rebuild the Jerusalem wall (Nehemiah 2:1-9)—all according to God's prophecies. Job's dramatic experience ends with Job acknowledging God's ultimate sovereignty: Then Job answered the Lord: 2I know that you can do all things; no purpose of yours can be thwarted...”” (Job 42:1-2).

When we know that God is using someone to achieve his purposes, it doesn't mean they are above criticism. God allowed the Devil to harm Job: is the Devil above criticism?! But God's purposes were to shine forth the righteousness of Job, and also to humble Job further. These things should be allowed to run their course, and not be opposed, lest we find ourselves opposing God. This is Gamaliel's council, cautioning the Jewish religious leaders in their action against the Apostles:

Then [Gamaliel] said to the council, “Men of Israel, pay close attention to what you are about to do to these men. 36 For some time ago Theudas rose up, claiming to be somebody, and about four hundred men joined him. He was killed, and all who followed him were dispersed and nothing came of it.37 After him Judas the Galilean arose in the days of the census, and incited people to follow him in revolt. He too was killed, and all who followed him were scattered. 38 So in this case I say to you, stay away from these men and leave them alone, because if this plan or this undertaking originates with people, it will come to nothing,39 but if it is from God, you will not be able to stop them, or you may even be found fighting against God.”
Acts 5:35–39 (NET)

Even as a Pharisee, God clearly spoke through Gamaliel, as his words were wise and true. Nevertheless, it is very difficult to know, looking ahead, what God's precise plans are. The example of David and the examples Gamaliel brings up all look back in history. Prophets and wise insight help. But the only way forward is with openness to criticism and alternative opinion, lest even the prophets be silenced. Those who silence the prophets are those who want to go their own way, their own path, away from God (Isaiah 30:10-11; Jeremiah 32:1-5). God's way forward is typically the harder way to accept, the one that rails against our flesh the most, and so the freedom to hear hard criticisms and undesirable alternatives is a freedom that we should champion and honour.

So, an application of not thwarting God's plan is to hear and consider different people on what those plans might be.