Package com.ibm.fhir.config
Class FHIRConfiguration
- java.lang.Object
-
- com.ibm.fhir.config.FHIRConfiguration
-
public class FHIRConfiguration extends Object
This class serves up a singleton instance of ConfigurationService containing the FHIR Server's configuration.
-
-
Field Summary
-
Constructor Summary
Constructors Constructor Description FHIRConfiguration()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clearConfiguration()
Clears the entire cache of configuration objects.static String
getConfigHome()
Returns the "home" directory for FHIR Server configuration information (this directory will contain the "config" directory, etc.).List<String>
getConfiguredTenants()
This method returns the list of tenant id's for which a configuration exists.static FHIRConfiguration
getInstance()
PropertyGroup
loadConfiguration()
Retrieves the FHIR Server default configuration and returns it as a PropertyGroup.PropertyGroup
loadConfigurationForTenant(String tenantId)
Loads the configuration for the specified tenant id.static void
setConfigHome(String s)
This method is used to configure an explicit top-level directory where FHIR Server configuration information is expected to reside.
-
-
-
Field Detail
-
CONFIG_LOCATION
public static final String CONFIG_LOCATION
- See Also:
- Constant Field Values
-
CONFIG_FILE_BASENAME
public static final String CONFIG_FILE_BASENAME
- See Also:
- Constant Field Values
-
DEFAULT_TENANT_ID
public static final String DEFAULT_TENANT_ID
- See Also:
- Constant Field Values
-
DEFAULT_DATASTORE_ID
public static final String DEFAULT_DATASTORE_ID
- See Also:
- Constant Field Values
-
PROPERTY_ORIGINAL_REQUEST_URI_HEADER_NAME
public static final String PROPERTY_ORIGINAL_REQUEST_URI_HEADER_NAME
- See Also:
- Constant Field Values
-
PROPERTY_TENANT_ID_HEADER_NAME
public static final String PROPERTY_TENANT_ID_HEADER_NAME
- See Also:
- Constant Field Values
-
PROPERTY_DATASTORE_ID_HEADER_NAME
public static final String PROPERTY_DATASTORE_ID_HEADER_NAME
- See Also:
- Constant Field Values
-
PROPERTY_DEFAULT_TENANT_ID
public static final String PROPERTY_DEFAULT_TENANT_ID
- See Also:
- Constant Field Values
-
PROPERTY_DEFAULT_PRETTY_PRINT
public static final String PROPERTY_DEFAULT_PRETTY_PRINT
- See Also:
- Constant Field Values
-
PROPERTY_DEFAULT_HANDLING
public static final String PROPERTY_DEFAULT_HANDLING
- See Also:
- Constant Field Values
-
PROPERTY_ALLOW_CLIENT_HANDLING_PREF
public static final String PROPERTY_ALLOW_CLIENT_HANDLING_PREF
- See Also:
- Constant Field Values
-
PROPERTY_CHECK_REFERENCE_TYPES
public static final String PROPERTY_CHECK_REFERENCE_TYPES
- See Also:
- Constant Field Values
-
PROPERTY_CONDITIONAL_DELETE_MAX_NUMBER
public static final String PROPERTY_CONDITIONAL_DELETE_MAX_NUMBER
- See Also:
- Constant Field Values
-
PROPERTY_SERVER_REGISTRY_RESOURCE_PROVIDER_ENABLED
public static final String PROPERTY_SERVER_REGISTRY_RESOURCE_PROVIDER_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_SERVER_RESOLVE_FUNCTION_ENABLED
public static final String PROPERTY_SERVER_RESOLVE_FUNCTION_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_CAPABILITY_STATEMENT_CACHE
public static final String PROPERTY_CAPABILITY_STATEMENT_CACHE
- See Also:
- Constant Field Values
-
PROPERTY_EXTENDED_CODEABLE_CONCEPT_VALIDATION
public static final String PROPERTY_EXTENDED_CODEABLE_CONCEPT_VALIDATION
- See Also:
- Constant Field Values
-
PROPERTY_DISABLED_OPERATIONS
public static final String PROPERTY_DISABLED_OPERATIONS
- See Also:
- Constant Field Values
-
PROPERTY_DEFAULT_PAGE_SIZE
public static final String PROPERTY_DEFAULT_PAGE_SIZE
- See Also:
- Constant Field Values
-
PROPERTY_MAX_PAGE_SIZE
public static final String PROPERTY_MAX_PAGE_SIZE
- See Also:
- Constant Field Values
-
PROPERTY_MAX_PAGE_INCLUDE_COUNT
public static final String PROPERTY_MAX_PAGE_INCLUDE_COUNT
- See Also:
- Constant Field Values
-
PROPERTY_CAPABILITIES_URL
public static final String PROPERTY_CAPABILITIES_URL
- See Also:
- Constant Field Values
-
PROPERTY_VALIDATION_FAIL_FAST
public static final String PROPERTY_VALIDATION_FAIL_FAST
- See Also:
- Constant Field Values
-
PROPERTY_TERM_SERVICE_CAPABILITIES_URL
public static final String PROPERTY_TERM_SERVICE_CAPABILITIES_URL
- See Also:
- Constant Field Values
-
PROPERTY_GRAPH_TERM_SERVICE_PROVIDER_ENABLED
public static final String PROPERTY_GRAPH_TERM_SERVICE_PROVIDER_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_GRAPH_TERM_SERVICE_PROVIDER_TIME_LIMIT
public static final String PROPERTY_GRAPH_TERM_SERVICE_PROVIDER_TIME_LIMIT
- See Also:
- Constant Field Values
-
PROPERTY_GRAPH_TERM_SERVICE_PROVIDER_CONFIGURATION
public static final String PROPERTY_GRAPH_TERM_SERVICE_PROVIDER_CONFIGURATION
- See Also:
- Constant Field Values
-
PROPERTY_RESOURCES
public static final String PROPERTY_RESOURCES
- See Also:
- Constant Field Values
-
PROPERTY_FIELD_RESOURCES_OPEN
public static final String PROPERTY_FIELD_RESOURCES_OPEN
- See Also:
- Constant Field Values
-
PROPERTY_FIELD_RESOURCES_INTERACTIONS
public static final String PROPERTY_FIELD_RESOURCES_INTERACTIONS
- See Also:
- Constant Field Values
-
PROPERTY_FIELD_RESOURCES_SEARCH_PARAMETERS
public static final String PROPERTY_FIELD_RESOURCES_SEARCH_PARAMETERS
- See Also:
- Constant Field Values
-
PROPERTY_FIELD_RESOURCES_SEARCH_INCLUDES
public static final String PROPERTY_FIELD_RESOURCES_SEARCH_INCLUDES
- See Also:
- Constant Field Values
-
PROPERTY_FIELD_RESOURCES_SEARCH_REV_INCLUDES
public static final String PROPERTY_FIELD_RESOURCES_SEARCH_REV_INCLUDES
- See Also:
- Constant Field Values
-
PROPERTY_FIELD_RESOURCES_SEARCH_PARAMETER_COMBINATIONS
public static final String PROPERTY_FIELD_RESOURCES_SEARCH_PARAMETER_COMBINATIONS
- See Also:
- Constant Field Values
-
PROPERTY_FIELD_RESOURCES_PROFILES
public static final String PROPERTY_FIELD_RESOURCES_PROFILES
- See Also:
- Constant Field Values
-
PROPERTY_FIELD_RESOURCES_PROFILES_AT_LEAST_ONE
public static final String PROPERTY_FIELD_RESOURCES_PROFILES_AT_LEAST_ONE
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_CORS
public static final String PROPERTY_SECURITY_CORS
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_BASIC_ENABLED
public static final String PROPERTY_SECURITY_BASIC_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_CERT_ENABLED
public static final String PROPERTY_SECURITY_CERT_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_OAUTH_ENABLED
public static final String PROPERTY_SECURITY_OAUTH_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_OAUTH_REG_URL
public static final String PROPERTY_SECURITY_OAUTH_REG_URL
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_OAUTH_AUTH_URL
public static final String PROPERTY_SECURITY_OAUTH_AUTH_URL
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_OAUTH_TOKEN_URL
public static final String PROPERTY_SECURITY_OAUTH_TOKEN_URL
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_OAUTH_MANAGE_URL
public static final String PROPERTY_SECURITY_OAUTH_MANAGE_URL
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_OAUTH_INTROSPECT_URL
public static final String PROPERTY_SECURITY_OAUTH_INTROSPECT_URL
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_OAUTH_REVOKE_URL
public static final String PROPERTY_SECURITY_OAUTH_REVOKE_URL
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_OAUTH_SMART_ENABLED
public static final String PROPERTY_SECURITY_OAUTH_SMART_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_OAUTH_SMART_SCOPES
public static final String PROPERTY_SECURITY_OAUTH_SMART_SCOPES
- See Also:
- Constant Field Values
-
PROPERTY_SECURITY_OAUTH_SMART_CAPABILITIES
public static final String PROPERTY_SECURITY_OAUTH_SMART_CAPABILITIES
- See Also:
- Constant Field Values
-
PROPERTY_AUDIT_SERVICE_CLASS_NAME
public static final String PROPERTY_AUDIT_SERVICE_CLASS_NAME
- See Also:
- Constant Field Values
-
PROPERTY_AUDIT_SERVICE_PROPERTIES
public static final String PROPERTY_AUDIT_SERVICE_PROPERTIES
- See Also:
- Constant Field Values
-
PROPERTY_AUDIT_PATIENT_ID_EXTURL
public static final String PROPERTY_AUDIT_PATIENT_ID_EXTURL
- See Also:
- Constant Field Values
-
PROPERTY_AUDIT_HOSTNAME
public static final String PROPERTY_AUDIT_HOSTNAME
- See Also:
- Constant Field Values
-
PROPERTY_AUDIT_IP
public static final String PROPERTY_AUDIT_IP
- See Also:
- Constant Field Values
-
PROPERTY_NOTIFICATION_RESOURCE_TYPES
public static final String PROPERTY_NOTIFICATION_RESOURCE_TYPES
- See Also:
- Constant Field Values
-
PROPERTY_NOTIFICATION_NOTIFICATION_SIZE_BEHAVIOR
public static final String PROPERTY_NOTIFICATION_NOTIFICATION_SIZE_BEHAVIOR
- See Also:
- Constant Field Values
-
PROPERTY_NOTIFICATION_MAX_SIZE
public static final String PROPERTY_NOTIFICATION_MAX_SIZE
- See Also:
- Constant Field Values
-
PROPERTY_WEBSOCKET_ENABLED
public static final String PROPERTY_WEBSOCKET_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_KAFKA_ENABLED
public static final String PROPERTY_KAFKA_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_KAFKA_TOPICNAME
public static final String PROPERTY_KAFKA_TOPICNAME
- See Also:
- Constant Field Values
-
PROPERTY_KAFKA_CONNECTIONPROPS
public static final String PROPERTY_KAFKA_CONNECTIONPROPS
- See Also:
- Constant Field Values
-
PROPERTY_KAFKA_SYNC
public static final String PROPERTY_KAFKA_SYNC
- See Also:
- Constant Field Values
-
PROPERTY_NATS_ENABLED
public static final String PROPERTY_NATS_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_NATS_CLUSTER
public static final String PROPERTY_NATS_CLUSTER
- See Also:
- Constant Field Values
-
PROPERTY_NATS_CHANNEL
public static final String PROPERTY_NATS_CHANNEL
- See Also:
- Constant Field Values
-
PROPERTY_NATS_CLIENT
public static final String PROPERTY_NATS_CLIENT
- See Also:
- Constant Field Values
-
PROPERTY_NATS_SERVERS
public static final String PROPERTY_NATS_SERVERS
- See Also:
- Constant Field Values
-
PROPERTY_NATS_TLS_ENABLED
public static final String PROPERTY_NATS_TLS_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_NATS_TRUSTSTORE
public static final String PROPERTY_NATS_TRUSTSTORE
- See Also:
- Constant Field Values
-
PROPERTY_NATS_TRUSTSTORE_PW
public static final String PROPERTY_NATS_TRUSTSTORE_PW
- See Also:
- Constant Field Values
-
PROPERTY_NATS_KEYSTORE
public static final String PROPERTY_NATS_KEYSTORE
- See Also:
- Constant Field Values
-
PROPERTY_NATS_KEYSTORE_PW
public static final String PROPERTY_NATS_KEYSTORE_PW
- See Also:
- Constant Field Values
-
PROPERTY_UPDATE_CREATE_ENABLED
public static final String PROPERTY_UPDATE_CREATE_ENABLED
- See Also:
- Constant Field Values
-
PROPERTY_PERSISTENCE_FACTORY
public static final String PROPERTY_PERSISTENCE_FACTORY
- See Also:
- Constant Field Values
-
PROPERTY_DATASOURCES
public static final String PROPERTY_DATASOURCES
- See Also:
- Constant Field Values
-
PROPERTY_JDBC_ENABLE_READ_ONLY_REPLICAS
public static final String PROPERTY_JDBC_ENABLE_READ_ONLY_REPLICAS
- See Also:
- Constant Field Values
-
PROPERTY_JDBC_ENABLE_CODE_SYSTEMS_CACHE
public static final String PROPERTY_JDBC_ENABLE_CODE_SYSTEMS_CACHE
- See Also:
- Constant Field Values
-
PROPERTY_JDBC_ENABLE_PARAMETER_NAMES_CACHE
public static final String PROPERTY_JDBC_ENABLE_PARAMETER_NAMES_CACHE
- See Also:
- Constant Field Values
-
PROPERTY_JDBC_ENABLE_RESOURCE_TYPES_CACHE
public static final String PROPERTY_JDBC_ENABLE_RESOURCE_TYPES_CACHE
- See Also:
- Constant Field Values
-
PROPERTY_JDBC_EXTERNAL_REF_SYSTEM_CACHE_SIZE
public static final String PROPERTY_JDBC_EXTERNAL_REF_SYSTEM_CACHE_SIZE
- See Also:
- Constant Field Values
-
PROPERTY_JDBC_EXTERNAL_REF_VALUE_CACHE_SIZE
public static final String PROPERTY_JDBC_EXTERNAL_REF_VALUE_CACHE_SIZE
- See Also:
- Constant Field Values
-
PROPERTY_JDBC_SEARCH_OPTIMIZER_OPTIONS
public static final String PROPERTY_JDBC_SEARCH_OPTIMIZER_OPTIONS
- See Also:
- Constant Field Values
-
PROPERTY_SEARCH_BOUNDING_AREA_RADIUS_TYPE
public static final String PROPERTY_SEARCH_BOUNDING_AREA_RADIUS_TYPE
- See Also:
- Constant Field Values
-
PROPERTY_USE_STORED_COMPARTMENT_PARAM
public static final String PROPERTY_USE_STORED_COMPARTMENT_PARAM
- See Also:
- Constant Field Values
-
PROPERTY_SEARCH_ENABLE_LEGACY_WHOLE_SYSTEM_SEARCH_PARAMS
public static final String PROPERTY_SEARCH_ENABLE_LEGACY_WHOLE_SYSTEM_SEARCH_PARAMS
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOBID_ENCRYPTION_KEY
public static final String PROPERTY_BULKDATA_BATCHJOBID_ENCRYPTION_KEY
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_PARAMETERS
public static final String PROPERTY_BULKDATA_BATCHJOB_PARAMETERS
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_APPLICATIONNAME
public static final String PROPERTY_BULKDATA_BATCHJOB_APPLICATIONNAME
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_MODULENAME
public static final String PROPERTY_BULKDATA_BATCHJOB_MODULENAME
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_JOBXMLNAME
public static final String PROPERTY_BULKDATA_BATCHJOB_JOBXMLNAME
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_IMPTYPE
public static final String PROPERTY_BULKDATA_BATCHJOB_IMPTYPE
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_BATCHURI
public static final String PROPERTY_BULKDATA_BATCHJOB_BATCHURI
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_BATCHUSER
public static final String PROPERTY_BULKDATA_BATCHJOB_BATCHUSER
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_BATCHUSERPWD
public static final String PROPERTY_BULKDATA_BATCHJOB_BATCHUSERPWD
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_BATCHTRUSTSTORE
public static final String PROPERTY_BULKDATA_BATCHJOB_BATCHTRUSTSTORE
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_BATCHTRUSTSTOREPWD
public static final String PROPERTY_BULKDATA_BATCHJOB_BATCHTRUSTSTOREPWD
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_USEFHIRSERVERTRUSTSTORE
public static final String PROPERTY_BULKDATA_BATCHJOB_USEFHIRSERVERTRUSTSTORE
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_ENABLEPARQUET
public static final String PROPERTY_BULKDATA_BATCHJOB_ENABLEPARQUET
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_SYSTEMEXPIMPL
public static final String PROPERTY_BULKDATA_BATCHJOB_SYSTEMEXPIMPL
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_VALID_BASE_URLS
public static final String PROPERTY_BULKDATA_BATCHJOB_VALID_BASE_URLS
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_VALID_URLS_DISABLED
public static final String PROPERTY_BULKDATA_BATCHJOB_VALID_URLS_DISABLED
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_MAX_INPUT_PER_TENANT
public static final String PROPERTY_BULKDATA_BATCHJOB_MAX_INPUT_PER_TENANT
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_COSFILEMAXSIZE
public static final String PROPERTY_BULKDATA_BATCHJOB_COSFILEMAXSIZE
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_BATCHJOB_COSFILEMAXRESOURCES
public static final String PROPERTY_BULKDATA_BATCHJOB_COSFILEMAXRESOURCES
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_PATIENTEXPORT_PAGESIZE
public static final String PROPERTY_BULKDATA_PATIENTEXPORT_PAGESIZE
- See Also:
- Constant Field Values
-
PROPERTY_BULKDATA_IGNORE_IMPORT_OPERATION_OUTCOMES
public static final String PROPERTY_BULKDATA_IGNORE_IMPORT_OPERATION_OUTCOMES
- See Also:
- Constant Field Values
-
DEFAULT_TENANT_ID_HEADER_NAME
public static final String DEFAULT_TENANT_ID_HEADER_NAME
- See Also:
- Constant Field Values
-
DEFAULT_DATASTORE_ID_HEADER_NAME
public static final String DEFAULT_DATASTORE_ID_HEADER_NAME
- See Also:
- Constant Field Values
-
DEFAULT_PRETTY_RESPONSE_HEADER_NAME
public static final String DEFAULT_PRETTY_RESPONSE_HEADER_NAME
- See Also:
- Constant Field Values
-
FHIR_SERVER_DEFAULT_CONFIG
public static final String FHIR_SERVER_DEFAULT_CONFIG
- See Also:
- Constant Field Values
-
-
Method Detail
-
getInstance
public static FHIRConfiguration getInstance()
-
setConfigHome
public static void setConfigHome(String s)
This method is used to configure an explicit top-level directory where FHIR Server configuration information is expected to reside.For example, by calling this method with value "/mydir", then we'd expect to find config files whose names are of the form:
"/mydir/config/<tenant-id>/fhir-server-config.json"
The default location for config files is the current working directory (i.e. "" - the empty string).
- Parameters:
s
- the new config home directory name
-
getConfigHome
public static String getConfigHome()
Returns the "home" directory for FHIR Server configuration information (this directory will contain the "config" directory, etc.).The default value of this property is "" which is interpreted to mean the current working directory (which for a running FHIR Server will be $WLP_HOME/wlp/usr/servers/fhir-server).
-
loadConfiguration
public PropertyGroup loadConfiguration() throws Exception
Retrieves the FHIR Server default configuration and returns it as a PropertyGroup.- Returns:
- the top-level property group of the default tenant or null if it doesn't exist
- Throws:
Exception
- if the configuration file was found but couldn't be loaded
-
loadConfigurationForTenant
public PropertyGroup loadConfigurationForTenant(String tenantId) throws Exception
Loads the configuration for the specified tenant id.- Parameters:
tenantId
- a shortname representing the tenant whose configuration will be loaded- Returns:
- the top-level property group representing this tenant's configuration or null if it doesn't exist
- Throws:
Exception
-
clearConfiguration
public void clearConfiguration()
Clears the entire cache of configuration objects. This can be used perhaps during testing when you need to clear and re-load the configuration.
-
-