ericire12,
Well, that's going to depend on two things. One, what is the purpose of the firearm and two, what is acceptable accuracy for that firearms stated purpose?
The quick answer is that you will most likely never wear out a Glock barrel. I know guys that have well over 50,000 rds on Glock barrels and they still shoot 4" at 25 yards.
It really doesn't matter whether it's a rifle or a pistol. What matters is what is acceptable accuracy to you. In Benchrest competition, if a rifle barrel opens up 1/4", it's a loser in the benchrest game, but the barrel still will be a sub-MOA barrel and would continue to serve quite well as a precision rifle for many more rounds. If that same rifle opened up to a 2 MOA rifle, it might not be good for Benchrest or as a sniper rifle, but it may be just fine for hunting moose and elk for another 1,000 rounds. This applies to pistols and rifles in the same way. My competiton pistol standard is 2.5" at 25 yards. Once a barrel goes over that, I'll replace it, but that same standard is still quite acceptable for a self defense pistol where my personal standard is 4" at 25 yards.
So you see, it really depends on what the purpose of the barrel is, and what is acceptable accuracy to you.
What parts are likely to fail? I'll assume your talking about a Glock. If so, I would stock up on "wear" parts. Glocks are very durable, but I would get an extra set of springs (Recoil, Striker, and Extractor), a spare extractor, and a spare cross pin for the trigger group or the barrel block. That would be about it for a Glock.
Erik