Class AbstractSystemConfigurationImpl
- java.lang.Object
-
- com.ibm.fhir.operation.bulkdata.config.impl.AbstractSystemConfigurationImpl
-
- All Implemented Interfaces:
ConfigurationAdapter
- Direct Known Subclasses:
V2ConfigurationImpl
public abstract class AbstractSystemConfigurationImpl extends Object implements ConfigurationAdapter
Common between the Legacy and V2 Configuration and Implementation Also the system defaults.
-
-
Field Summary
Fields Modifier and Type Field Description protected static intDEFAULT_AZURE_OBJ_MAX_RESOURCE_COUNTprotected static intDEFAULT_AZURE_OBJ_MAX_SIZE_MBprotected static intDEFAULT_COS_OBJ_MAX_RESOURCE_COUNTprotected static intDEFAULT_COS_OBJ_MAX_SIZE_MBprotected static intDEFAULT_FILE_MAX_RESOURCE_COUNTprotected static intDEFAULT_FILE_MAX_SIZE_MBprotected static intDEFAULT_PAGE_SIZEstatic intIMPORT_INFLY_RATE_NUMOFFHIRRESOURCESstatic intIMPORT_NUMOFFHIRRESOURCES_PERREAD
-
Constructor Summary
Constructors Constructor Description AbstractSystemConfigurationImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanenabled()booleanenableSkippableUpdates()StringgetApplicationName()get the application name used in the javabatch framework.StringgetBaseFileLocation(String provider)get the base file locationintgetCoreAzureObjectResourceCountThreshold()The number of resources at which to finish writing to a given AzureBlob object,longgetCoreAzureObjectSizeThreshold()The size (in bytes) at which to finish writing to a given AzureBlob object,StringgetCoreBatchIdEncryptionKey()get core batch id encryption key for the job id that is returnedintgetCoreCosObjectResourceCountThreshold()The number of resources at which to finish writing to a given COS object, or 0 to indicate that there is no resource count threshold.longgetCoreCosObjectSizeThreshold()The size (in bytes) at which to finish writing to a given COS object, or 0 to indicate that there is no object size threshold.intgetCoreCosPartUploadTriggerSize()The size (in bytes) at which to begin writing a part for a COS multi-part upload.intgetCoreCosRequestTimeout()intgetCoreCosSocketTimeout()booleangetCoreCosTcpKeepAlive()get the COS TCP Keep alive setting (true or false)longgetCoreFastMaxReadTimeout()get the number ms to read payloads from the persistence layer before stopping to checkpointintgetCoreFileResourceCountThreshold()The number of resources at which to finish writing to a given file, or 0 to indicate that there is no resource count threshold.longgetCoreFileSizeThreshold()The size (in bytes) at which to finish writing to a given file, or 0 to indicate that there is no file size threshold.intgetCoreFileWriteTriggerSize()The size (in bytes) to buffer before writing to file.StringgetCoreIamEndpoint()get the core iam endpoint (it is set one time for the whole system)intgetCoreMaxPartitions()get core max partitionsintgetCorePageSize()get the core page size used in Search.StringgetDefaultExportProvider()get default export providerStringgetDefaultImportProvider()get default import providerbyte[]getEndOfFileDelimiter(String provider)intgetImportInflyRateNumberOfFhirResources(String provider)the infly rate for the importintgetImportNumberOfFhirResourcesPerRead(String provider)get the import fhir resources per readintgetInputLimit()limit of inputsStringgetJobXMLName()get the job xml used in the javabatch framework.StringgetModuleName()get the module name used in javabatch framework.StringgetOperationOutcomeProvider(String provider)get the OperationOutcome providerintgetPresignedUrlExpiry()the expiry time of the generated presigned urls.S3HostStylegetS3HostStyleByStorageProvider(String provider)gets the storage typeStringgetStorageProviderAuthTypeConnectionString(String provider)get the connection string for the azure type account with a connection string.StorageTypegetStorageProviderStorageType(String provider)StringgetTenant()gets a tenant in the current contextbooleanhasStorageProvider(String storageProvider)booleanisStorageProviderAuthTypeConnectionString(String provider)checks the provider to see if this is an azure connection string.booleanisStorageProviderHmacPresigned(String provider)booleanisStorageTypeAllowed(String storageType)checks if thevoidregisterRequestContext(String tenantId, String datastoreId, String incomingUrl)creates a uniform request context for the $import and $export operations.booleanshouldCoreApiBatchTrustAll()booleanshouldCoreCosUseServerTruststore()-
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.ibm.fhir.operation.bulkdata.config.ConfigurationAdapter
getCoreApiBatchPassword, getCoreApiBatchTrustStore, getCoreApiBatchTrustStorePassword, getCoreApiBatchUrl, getCoreApiBatchUser, getStorageProviderAuthType, getStorageProviderAuthTypeHmacAccessKey, getStorageProviderAuthTypeHmacSecretKey, getStorageProviderAuthTypeIamApiKey, getStorageProviderAuthTypeIamApiResourceInstanceId, getStorageProviderAuthTypePassword, getStorageProviderAuthTypeUsername, getStorageProviderBucketName, getStorageProviderEndpointExternal, getStorageProviderEndpointInternal, getStorageProviderLocation, getStorageProviderType, getStorageProviderValidBaseUrls, isFastExport, isStorageProviderAuthTypeBasic, isStorageProviderAuthTypeHmac, isStorageProviderAuthTypeIam, isStorageProviderParquetEnabled, legacy, shouldStorageProviderCheckDuplicate, shouldStorageProviderCollectOperationOutcomes, shouldStorageProviderCreate, shouldStorageProviderValidateBaseUrl, shouldStorageProviderValidateResources
-
-
-
-
Field Detail
-
DEFAULT_COS_OBJ_MAX_SIZE_MB
protected static final int DEFAULT_COS_OBJ_MAX_SIZE_MB
- See Also:
- Constant Field Values
-
DEFAULT_COS_OBJ_MAX_RESOURCE_COUNT
protected static final int DEFAULT_COS_OBJ_MAX_RESOURCE_COUNT
- See Also:
- Constant Field Values
-
DEFAULT_AZURE_OBJ_MAX_SIZE_MB
protected static final int DEFAULT_AZURE_OBJ_MAX_SIZE_MB
- See Also:
- Constant Field Values
-
DEFAULT_AZURE_OBJ_MAX_RESOURCE_COUNT
protected static final int DEFAULT_AZURE_OBJ_MAX_RESOURCE_COUNT
- See Also:
- Constant Field Values
-
DEFAULT_FILE_MAX_SIZE_MB
protected static final int DEFAULT_FILE_MAX_SIZE_MB
- See Also:
- Constant Field Values
-
DEFAULT_FILE_MAX_RESOURCE_COUNT
protected static final int DEFAULT_FILE_MAX_RESOURCE_COUNT
- See Also:
- Constant Field Values
-
DEFAULT_PAGE_SIZE
protected static final int DEFAULT_PAGE_SIZE
- See Also:
- Constant Field Values
-
IMPORT_NUMOFFHIRRESOURCES_PERREAD
public static final int IMPORT_NUMOFFHIRRESOURCES_PERREAD
- See Also:
- Constant Field Values
-
IMPORT_INFLY_RATE_NUMOFFHIRRESOURCES
public static final int IMPORT_INFLY_RATE_NUMOFFHIRRESOURCES
- See Also:
- Constant Field Values
-
-
Method Detail
-
getCoreCosTcpKeepAlive
public boolean getCoreCosTcpKeepAlive()
Description copied from interface:ConfigurationAdapterget the COS TCP Keep alive setting (true or false)- Specified by:
getCoreCosTcpKeepAlivein interfaceConfigurationAdapter- Returns:
-
getCoreMaxPartitions
public int getCoreMaxPartitions()
Description copied from interface:ConfigurationAdapterget core max partitions- Specified by:
getCoreMaxPartitionsin interfaceConfigurationAdapter- Returns:
-
getCoreBatchIdEncryptionKey
public String getCoreBatchIdEncryptionKey()
Description copied from interface:ConfigurationAdapterget core batch id encryption key for the job id that is returned- Specified by:
getCoreBatchIdEncryptionKeyin interfaceConfigurationAdapter- Returns:
-
getCoreCosSocketTimeout
public int getCoreCosSocketTimeout()
- Specified by:
getCoreCosSocketTimeoutin interfaceConfigurationAdapter- Returns:
- the timeout for the s3 socket
-
getInputLimit
public int getInputLimit()
Description copied from interface:ConfigurationAdapterlimit of inputs- Specified by:
getInputLimitin interfaceConfigurationAdapter- Returns:
-
getCoreCosRequestTimeout
public int getCoreCosRequestTimeout()
- Specified by:
getCoreCosRequestTimeoutin interfaceConfigurationAdapter- Returns:
- the timeout for the s3 request
-
shouldCoreCosUseServerTruststore
public boolean shouldCoreCosUseServerTruststore()
- Specified by:
shouldCoreCosUseServerTruststorein interfaceConfigurationAdapter- Returns:
- the system wide setting for using the server truststore.
-
getCoreCosPartUploadTriggerSize
public int getCoreCosPartUploadTriggerSize()
Description copied from interface:ConfigurationAdapterThe size (in bytes) at which to begin writing a part for a COS multi-part upload.- Specified by:
getCoreCosPartUploadTriggerSizein interfaceConfigurationAdapter- Returns:
-
getCoreCosObjectSizeThreshold
public long getCoreCosObjectSizeThreshold()
Description copied from interface:ConfigurationAdapterThe size (in bytes) at which to finish writing to a given COS object, or 0 to indicate that there is no object size threshold.- Specified by:
getCoreCosObjectSizeThresholdin interfaceConfigurationAdapter- Returns:
-
getCoreCosObjectResourceCountThreshold
public int getCoreCosObjectResourceCountThreshold()
Description copied from interface:ConfigurationAdapterThe number of resources at which to finish writing to a given COS object, or 0 to indicate that there is no resource count threshold.- Specified by:
getCoreCosObjectResourceCountThresholdin interfaceConfigurationAdapter- Returns:
-
getCoreAzureObjectSizeThreshold
public long getCoreAzureObjectSizeThreshold()
Description copied from interface:ConfigurationAdapterThe size (in bytes) at which to finish writing to a given AzureBlob object,- Specified by:
getCoreAzureObjectSizeThresholdin interfaceConfigurationAdapter- Returns:
-
getCoreAzureObjectResourceCountThreshold
public int getCoreAzureObjectResourceCountThreshold()
Description copied from interface:ConfigurationAdapterThe number of resources at which to finish writing to a given AzureBlob object,- Specified by:
getCoreAzureObjectResourceCountThresholdin interfaceConfigurationAdapter- Returns:
-
getCoreFileWriteTriggerSize
public int getCoreFileWriteTriggerSize()
Description copied from interface:ConfigurationAdapterThe size (in bytes) to buffer before writing to file.- Specified by:
getCoreFileWriteTriggerSizein interfaceConfigurationAdapter- Returns:
-
getCoreFileSizeThreshold
public long getCoreFileSizeThreshold()
Description copied from interface:ConfigurationAdapterThe size (in bytes) at which to finish writing to a given file, or 0 to indicate that there is no file size threshold.- Specified by:
getCoreFileSizeThresholdin interfaceConfigurationAdapter- Returns:
-
getCoreFileResourceCountThreshold
public int getCoreFileResourceCountThreshold()
Description copied from interface:ConfigurationAdapterThe number of resources at which to finish writing to a given file, or 0 to indicate that there is no resource count threshold.- Specified by:
getCoreFileResourceCountThresholdin interfaceConfigurationAdapter- Returns:
-
getApplicationName
public String getApplicationName()
Description copied from interface:ConfigurationAdapterget the application name used in the javabatch framework.- Specified by:
getApplicationNamein interfaceConfigurationAdapter- Returns:
-
getModuleName
public String getModuleName()
Description copied from interface:ConfigurationAdapterget the module name used in javabatch framework.- Specified by:
getModuleNamein interfaceConfigurationAdapter- Returns:
-
getJobXMLName
public String getJobXMLName()
Description copied from interface:ConfigurationAdapterget the job xml used in the javabatch framework.- Specified by:
getJobXMLNamein interfaceConfigurationAdapter- Returns:
-
registerRequestContext
public void registerRequestContext(String tenantId, String datastoreId, String incomingUrl) throws FHIRException
Description copied from interface:ConfigurationAdaptercreates a uniform request context for the $import and $export operations.- Specified by:
registerRequestContextin interfaceConfigurationAdapter- Throws:
FHIRException
-
enabled
public boolean enabled()
- Specified by:
enabledin interfaceConfigurationAdapter- Returns:
- the status of the bulkdata feature, enabled = true, disabled = false
-
getCorePageSize
public int getCorePageSize()
Description copied from interface:ConfigurationAdapterget the core page size used in Search.- Specified by:
getCorePageSizein interfaceConfigurationAdapter- Returns:
-
getCoreIamEndpoint
public String getCoreIamEndpoint()
Description copied from interface:ConfigurationAdapterget the core iam endpoint (it is set one time for the whole system)- Specified by:
getCoreIamEndpointin interfaceConfigurationAdapter- Returns:
-
getCoreFastMaxReadTimeout
public long getCoreFastMaxReadTimeout()
Description copied from interface:ConfigurationAdapterget the number ms to read payloads from the persistence layer before stopping to checkpoint- Specified by:
getCoreFastMaxReadTimeoutin interfaceConfigurationAdapter- Returns:
-
isStorageTypeAllowed
public boolean isStorageTypeAllowed(String storageType)
Description copied from interface:ConfigurationAdapterchecks if the- Specified by:
isStorageTypeAllowedin interfaceConfigurationAdapter- Returns:
-
getStorageProviderStorageType
public StorageType getStorageProviderStorageType(String provider)
- Specified by:
getStorageProviderStorageTypein interfaceConfigurationAdapter- Parameters:
provider- of the storage type- Returns:
-
getTenant
public String getTenant()
Description copied from interface:ConfigurationAdaptergets a tenant in the current context- Specified by:
getTenantin interfaceConfigurationAdapter- Returns:
-
getBaseFileLocation
public String getBaseFileLocation(String provider)
Description copied from interface:ConfigurationAdapterget the base file location- Specified by:
getBaseFileLocationin interfaceConfigurationAdapter- Returns:
-
isStorageProviderHmacPresigned
public boolean isStorageProviderHmacPresigned(String provider)
- Specified by:
isStorageProviderHmacPresignedin interfaceConfigurationAdapter- Returns:
-
shouldCoreApiBatchTrustAll
public boolean shouldCoreApiBatchTrustAll()
- Specified by:
shouldCoreApiBatchTrustAllin interfaceConfigurationAdapter- Returns:
- should we trust the calls to the backend
-
getEndOfFileDelimiter
public byte[] getEndOfFileDelimiter(String provider)
- Specified by:
getEndOfFileDelimiterin interfaceConfigurationAdapter- Returns:
-
getImportNumberOfFhirResourcesPerRead
public int getImportNumberOfFhirResourcesPerRead(String provider)
Description copied from interface:ConfigurationAdapterget the import fhir resources per read- Specified by:
getImportNumberOfFhirResourcesPerReadin interfaceConfigurationAdapter- Returns:
-
getImportInflyRateNumberOfFhirResources
public int getImportInflyRateNumberOfFhirResources(String provider)
Description copied from interface:ConfigurationAdapterthe infly rate for the import- Specified by:
getImportInflyRateNumberOfFhirResourcesin interfaceConfigurationAdapter- Returns:
-
getPresignedUrlExpiry
public int getPresignedUrlExpiry()
Description copied from interface:ConfigurationAdapterthe expiry time of the generated presigned urls.- Specified by:
getPresignedUrlExpiryin interfaceConfigurationAdapter- Returns:
-
getDefaultImportProvider
public String getDefaultImportProvider()
Description copied from interface:ConfigurationAdapterget default import provider- Specified by:
getDefaultImportProviderin interfaceConfigurationAdapter- Returns:
-
getDefaultExportProvider
public String getDefaultExportProvider()
Description copied from interface:ConfigurationAdapterget default export provider- Specified by:
getDefaultExportProviderin interfaceConfigurationAdapter- Returns:
-
getOperationOutcomeProvider
public String getOperationOutcomeProvider(String provider)
Description copied from interface:ConfigurationAdapterget the OperationOutcome provider- Specified by:
getOperationOutcomeProviderin interfaceConfigurationAdapter- Parameters:
provider- the storage provider- Returns:
-
hasStorageProvider
public boolean hasStorageProvider(String storageProvider)
- Specified by:
hasStorageProviderin interfaceConfigurationAdapter- Returns:
- True, iff the provider exists in the configuration.
-
getS3HostStyleByStorageProvider
public S3HostStyle getS3HostStyleByStorageProvider(String provider)
Description copied from interface:ConfigurationAdaptergets the storage type- Specified by:
getS3HostStyleByStorageProviderin interfaceConfigurationAdapter- Returns:
-
enableSkippableUpdates
public boolean enableSkippableUpdates()
- Specified by:
enableSkippableUpdatesin interfaceConfigurationAdapter- Returns:
- the status of skippable updates
-
getStorageProviderAuthTypeConnectionString
public String getStorageProviderAuthTypeConnectionString(String provider)
Description copied from interface:ConfigurationAdapterget the connection string for the azure type account with a connection string.- Specified by:
getStorageProviderAuthTypeConnectionStringin interfaceConfigurationAdapter- Returns:
-
isStorageProviderAuthTypeConnectionString
public boolean isStorageProviderAuthTypeConnectionString(String provider)
Description copied from interface:ConfigurationAdapterchecks the provider to see if this is an azure connection string.- Specified by:
isStorageProviderAuthTypeConnectionStringin interfaceConfigurationAdapter- Returns:
- true, if connectionString
-
-