From 401d4f71efff9d8e96550d5cbd9e1e6162416322 Mon Sep 17 00:00:00 2001 From: Patrick Werner Date: Thu, 9 Oct 2025 13:39:43 +0200 Subject: [PATCH] feat: add configuration for marking resources for reindexing upon search parameter change --- .../java/ca/uhn/fhir/jpa/starter/AppProperties.java | 10 ++++++++++ .../jpa/starter/common/FhirServerConfigCommon.java | 2 ++ 2 files changed, 12 insertions(+) diff --git a/src/main/java/ca/uhn/fhir/jpa/starter/AppProperties.java b/src/main/java/ca/uhn/fhir/jpa/starter/AppProperties.java index f10f693..fc1f318 100644 --- a/src/main/java/ca/uhn/fhir/jpa/starter/AppProperties.java +++ b/src/main/java/ca/uhn/fhir/jpa/starter/AppProperties.java @@ -118,6 +118,7 @@ public class AppProperties { private Map remote_terminology_service = null; private Boolean match_url_cache_enabled = false; private Boolean index_storage_optimized = false; + private Boolean mark_resources_for_reindexing_upon_search_parameter_change = true; public List getCustomInterceptorClasses() { return custom_interceptor_classes; @@ -785,6 +786,15 @@ public class AppProperties { index_storage_optimized = theIndex_storage_optimized; } + public Boolean getMark_resources_for_reindexing_upon_search_parameter_change() { + return mark_resources_for_reindexing_upon_search_parameter_change; + } + + public void setMark_resources_for_reindexing_upon_search_parameter_change( + Boolean mark_resources_for_reindexing_upon_search_parameter_change) { + this.mark_resources_for_reindexing_upon_search_parameter_change = mark_resources_for_reindexing_upon_search_parameter_change; + } + public JpaStorageSettings.StoreMetaSourceInformationEnum getStore_meta_source_information() { return store_meta_source_information; } diff --git a/src/main/java/ca/uhn/fhir/jpa/starter/common/FhirServerConfigCommon.java b/src/main/java/ca/uhn/fhir/jpa/starter/common/FhirServerConfigCommon.java index f28a2c6..ffc7515 100644 --- a/src/main/java/ca/uhn/fhir/jpa/starter/common/FhirServerConfigCommon.java +++ b/src/main/java/ca/uhn/fhir/jpa/starter/common/FhirServerConfigCommon.java @@ -187,6 +187,8 @@ public class FhirServerConfigCommon { jpaStorageSettings.setSchedulingDisabled(!appProperties.getDao_scheduling_enabled()); jpaStorageSettings.setIndexStorageOptimized(appProperties.getIndex_storage_optimized()); jpaStorageSettings.setMatchUrlCacheEnabled(appProperties.getMatch_url_cache_enabled()); + jpaStorageSettings.setMarkResourcesForReindexingUponSearchParameterChange( + appProperties.getMark_resources_for_reindexing_upon_search_parameter_change()); jpaStorageSettings.setDeleteEnabled(appProperties.getDelete_enabled()); jpaStorageSettings.setDeleteExpungeEnabled(appProperties.getDelete_expunge_enabled()); jpaStorageSettings.setExpungeEnabled(appProperties.getExpunge_enabled());