Renamed registerHandler to subscribe according to MQTT specification