I agree with all the posts above. It really depends on how you ride the bike. If you are a weekend warrior and don't ride too hard than 5 + years is reasonable.
If you are a heavier rider like myself, than less. If you jump or ride aggressively, than less. Too many factors.
The best thing to do is to ride it like you stole it, then when you break it, buy another one!
Frames can be found for reasonable prices. I bought a N.O.S. aluminum frame that was sitting in a shop for 4 years, never used for under a hundred dollars.
__________________
"Life is not a journey to the grave with the intention of arriving safely in a pretty and well preserved body, but rather to skid in broadside, thoroughly used up, totally worn out, and loudly proclaiming, "WOW, What a Ride!" - unknown
"Your Bike Sucks" - Sky Yaeger