public function getPluginViewData(
        $pluginName,
        $pluginInstanceId,
        $forcedAlternativeInstanceConfig = null
    ) {
        $request = ServerRequestFactory::fromGlobals();

        $blockConfig = $this->blockConfigRepository->findById($pluginName);

        if ($pluginInstanceId < 0) {
            $instanceWithData = new InstanceWithDataBasic(
                $pluginInstanceId,
                $pluginName,
                $blockConfig->getDefaultConfig(),
                null //@TODO run the dataprovider here instead of returning null
            );
        } else {
            $instanceWithData = $this->instanceWithDataService->__invoke($pluginInstanceId, $request);
        }

        if ($forcedAlternativeInstanceConfig !== null) {
            $instanceWithData = new InstanceWithDataBasic(
                $instanceWithData->getId(),
                $instanceWithData->getName(),
                $forcedAlternativeInstanceConfig,
                //@TODO we should have got the data from the data provider with the forced instance config as an input
                $instanceWithData->getData()
            );
        }

        $html = $this->blockRendererService->__invoke($instanceWithData);

        /**
         * @var $blockConfig Config
         */

        $return = [
            'html' => $html,
            'css' => [],
            'js' => [],
            'editJs' => '',
            'editCss' => '',
            'displayName' => $blockConfig->getLabel(),
            'tooltip' => $blockConfig->getDescription(),
            'icon' => $blockConfig->getIcon(),
            'siteWide' => false, // @deprecated <deprecated-site-wide-plugin>
            'md5' => '',
            'fromCache' => false,
            'canCache' => $blockConfig->getCache(),
            'pluginName' => $blockConfig->getName(),
            'pluginInstanceId' => $pluginInstanceId,
        ];

        return $return;
    }