It can be worthwhile to risk a counterattack if you are taking an enemy factory, and is usually worthwhile to take an enemy capital. Attack and then withdraw before destroying the opposing force, which could leave you vulnerable to an enemy counterattack. Spoiling Attacks can be an important tactic. Don't attack if you are going to destroyed with a counterattack. The basic rule for good play in Axis & Allies is Don't fight a battle you're not going to win.