I would say further, that If you are in a position to be implementing some non-trivial algorithm that's not currently in the toolbox, then your best approach is probably to go read a few papers first, and make sure that the algorithm you're looking at has not been surpassed. (Or, perhaps, you just need to dig something up from the '70s. A lot has been forgotten).
Then again, if you can implement Paxos on the first try...