I think all in all it was a good thing. She wasn't right for you and this was the only way your relationship would have ended. Personally, I'll stay in a bad relationship, only to be miserable and confused. But, then looking back, I am much happier. Thank God, I never married my last ex gf!
Give it time. It happened for the best. You'll find someone a lot better for you!