If you are ever feeling down about a rejection (especially a close one you really wanted), check out audition tapes of now famous actors on Youtube. My personal go-to is the office audition tapes for Dwight, Michael, Kevin and Pam.
In a few minutes, you can see that even amazing people giving their absolute best experience rejection. Some of these people would have been absolutely great at their parts (cough Adam Scott as Jim cough), and still it didn't work.
In fact, a lot of sources say that Jim and Pam were only cast because of their chemistry with each other. So, when I have given my best and it doesn't work out, I take a look at this video.