Interface FHIRDbConnectionStrategy
-
- All Known Implementing Classes:
FHIRDbConnectionStrategyBase
,FHIRDbProxyDatasourceConnectionStrategy
,FHIRDbTenantDatasourceConnectionStrategy
,FHIRDbTestConnectionStrategy
public interface FHIRDbConnectionStrategy
Abstraction used to obtain JDBC connections. The database being connected is determined by the datasource currently referenced by theFHIRRequestContext
(which is a ThreadLocal thing, and not obvious).
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Connection
getConnection()
Get a connection to the desired data source identified by the currentFHIRRequestContext
FHIRDbFlavor
getFlavor()
Get the flavor of the database we are working with to reveal its capabilitiesQueryHints
getQueryHints()
Append the given hint to FHIR search queries
-
-
-
Method Detail
-
getConnection
Connection getConnection() throws FHIRPersistenceDBConnectException
Get a connection to the desired data source identified by the currentFHIRRequestContext
- Returns:
- a
Connection
. Never null. - Throws:
FHIRPersistenceDBConnectException
-
getFlavor
FHIRDbFlavor getFlavor() throws FHIRPersistenceDataAccessException
Get the flavor of the database we are working with to reveal its capabilities- Returns:
- the datastore/source flavor from the FHIR configuration
- Throws:
FHIRPersistenceDataAccessException
- if there is an issue with the configuration
-
getQueryHints
QueryHints getQueryHints()
Append the given hint to FHIR search queries- Returns:
-
-