If you can, get on higher ground (car) so you can kick. Do not allow them to get behind you!
Dogs hate loud sounds, so air horn (on compressed air can), or loud personal alarm are good repellent. Also some fireworks work great.
To deal with dog owners (usual "itjustwantstoplay" or "noproblemnoproblem") scream for help immediately, and record video! Quite often dog owners attack right after their dogs, and make the situation much worse!