WP7 does not restore every app after a hard reset or phone replacement. The Zune desktop software will restore some of the apps that were purchased through it, but even then it doesn't restore all of them. I don't know what the exact threshold is, but there is a definite limit (either time-based, count-based, or both) on the apps it will automatically restore.
Also, apps that were purchased via the phone itself are not automatically restored, and although I haven't needed to try this yet, I would bet that apps purchased via the web-based marketplace are also not automatically restored.
Also, apps that were purchased via the phone itself are not automatically restored, and although I haven't needed to try this yet, I would bet that apps purchased via the web-based marketplace are also not automatically restored.