Merge branch 'master' into ja_20250502_improve_dialect_handling

This commit is contained in:
James Agnew
2025-06-25 17:05:08 -04:00
committed by GitHub
9 changed files with 38 additions and 9 deletions

View File

@@ -6,7 +6,7 @@
<properties> <properties>
<java.version>17</java.version> <java.version>17</java.version>
<hapi.fhir.jpa.server.starter.revision>1</hapi.fhir.jpa.server.starter.revision> <hapi.fhir.jpa.server.starter.revision>1</hapi.fhir.jpa.server.starter.revision>
<clinical-reasoning.version>3.21.0</clinical-reasoning.version> <clinical-reasoning.version>3.22.0</clinical-reasoning.version>
</properties> </properties>
<!-- one-liner to take you to the cloud with settings form the application.yaml file: --> <!-- one-liner to take you to the cloud with settings form the application.yaml file: -->

View File

@@ -1,6 +1,7 @@
package ca.uhn.fhir.jpa.starter; package ca.uhn.fhir.jpa.starter;
import ca.uhn.fhir.context.FhirVersionEnum; import ca.uhn.fhir.context.FhirVersionEnum;
import ca.uhn.fhir.jpa.api.config.JpaStorageSettings;
import ca.uhn.fhir.jpa.api.config.JpaStorageSettings.ClientIdStrategyEnum; import ca.uhn.fhir.jpa.api.config.JpaStorageSettings.ClientIdStrategyEnum;
import ca.uhn.fhir.jpa.api.config.JpaStorageSettings.IdStrategyEnum; import ca.uhn.fhir.jpa.api.config.JpaStorageSettings.IdStrategyEnum;
import ca.uhn.fhir.jpa.model.entity.NormalizedQuantitySearchLevel; import ca.uhn.fhir.jpa.model.entity.NormalizedQuantitySearchLevel;
@@ -36,6 +37,7 @@ public class AppProperties {
private Boolean mdm_enabled = false; private Boolean mdm_enabled = false;
private String mdm_rules_json_location = "mdm-rules.json"; private String mdm_rules_json_location = "mdm-rules.json";
private boolean advanced_lucene_indexing = false; private boolean advanced_lucene_indexing = false;
private boolean search_index_full_text_enabled = false;
private boolean enable_index_of_type = false; private boolean enable_index_of_type = false;
private Boolean allow_cascading_deletes = false; private Boolean allow_cascading_deletes = false;
private Boolean allow_contains_searches = true; private Boolean allow_contains_searches = true;
@@ -108,6 +110,8 @@ public class AppProperties {
private Integer pre_expand_value_sets_default_count = 1000; private Integer pre_expand_value_sets_default_count = 1000;
private Integer pre_expand_value_sets_max_count = 1000; private Integer pre_expand_value_sets_max_count = 1000;
private Integer maximum_expansion_size = 1000; private Integer maximum_expansion_size = 1000;
private JpaStorageSettings.StoreMetaSourceInformationEnum store_meta_source_information =
JpaStorageSettings.StoreMetaSourceInformationEnum.NONE;
private Map<String, RemoteSystem> remote_terminology_service = null; private Map<String, RemoteSystem> remote_terminology_service = null;
private Boolean match_url_cache_enabled = false; private Boolean match_url_cache_enabled = false;
@@ -289,6 +293,14 @@ public class AppProperties {
advanced_lucene_indexing = theAdvanced_lucene_indexing; advanced_lucene_indexing = theAdvanced_lucene_indexing;
} }
public boolean getSearch_index_full_text_enabled() {
return this.search_index_full_text_enabled;
}
public void setSearch_index_full_text_enabled(boolean theSearch_index_full_text_enabled) {
search_index_full_text_enabled = theSearch_index_full_text_enabled;
}
public Boolean getAllow_cascading_deletes() { public Boolean getAllow_cascading_deletes() {
return allow_cascading_deletes; return allow_cascading_deletes;
} }
@@ -760,6 +772,15 @@ public class AppProperties {
public void setIndex_storage_optimized(boolean theIndex_storage_optimized) { public void setIndex_storage_optimized(boolean theIndex_storage_optimized) {
index_storage_optimized = theIndex_storage_optimized; index_storage_optimized = theIndex_storage_optimized;
}
public JpaStorageSettings.StoreMetaSourceInformationEnum getStore_meta_source_information() {
return store_meta_source_information;
}
public void setStore_meta_source_information(
JpaStorageSettings.StoreMetaSourceInformationEnum store_meta_source_information) {
this.store_meta_source_information = store_meta_source_information;
} }
public static class Cors { public static class Cors {

View File

@@ -1,12 +1,11 @@
package ca.uhn.fhir.jpa.starter.cdshooks; package ca.uhn.fhir.jpa.starter.cdshooks;
import ca.uhn.fhir.context.FhirVersionEnum; import ca.uhn.fhir.context.FhirVersionEnum;
import ca.uhn.fhir.repository.IRepository;
import ca.uhn.fhir.rest.api.server.RequestDetails; import ca.uhn.fhir.rest.api.server.RequestDetails;
import ca.uhn.fhir.rest.api.server.cdshooks.CdsServiceRequestJson; import ca.uhn.fhir.rest.api.server.cdshooks.CdsServiceRequestJson;
import ca.uhn.hapi.fhir.cdshooks.api.ICdsConfigService;
import org.hl7.fhir.instance.model.api.IBaseParameters; import org.hl7.fhir.instance.model.api.IBaseParameters;
import org.hl7.fhir.instance.model.api.IPrimitiveType; import org.hl7.fhir.instance.model.api.IPrimitiveType;
import org.opencds.cqf.fhir.api.Repository;
import org.opencds.cqf.fhir.cr.hapi.cdshooks.CdsCrService; import org.opencds.cqf.fhir.cr.hapi.cdshooks.CdsCrService;
import org.opencds.cqf.fhir.utility.adapter.IAdapterFactory; import org.opencds.cqf.fhir.utility.adapter.IAdapterFactory;
@@ -15,9 +14,8 @@ import static org.opencds.cqf.fhir.utility.Constants.APPLY_PARAMETER_DATA;
public class UpdatedCdsCrService extends CdsCrService { public class UpdatedCdsCrService extends CdsCrService {
private final IAdapterFactory adapterFactory; private final IAdapterFactory adapterFactory;
public UpdatedCdsCrService( public UpdatedCdsCrService(RequestDetails theRequestDetails, IRepository theRepository) {
RequestDetails theRequestDetails, Repository theRepository, ICdsConfigService theCdsConfigService) { super(theRequestDetails, theRepository);
super(theRequestDetails, theRepository, theCdsConfigService);
adapterFactory = IAdapterFactory.forFhirContext(theRepository.fhirContext()); adapterFactory = IAdapterFactory.forFhirContext(theRepository.fhirContext());
} }

View File

@@ -1,11 +1,11 @@
package ca.uhn.fhir.jpa.starter.cdshooks; package ca.uhn.fhir.jpa.starter.cdshooks;
import ca.uhn.fhir.repository.IRepository;
import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.instance.model.api.IIdType;
import org.opencds.cqf.fhir.api.Repository;
import org.opencds.cqf.fhir.cr.hapi.cdshooks.discovery.CrDiscoveryService; import org.opencds.cqf.fhir.cr.hapi.cdshooks.discovery.CrDiscoveryService;
public class UpdatedCrDiscoveryService extends CrDiscoveryService { public class UpdatedCrDiscoveryService extends CrDiscoveryService {
public UpdatedCrDiscoveryService(IIdType thePlanDefinitionId, Repository theRepository) { public UpdatedCrDiscoveryService(IIdType thePlanDefinitionId, IRepository theRepository) {
super(thePlanDefinitionId, theRepository); super(thePlanDefinitionId, theRepository);
maxUriLength = 6000; maxUriLength = 6000;
} }

View File

@@ -206,6 +206,7 @@ public class FhirServerConfigCommon {
jpaStorageSettings.setFilterParameterEnabled(appProperties.getFilter_search_enabled()); jpaStorageSettings.setFilterParameterEnabled(appProperties.getFilter_search_enabled());
jpaStorageSettings.setHibernateSearchIndexSearchParams(appProperties.getAdvanced_lucene_indexing()); jpaStorageSettings.setHibernateSearchIndexSearchParams(appProperties.getAdvanced_lucene_indexing());
jpaStorageSettings.setHibernateSearchIndexFullText(appProperties.getSearch_index_full_text_enabled());
jpaStorageSettings.setTreatBaseUrlsAsLocal(new HashSet<>(appProperties.getLocal_base_urls())); jpaStorageSettings.setTreatBaseUrlsAsLocal(new HashSet<>(appProperties.getLocal_base_urls()));
jpaStorageSettings.setTreatReferencesAsLogical(new HashSet<>(appProperties.getLogical_urls())); jpaStorageSettings.setTreatReferencesAsLogical(new HashSet<>(appProperties.getLogical_urls()));
@@ -258,6 +259,10 @@ public class FhirServerConfigCommon {
jpaStorageSettings.setBundleBatchPoolSize(appProperties.getBundle_batch_pool_size()); jpaStorageSettings.setBundleBatchPoolSize(appProperties.getBundle_batch_pool_size());
jpaStorageSettings.setBundleBatchPoolSize(appProperties.getBundle_batch_pool_max_size()); jpaStorageSettings.setBundleBatchPoolSize(appProperties.getBundle_batch_pool_max_size());
// Set store meta source information
ourLog.debug("Server configured to Store Meta Source: {}", appProperties.getStore_meta_source_information());
jpaStorageSettings.setStoreMetaSourceInformation(appProperties.getStore_meta_source_information());
storageSettings(appProperties, jpaStorageSettings); storageSettings(appProperties, jpaStorageSettings);
return jpaStorageSettings; return jpaStorageSettings;
} }

View File

@@ -204,6 +204,7 @@ hapi:
### !!Extended Lucene/Elasticsearch Indexing is still a experimental feature, expect some features (e.g. _total=accurate) to not work as expected!! ### !!Extended Lucene/Elasticsearch Indexing is still a experimental feature, expect some features (e.g. _total=accurate) to not work as expected!!
### more information here: https://hapifhir.io/hapi-fhir/docs/server_jpa/elastic.html ### more information here: https://hapifhir.io/hapi-fhir/docs/server_jpa/elastic.html
advanced_lucene_indexing: false advanced_lucene_indexing: false
search_index_full_text_enabled: false
bulk_export_enabled: false bulk_export_enabled: false
bulk_import_enabled: false bulk_import_enabled: false
# language_search_parameter_enabled: true # language_search_parameter_enabled: true
@@ -294,7 +295,8 @@ hapi:
# classes listed here will be fetched from the Spring context when combined with 'custom-bean-packages', # classes listed here will be fetched from the Spring context when combined with 'custom-bean-packages',
# or will be instantiated via reflection using an no-arg contructor; then registered with the server # or will be instantiated via reflection using an no-arg contructor; then registered with the server
#custom-provider-classes: #custom-provider-classes:
# specify what should be stored in meta.source based on StoreMetaSourceInformationEnum defaults to NONE
# store_meta_source_information: NONE
# Threadpool size for BATCH'ed GETs in a bundle. # Threadpool size for BATCH'ed GETs in a bundle.
# bundle_batch_pool_size: 10 # bundle_batch_pool_size: 10
# bundle_batch_pool_max_size: 50 # bundle_batch_pool_max_size: 50

View File

@@ -196,6 +196,7 @@ hapi:
### !!Extended Lucene/Elasticsearch Indexing is still a experimental feature, expect some features (e.g. _total=accurate) to not work as expected!! ### !!Extended Lucene/Elasticsearch Indexing is still a experimental feature, expect some features (e.g. _total=accurate) to not work as expected!!
### more information here: https://hapifhir.io/hapi-fhir/docs/server_jpa/elastic.html ### more information here: https://hapifhir.io/hapi-fhir/docs/server_jpa/elastic.html
advanced_lucene_indexing: false advanced_lucene_indexing: false
search_index_full_text_enabled: false
bulk_export_enabled: false bulk_export_enabled: false
bulk_import_enabled: false bulk_import_enabled: false
# language_search_parameter_enabled: true # language_search_parameter_enabled: true

View File

@@ -52,6 +52,7 @@ import org.testcontainers.junit.jupiter.Testcontainers;
"hapi.fhir.lastn_enabled=true", "hapi.fhir.lastn_enabled=true",
"hapi.fhir.store_resource_in_lucene_index_enabled=true", "hapi.fhir.store_resource_in_lucene_index_enabled=true",
"hapi.fhir.advanced_lucene_indexing=true", "hapi.fhir.advanced_lucene_indexing=true",
"hapi.fhir.search_index_full_text_enabled=true",
"elasticsearch.enabled=true", "elasticsearch.enabled=true",
"hapi.fhir.cr_enabled=false", "hapi.fhir.cr_enabled=false",

View File

@@ -129,6 +129,7 @@ hapi:
### !!Extended Lucene/Elasticsearch Indexing is still a experimental feature, expect some features (e.g. _total=accurate) to not work as expected!! ### !!Extended Lucene/Elasticsearch Indexing is still a experimental feature, expect some features (e.g. _total=accurate) to not work as expected!!
### more information here: https://hapifhir.io/hapi-fhir/docs/server_jpa/elastic.html ### more information here: https://hapifhir.io/hapi-fhir/docs/server_jpa/elastic.html
advanced_lucene_indexing: false advanced_lucene_indexing: false
search_index_full_text_enabled: false
# enforce_referential_integrity_on_delete: false # enforce_referential_integrity_on_delete: false
# This is an experimental feature, and does not fully support _total and other FHIR features. # This is an experimental feature, and does not fully support _total and other FHIR features.
# enforce_referential_integrity_on_delete: false # enforce_referential_integrity_on_delete: false