public function registerPlugin($provider, $pluginId, $title, $mode, $script, Map $map)
    {
        $providerId = $this->getCompatibleProviderId($provider, $title, $mode, $script, $map);

        if (empty($providerId)) {
            return;
        }

        /** @var AbstractDataProvider $providerService */
        $providerService = $this->container->get($providerId);
        $pluginService = $this->container->get($pluginId);
        $interface = $this->providerInterfaces[$provider];

        if ($pluginService instanceof $interface) {
            $this->deletePlugin($provider, $pluginId);
            $providerService->registerPlugin($pluginId, $pluginService);
        } else {
            throw new UncompatibleException("Plugin $pluginId isn't compatible with $provider. Should be instance of $interface");
        }

        $this->logger->info("Plugin '$pluginId' will use data provider '$provider' : '$providerId'");
    }