Cody will bark when the door bell rings or when someone is first coming in through the door - he will usually go over to check out who it is. He will bark if I am playing fetch with him and he anticipates the toy being thrown.
However, one night, some prankster rang our door bell at 2 in the morning, and Cody's crate was within 8 feet of the front door and he never made a peep

so much for protecting us.
My previous Corgi was not a barker at all.