Honestly, if he really loves you and you really love him you will work out a way to make the 3 year separation work. My "sister" who is from Taiwan was separated from her boyfriend for over 5 years and they got to see each other only twice in that time. However they stuck out their relationship, chatted by video online every night and so on and in the end they married two years after she went home.
So take the job and if you and your boyfriend if you are determined enough then you can survive and strengthen your relationship. If not and it fails then it's better to have it fail now than in a few years time when married for example.
Prefer? of course you should prefer to a nice boyfriend. But the situation is not that simple, I guess. I am not sure whether you will lose one if you make decisions to grab one, if so, choose the one you will never regret for.
seems all the female friends here agree to let u leave for the new job, which is not bad, indeed, however, ask yourself do you really have to ask here, or in fact you have already made your decision and just search for supports and comforting here?