Use ruflin/Elastica instead of nodespark/des-connector

Created on 7 December 2020, over 4 years ago
Updated 4 June 2025, 24 days ago

Problem/Motivation

https://github.com/nodespark/des-connector is very Drupal specific solution and it doesn't support PHP 8.
To decrease the maintenance burden, we should change to official PHP client for Elasticsearch.

Steps to reproduce

-

Proposed resolution

Use https://github.com/ruflin/Elastica instead of https://github.com/nodespark/des-connector

Remaining tasks

  1. — released in 8.0.0-alpha1

User interface changes

None

API changes

  1. Changed module dependencies in composer.json
  2. Service elasticsearch_connector.client_factory went away.
  3. \Drupal\elasticsearch_connector\ClusterManager moved namespaces to \Drupal\elasticsearch_connector\ElasticSearch\ClusterManager and got better type hints
  4. A number of functions in \Drupal\elasticsearch_connector\Controller\ClusterListBuilder, \Drupal\elasticsearch_connector\Controller\ElasticsearchController, and \Drupal\elasticsearch_connector\Entity\Cluster got better type hints
  5. A number of functions in \Drupal\elasticsearch_connector\ElasticSearch\ClientManager changed names/signatures
  6. In \Drupal\elasticsearch_connector\ElasticSearch\ClientManagerInterface, ::__construct() was removed; and ::getClientForCluster() was renamed to ::getClient().
  7. Many changes to \Drupal\elasticsearch_connector\Elasticsearch\Parameters\Builder\SearchBuilder
  8. \Drupal\elasticsearch_connector\ElasticSearch\Parameters\Factory\SearchFactory's parseResult() changed signatures.
  9. Added \Drupal\elasticsearch_connector\Event\BuildSearchQueryEvent and \Drupal\elasticsearch_connector\Event\PrepareDocumentIndexEvent
  10. Changes to \Drupal\elasticsearch_connector\Event\PrepareIndexEvent's ::__construct() signatures; better type hints for ::getIndexConfig() and ::setIndexConfig(); ::getIndexName() was removed; ::getIndex() was added.

Data model changes

None.

📌 Task
Status

Fixed

Version

8.0

Component

Code

Created by

🇫🇮Finland sokru

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024