I'm getting along just fine with my most recent ex - we chatted on Skype tonight, actually, and watched an episode of Torchwood together.
I also get along fine with two other exes. One of them, I met through mutual friends at one of the conventions I work on. Knowing that I'd likely bump into him again, I worked hard to stay friends with him even though I was hurt when he broke up with me. The other, whom I knew through my bowling league, I had a bit of a prickly relationship with after our breakup; when we saw each other, there was usually verbal sniping. Then about two years ago, after my team switched from the Wednesday session to the Friday, he came up to me at the banquet and said, in a friendly manner, "Where have you been all year?" I said, "Why, did you miss me?" He replied, "Yes, actually, I did." It was then that I realized that the whole thing had been a front on his part. I still don't know why he was an ass to me for all those years, but knowing that it was a front means that I can deal with it.
OTOH, I wouldn't put my ex-husband out if he was on fire. Then again, he cheated on me, and married the other guy by means of the banns, which meant that he had to publicly state that he'd never been married before. Since we'd had a church service about six years earlier, I was a little ticked off. When Facebook suggested him as a friend, I blocked him.