Jesus was a man of peace. He did not come to a world absent of war. Rather, he came to create a community that slowly created a world where war is unnecessary, where everyone's needs are met and the greedy are punished.
Jesus offered his true followers-- those obedient to his love and mercy-- peace (John 14:27). He commanded his people to always seek peace (Mark 9:50; Romans 12:18). He said his true followers would step into the world and make peace out of conflict (Matthew 5:9). He said that not a single human being should be excluded from the love and gentleness of his people (Luke 6:27-36)
So why did Jesus say, "I did not come to give peace but a sword." (Matthew 10:34)? Because he knew the established order is opposed to peace. The established order must always have people they exclude, must always have fear, must always have conflict or else their whole system will collapse. (Matthew 23:23-27) Jesus' way of peace is in a spiritual war against this philosophy. And Jesus will not cringe from battling in that war.
But Jesus has transferred the battlefield to the spirit realm (Mark 3:22-27). So Jesus will never attack human beings, but the ideas and spirits that cause human beings to do evil. Jesus and his community stands in the way of violence, especially against the oppressed and outcast, allowing themselves to take the sword that was meant for the rejected ones.