Please read the narrations in Bukhari that The Holy Prophet advised Companion to be patient when their rights will be taken away and be patient until you meet me at the pond of Kauthar.
The Holy Prophet also advised his Companions to be patient and be united.
In the light such narrations in Bukhari, we can easily understand the actions of Imam Ali, How Imam Ali remained patient for the sake of Islam and Muslim Ummah!
http://sunnah.com/bukhari/92/9
URDU TRANSLATION:
Please read the next narration.
http://sunnah.com/bukhari/92/7
URDU TRANSLATION: