I have two dogs right now. During my entire life, I've always lived with at least one dog. We've also had birds (got rid of those after they posed a cf problem), hamsters, guinea pigs, and my father has had a fish tank my entire life. Personally, I could not get through some things without my dog. He's a cocker spaniel, so he sheds, but we keep him groomed with a shorter cut, he gets a rinse off every two weeks in the winter, every week in the summer, and a bath every 6 weeks. The comfort I get from him far outweighs the risk he brings. For example, he is not a dog that cuddles. Ever. But the night I came home after getting my port placed, I was feeling pretty down. He picked up on it and spent the entire night glued to my side. And to be honest, I miss him more than I miss my family when I'm in the hospital. My family can visit, but he can't.
That said, pets can only provide comfort when you are ready. They will always carry a risk of germs and bacteria, however research breeds to find the one that fits best for you. A dog with shorter fur, that doesn't shed, that is active but can also relax when you are sick...all important factors. When it's time to have a dog, you'll know because it will feel right.