Letting the shot go will let the enemy know that a sniper is around and where you are potentially. Keep the element of surprise by jumping in the air and letting go of the button. A message will pop up about only sniping with two feet on the ground and your shot won't go off. This is very risky and best left for experienced players. Instead switch to the auto-rifle and use your grenades.
Snipers seem to be equally effective for attacking and defending.
As defending goes, get the sniper to a high spot and cover an entrance. The enemy will have a hard time not losing men to the deadly red sight of the sniper. As attacking goes, the sniper is more effective than most people think. Sometimes, a sniper is a good idea to bring as backup. Move him into position and give cover to a comrade running with the flag.