You are here

public function StandardSolrCloudConnector::getCheckpointsCollectionEndpoint in Search API Solr 4.x

Same name and namespace in other branches
  1. 8.3 src/Plugin/SolrConnector/StandardSolrCloudConnector.php \Drupal\search_api_solr\Plugin\SolrConnector\StandardSolrCloudConnector::getCheckpointsCollectionEndpoint()

Returns the Solr collection endpoint used to store topic checkpoints.

Return value

\Solarium\Core\Client\Endpoint|null Solr endpoint.

Overrides SolrCloudConnectorInterface::getCheckpointsCollectionEndpoint

1 call to StandardSolrCloudConnector::getCheckpointsCollectionEndpoint()
StandardSolrCloudConnector::deleteCheckpoints in src/Plugin/SolrConnector/StandardSolrCloudConnector.php
Deletes all checkpoints for given index/site.

File

src/Plugin/SolrConnector/StandardSolrCloudConnector.php, line 155

Class

StandardSolrCloudConnector
Standard Solr Cloud connector.

Namespace

Drupal\search_api_solr\Plugin\SolrConnector

Code

public function getCheckpointsCollectionEndpoint() : ?Endpoint {
  $checkpoints_collection = $this
    ->getCheckpointsCollectionName();
  if ($checkpoints_collection) {
    try {
      return $this
        ->getEndpoint($checkpoints_collection);
    } catch (OutOfBoundsException $e) {
      $additional_config['core'] = $checkpoints_collection;
      return $this
        ->createEndpoint($checkpoints_collection, $additional_config);
    }
  }
  return NULL;
}