Last active
August 18, 2025 14:48
-
-
Save Phate334/9fd90ddce0eaea74086c1a2e5d419402 to your computer and use it in GitHub Desktop.
JanusGraph and OpenSearch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| version: "3" | |
| services: | |
| janusgraph: | |
| image: janusgraph/janusgraph:0.6.2 | |
| container_name: jce-janusgraph | |
| env_file: | |
| - janusgraph.env | |
| ports: | |
| - "8182:8182" | |
| networks: | |
| - jce-network | |
| depends_on: | |
| - cassandra | |
| - opensearch | |
| cassandra: | |
| image: cassandra:3 | |
| container_name: jce-cassandra | |
| ports: | |
| - "9042:9042" | |
| - "9160:9160" | |
| networks: | |
| - jce-network | |
| volumes: | |
| - janusgraph-data:/var/lib/cassandra | |
| opensearch: | |
| image: docker.io/opensearchproject/opensearch:2.4.0 | |
| container_name: jce-elastic | |
| hostname: jce-elastic | |
| env_file: | |
| - opensearch.env | |
| ports: | |
| - 9200:9200 # REST API | |
| - 9600:9600 # Performance Analyzer | |
| networks: | |
| - jce-network | |
| volumes: | |
| - janusgraph-index:/usr/share/opensearch/data | |
| dashboard: | |
| image: opensearchproject/opensearch-dashboards:2.4.0 | |
| container_name: opensearch-dashboards | |
| ports: | |
| - 5601:5601 | |
| environment: | |
| OPENSEARCH_HOSTS: '["https://opensearch:9200"]' | |
| networks: | |
| - jce-network | |
| networks: | |
| jce-network: | |
| volumes: | |
| janusgraph-index: | |
| janusgraph-data: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| JANUS_PROPS_TEMPLATE=cql-es | |
| janusgraph.storage.hostname=jce-cassandra | |
| janusgraph.graph.replace-instance-if-exists=true | |
| janusgraph.query.batch=true | |
| index.search.backend=elasticsearch | |
| janusgraph.index.search.hostname=jce-elastic | |
| janusgraph.index.search.elasticsearch.http.auth.type=BASIC | |
| janusgraph.index.search.elasticsearch.http.auth.basic.username=admin | |
| janusgraph.index.search.elasticsearch.http.auth.basic.password=admin | |
| janusgraph.index.search.elasticsearch.ssl.enabled=true | |
| janusgraph.index.search.elasticsearch.ssl.disable-hostname-verification=true | |
| janusgraph.index.search.elasticsearch.ssl.allow-self-signed-certificates=true | |
| janusgraph.metrics.enabled=true | |
| janusgraph.metrics.csvReporter.enabled=false | |
| janusgraph.metrics.slf4jReporter.enabled=false | |
| janusgraph.metrics.jmx.enabled=false | |
| gremlinserver.channelizer=org.apache.tinkerpop.gremlin.server.channel.WsAndHttpChannelizer | |
| gremlinserver.metrics.csvReporter.enabled=false | |
| gremlinserver.metrics.jmxReporter.enabled=false | |
| gremlinserver.metrics.slf4jReporter.enabled=false | |
| gremlinserver.threadPoolWorker=2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| http.host=0.0.0.0 | |
| network.host=0.0.0.0 | |
| transport.host=127.0.0.1 | |
| cluster.name=opensearch-cluster # Name the cluster | |
| node.name=jce-elastic # Name the node that will run in this container | |
| discovery.type=single-node | |
| compatibility.override_main_response_version=true | |
| bootstrap.memory_lock=true # Disable JVM heap memory swapping | |
| OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m # Set min and max JVM heap sizes to at least 50% of system RAM |
Sorry, I haven’t used JanusGraph for a while so I’m not able to help. Have there been any changes in the recent versions?
Everything is fine, except that JanusGraph still has to pretend that it's using ElasticSearch, not OpenSearch.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
I got https://github.com/humemai/janusgraph/blob/opensearch/janusgraph-dist/docker/examples/docker-compose-cql-es.yml working.
Just doing
docker compose -f docker-compose-cql-es.yml upworks, without the env files. I also tried opensearch v3, but it doesn't work. I think it has some breaking changes.