Refactor the module-patching mechanism.
Make the Registry compatible with Odoo 8.0.
Make `get_raw_message` always return bytes.