Overrides Drupal\Component\Plugin\PluginManagerBase::__construct().
public function __construct() {
// Create resource plugin derivatives from declaratively defined resources.
$this->discovery = new DerivativeDiscoveryDecorator(new AnnotatedClassDiscovery('rest', 'resource'));
$this->factory = new ReflectionFactory($this);
}