We get angry sometimes and so be it. Classrooms can't be all fun. Work is not always fun, and learning is work. But I think an important first step is an awareness of these relationships and principles of classroom management. Awareness helps us share these realities with students.
Awareness helps build and preserve the learning relationship.
Classrooms should be welcoming. Classrooms should be places where students always feel valued and encouraged, not belittled and degraded. When these relationships are solid, then students understand us and we can better understand them. And things will begin to improve - a lot.