The Angel of the LORD is in the midst of His saving work as promised in 3:12. He has brought His people out of slavery, and now He is bringing them to the mountain to worship God. In the meantime He leads them "by stages" (17:1, ESV) through a desert wasteland where all they have to sustain them is the Angel Himself. He - the LORD Jesus - is the Rock who accompanies them and provides them with both their natural and spiritual sustenance (1 Cor 10:3-4,9). The Israelites are being taught a lesson summed up well in the experience of one African Bishop:
"I never knew Jesus was all I needed until Jesus was all I had."
That's the lesson for the Israelites in the desert. There is no natural sustenance for the people of God as they wait their mountain-top experience. All they have is Jesus. But they are being taught time and again - all they need is Jesus. (For more on this theme see The Church in the Wilderness.)
In chapter 16 we saw grace for the grumbling. The people complain at their spiritual leaders (16:2) and wish themselves back in slavery. This is bad enough but Christ reveals that this is really grumbling against Himself (16:8) (pause for thought when you're next tempted to roast your Christian leaders!). Their sin is much worse than they imagine - but His grace is much greater too. He would feed this mutinous rabble with the food of angels. And on Calvary He would reveal the full depths of this grace - He would be torn apart as Bread for the world to feed wicked and desperate grumblers like us.
Chapter 17 shows this cycle of grace for the grumbling repeated.
The people "quarrel" with Moses (v2) - but it's clearly a test of the LORD (cf Ps 95:8-9). We know what should happen to those who quarrel:
1 Samuel 2:10 Those who quarrel with the LORD will be shattered. He will thunder against them from heaven; the LORD will judge the ends of the earth. He will give strength to His King and exalt the horn of His Anointed.
Christ, who does not quarrel (Matt 12:19), will be the anointed Judge of all those who quarrel.
So when the LORD commands Moses to take up the staff from which the plagues of Egypt have flowed (v5), we know what should happen next. He should strike down those horrible ingrates in judgement as a little sign of what the true Anointed King would do.
Except that's not how it works out. Instead the LORD Jesus stands on a Rock in front of all the elders. Remember that "The Rock" is a favourite name for Him (e.g. Gen 49:24; Deut 32:4ff). So He’s associating Himself very strongly with this physical rock. And then He says to Moses, Don’t strike them, strike the rock.
Water comes out and their thirst is slaked. It’s incredible grace towards the grumbling. Not simply are they spared, they are positively blessed in response to such wicked quarrelling! And wonderfully, Numbers 20:13 describes this event as one in which the LORD "showed Himself holy." The holiness of the LORD is not simply that which zaps sinners, but it shines forth when the Rock is struck and the grumblers are graced.
Centuries later, the One who stood on that rock - the Spiritual Rock who accompanied the people - came to a quarrelsome, grumbling, evil rabble. But again, it was not the rabble that was struck. He was struck by the rod of divine judgement and the life-giving waters of the Spirit flowed. That same grace is extended to we grumblers today. Our thirst is slaked because when our Rock was struck, Living Waters flowed from within Him (John 7:38; 19:34).
From v8, the Israelites learn that their LORD doesn't only provide our necessities - He fights our battles. We read of the attack of the Amalekites and we are introduced to Joshua for the first time. His name simply is Jesus. Here is the one who would bring them into the promised rest. Moses can only bring the people so far - the one called Jesus must bring them home. And here this young man will overcome the enemy while Moses holds his hands out on the mountaintop.
So the LORD provides food and drink and guidance and victory for a people who doubt and question and quarrel with Him at every turn. They groan when oppressed and then grumble when freed. They will be brought kicking and screaming to the promised rest only by the steadfast love and kindness of the LORD. They can count on no-one and nothing else for their identity, security, strength and salvation. The LORD alone is their banner (v15).