diff --git a/extensions/elasticsearch-rest-client-common/deployment/src/main/java/io/quarkus/elasticsearch/restclient/common/deployment/DevServicesElasticsearchProcessor.java b/extensions/elasticsearch-rest-client-common/deployment/src/main/java/io/quarkus/elasticsearch/restclient/common/deployment/DevServicesElasticsearchProcessor.java index b1dc0461f5164..065acd241b0c0 100644 --- a/extensions/elasticsearch-rest-client-common/deployment/src/main/java/io/quarkus/elasticsearch/restclient/common/deployment/DevServicesElasticsearchProcessor.java +++ b/extensions/elasticsearch-rest-client-common/deployment/src/main/java/io/quarkus/elasticsearch/restclient/common/deployment/DevServicesElasticsearchProcessor.java @@ -268,7 +268,11 @@ private GenericContainer createOpensearchContainer(ElasticsearchDevServicesBu container.addEnv("bootstrap.memory_lock", "true"); container.addEnv("plugins.index_state_management.enabled", "false"); - + // Disable disk-based shard allocation thresholds: on large, relatively full disks (>90% used), + // it will lead to index creation to get stuck waiting for other nodes to join the cluster, + // which will never happen since we only have one node. + // See https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-settings/ + container.addEnv("cluster.routing.allocation.disk.threshold_enabled", "false"); container.addEnv("OPENSEARCH_JAVA_OPTS", config.javaOpts); return container; } diff --git a/integration-tests/hibernate-search-orm-opensearch/pom.xml b/integration-tests/hibernate-search-orm-opensearch/pom.xml index f01ba89671a49..0dbdd56c2eafc 100644 --- a/integration-tests/hibernate-search-orm-opensearch/pom.xml +++ b/integration-tests/hibernate-search-orm-opensearch/pom.xml @@ -189,6 +189,13 @@ See https://opensearch.org/docs/latest/im-plugin/ism/settings/ --> false + -Xms512m -Xmx512m + + false 9200:9200