public static function registerMapping(array $config)
    {
        self::validateConfig($config);
        if (isset(self::$mappings[$config['name']]) === false) {
            self::$mappings[$config['name']] = array(
                'config' => $config
            );
            Database::registerDatabase($config['database']);
        } else {
            Logger::get()->warning('mapping with name "' . $config['name'] . '" was already set');
        }
    }