"Patience and a little effort"
Since this skill is ubiquitous in life, and not inherent in just one activity, it can be developed anywhere. Imagine that you are standing in a huge queue, and the cashier is rather slowly punching the goods. Perhaps, usually in such situations, you start spinning, spinning, sighing heavily, and so on. But next time, try to just imagine yourself in the shoes of this tired cashier, or just tell yourself that you want to stop.
In fact, many people underestimate the power of conscious exhortation. It seems like a strange trick, but you can influence yourself with thinking.
Feelings of anger and resentment (bad beats, coolers, etc.) can be dealt with by constantly repeating to yourself the thought that this is part of the journey. You can even try hanging paper over your monitor screen like this.
By the way, not so long ago I saw one interesting piece of advice addressed to a bartender. The user wrote that a mirror should be installed behind him so that customers can see themselves in the reflection. And then they will see the manifestation of their negative emotions (anger), which can reduce the degree of tension (try looking at yourself with an angry face - it's just ridiculous). Therefore, if the feeling of anger is your second self, try hanging a mirror behind the monitor.