A little piece of home automation. When iTunes (MacOS) starts or stops playing a track forward the event to RabbitMQ for further action.
In my case, turn power amps on/off using the WeMo power socket they are connected to - topic of another repository <-tba->.
I'm not an Objective-C programmer so I'm sure this is ugly code. But maybe somebody will find it handy.