Some more improvements. Support for complex messages.