"Aiming a blow at the sand thieves was like driving a chariot wheel through a mud puddle: the contents spattered and flew apart in tiny globules, then ran together and all was unchanged. So the nomads were, striking at defenseless peasant hamlets or the donkey-caravans of merchants, then fading back into the endless wastes of the west."
-SM Stirling, On The Oceans Of Eternity (New York, 2000), Chapter Eight, p. 133.
However, sometimes barbarians encroached so far into civilization that they became civilized:
"The chronicles said the Amorites had come likewise from the western deserts long ago, and ended by ruling all the Land - Hammurabi was of that blood. His own ancestors had been herdsmen from the other quarter, in the mountains to the eastward." (ibid.)
Poul Anderson imagines exactly the same kind of encroachments and invasions but on an interstellar scale. See here. When Flandry, requesting a projection of a rendezvousing craft, sees a lean shape rushing forward not of Imperial manufacture but armed as well as his own ship, he thinks:
-Poul Anderson, The Rebel Worlds (London, 1973), Chapter VII, p. 66.
The blurb on the back cover of this edition reads:
"The barbarians in their long ships waiting at the edge of the Galaxy...
"...waited for the ancient Terran Empire to fall..."
- and, in other works, Anderson wrote about Vikings in their long ships. Historical fiction and science fiction can be complementary.