From 329441ae9c431015fa5cd79d0da18808eed0936c Mon Sep 17 00:00:00 2001 From: Yuxuan HU Date: Fri, 17 Jul 2026 16:08:33 +1000 Subject: [PATCH] enable explain endpoint for staging and prod --- .../au/org/aodn/ogcapi/server/common/RestAdminService.java | 4 ++-- server/src/main/resources/application-production.yaml | 4 ++++ server/src/main/resources/application-staging.yaml | 4 ++++ 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/server/src/main/java/au/org/aodn/ogcapi/server/common/RestAdminService.java b/server/src/main/java/au/org/aodn/ogcapi/server/common/RestAdminService.java index 0176f5e2..7f562e8a 100644 --- a/server/src/main/java/au/org/aodn/ogcapi/server/common/RestAdminService.java +++ b/server/src/main/java/au/org/aodn/ogcapi/server/common/RestAdminService.java @@ -20,8 +20,8 @@ public class RestAdminService { protected Search searchService; /** - * Value defined in application-*.yml, for dev and test, this value is set as true, - * for other environments, use default false value. + * Value defined in application-*.yml, set as true for dev, edge, staging, production and test. + * The default is false, so any environment that does not set it explicitly has explain disabled. */ public boolean isElasticsearchExplainEnabled() { return elasticsearchExplainEnabled; diff --git a/server/src/main/resources/application-production.yaml b/server/src/main/resources/application-production.yaml index 438f2b99..5a5b12c2 100644 --- a/server/src/main/resources/application-production.yaml +++ b/server/src/main/resources/application-production.yaml @@ -7,3 +7,7 @@ management: logging: level: au.org.aodn.ogcapi.server: info + +ogcapi: + debug: + elasticsearch-explain-enabled: true diff --git a/server/src/main/resources/application-staging.yaml b/server/src/main/resources/application-staging.yaml index f25750bb..63749f0e 100644 --- a/server/src/main/resources/application-staging.yaml +++ b/server/src/main/resources/application-staging.yaml @@ -3,3 +3,7 @@ management: web: exposure: include: "health,info,env,beans,logfile" + +ogcapi: + debug: + elasticsearch-explain-enabled: true