In my mind this ends only when it is approached properly. Half of the debates I see on this topic are either racially, or religiously based, until that stops no one is going to get anywhere. Who cares about skin colour, or religion, I mean genuinely? Would it really matter to any of us if acts of terror were not being committed?
Religion and race are not grounds for the actions taken by these people. By "these people" I mean those degenerates who could be classified as extremists, or terrorists. That's a demographic independent of religion or race. There have been some in every race, and of every religion.
What this comes down to is a widespread group of people behaving in a way that is wrong. Call it unprincipled, call it immoral, it comes down to the same thing. They have no honor, they have no respect, they have no compassion, and they are driven by hate.
A unified body will be required to face this kind of threat. Not one defined by a nation, religion, or culture, because every one of those has its own pitfalls. This body would have to be entirely comprised of individuals of a selfless nature, each committed to adhering to a set of defining boundaries and commitments. They will not be flawless, but they will not become their adversary. The commitment needs to be in stopping bad people from doing bad things, not in attacking Muslims or brown people.
That will likely never be of course, we're quite adept at voicing our opinions but never taking action. We happily sit back and deplore the actions of others, but that's where the easy part ends, and not so coincidentally, our personal involvement. From that angle we have a striking resemblance to a small dog, barking at people we don't like from the safety of our lawns, and cowering instantly if one of them elects to face us.
The situation will degrade, and we will watch, passive observation brought us here. If you disagree, don't waste your time typing out some long winded hate mail I'll only approach like a satirical paper. If you really disagree, prove me wrong.