'Create and return a new registry for the given database name.'

@classmethod
def new(cls, db_name, force_demo=False, status=None, update_module=False):

    with cls._lock:
        with odoo.api.Environment.manage():
            registry = object.__new__(cls)
            registry.init(db_name)
            cls.delete(db_name)
            cls.registries[db_name] = registry
            try:
                registry.setup_signaling()
                odoo.modules.load_modules(registry._db, force_demo, status, update_module)
            except Exception:
                _logger.exception('Failed    to    load    registry')
                del cls.registries[db_name]
                raise
            init_parent = registry._init_parent
            registry = cls.registries[db_name]
            registry._init_parent.update(init_parent)
            with closing(registry.cursor()) as cr:
                registry.do_parent_store(cr)
                cr.commit()
    registry.ready = True
    if update_module:
        registry.signal_registry_change()
    return registry
