If it is a route you do regularly then the best thing to do may be to make friends with the dogs like Muirenn suggests. I did that on my route back home. I brought extra tasty treats (chopped up hot dogs) on a few rides. I'd toss the treats to the dogs, who loved them and were distracted. The dogs will be less likely to chase you out of their territory but instead will look forward to your appearance. The pair of dogs I did this with now wait on the side of the road wagging their tails. Sometimes they get treats, most of the time they do not. This is intermittent reinforcement. Once you establish a behavior a treat only once in a while will work to reinforce the behavior.
This works best on dogs that are not aggressive or too highly aroused. It may take more work if the dogs get too cranked up when you see them. You might have to stop and give them the treats as Muirenn suggests. I really do recommend making the treats extra special. Not dry old dog biscuits but something fresh and meaty.
Trek Madone 4.7 WSD
Cannondale Quick4
1969 Schwinn Collegiate, original owner
Terry Classic
Richard Feynman: “The first principle is that you must not fool yourself and you are the easiest person to fool.”