janusgraph icon indicating copy to clipboard operation
janusgraph copied to clipboard

Draft: support opensearch 2.x

Open unautre opened this issue 10 months ago • 0 comments

Hello,

JanusGraph, as of right now, asks nicely the ElasticSearch instance about its version on graph opening. OpenSearch 1.x aimed to stay close to ElasticSearch 7.x, and says so in the default page:

$ curl -k http://localhost:9200/
{
  "name" : "1209e072b3e5",
  "cluster_name" : "docker-cluster",
  "cluster_uuid" : "UZkz1kSfRFyfeUDaq211Mg",
  "version" : {
    "number" : "7.17.28",
    "build_flavor" : "default",
    "build_type" : "docker",
    "build_hash" : "139cb5a961d8de68b8e02c45cc47f5289a3623af",
    "build_date" : "2025-02-20T09:05:31.349013687Z",
    "build_snapshot" : false,
    "lucene_version" : "8.11.3",
    "minimum_wire_compatibility_version" : "6.8.0",
    "minimum_index_compatibility_version" : "6.0.0-beta1"
  },
  "tagline" : "You Know, for Search"
}

OpenSearch, while mostly compatible with ElasticSearch, has different versions, and thus JanusGraph can't use it:

$ curl -k https://localhost:9200/ -u admin:admin
{
  "name" : "42a87b487a69",
  "cluster_name" : "docker-cluster",
  "cluster_uuid" : "zguXGxbDQuO-s6FcuEy_Lw",
  "version" : {
    "distribution" : "opensearch",
    "number" : "1.0.0",
    "build_type" : "tar",
    "build_hash" : "34550c5b17124ddc59458ef774f6b43a086522e3",
    "build_date" : "2021-07-02T23:22:21.383695Z",
    "build_snapshot" : false,
    "lucene_version" : "8.8.2",
    "minimum_wire_compatibility_version" : "6.8.0",
    "minimum_index_compatibility_version" : "6.0.0-beta1"
  },
  "tagline" : "The OpenSearch Project: https://opensearch.org/"
}

This pull request aims to fix that. It is still a Work In Progress, I intend to add unit tests to verify my changes soon(ish).

unautre avatar Mar 29 '25 09:03 unautre