This is unavoidable by the player that gets targeted.
If you listened for the sound that accompanies this ability, and shift your camera to look up to see the actual cannon ball heading towards you, you could avoid it.