More subtle and covert attempts (such as helping Cardassian dissidents against the Dominion) can be successful in ending conflict and bringing all sides to the negotiating table.
But the war must be for the purpose
of defense. Once an aggressor attacks, a nation must be willing to do (as the Constitution says) all that is Neccessary And Proper in order to defeat this enemy--through negotiation where possible, through military and covert action where neccessary.
And believe me...it often is