Interface ConfigurationAdapter

  • All Known Implementing Classes:
    AbstractSystemConfigurationImpl, V2ConfigurationImpl

    public interface ConfigurationAdapter
    Configuration provides a common interface to the fhir-server-config.json. and enables seamless reads of constant values which may be set in the future. The interface adds an @implNote for fixed or system (default), All other are dynamic.
    • Method Detail

      • getApplicationName

        java.lang.String getApplicationName()
        get the application name used in the javabatch framework.
        Returns:
      • getModuleName

        java.lang.String getModuleName()
        get the module name used in javabatch framework.
        Returns:
      • getJobXMLName

        java.lang.String getJobXMLName()
        get the job xml used in the javabatch framework.
        Returns:
      • registerRequestContext

        void registerRequestContext​(java.lang.String tenantId,
                                    java.lang.String datastoreId,
                                    java.lang.String incomingUrl)
                             throws FHIRException
        creates a uniform request context for the $import and $export operations.
        Parameters:
        tenantId -
        datastoreId -
        incomingUrl -
        Throws:
        FHIRException
      • legacy

        boolean legacy()
        identifies the configuration as legacy or not.
        Returns:
      • enabled

        boolean enabled()
        Returns:
        the status of the bulkdata feature, enabled = true, disabled = false
      • getCoreApiBatchUrl

        java.lang.String getCoreApiBatchUrl()
        Returns:
        the local batch api URL
      • getCoreApiBatchUser

        java.lang.String getCoreApiBatchUser()
        Returns:
        the local batch api user, it should be an admin
      • getCoreApiBatchPassword

        java.lang.String getCoreApiBatchPassword()
        Returns:
        the local batch api user password
      • getCoreApiBatchTrustStore

        java.lang.String getCoreApiBatchTrustStore()
        Returns:
        the local batch api user password
      • getCoreApiBatchTrustStorePassword

        java.lang.String getCoreApiBatchTrustStorePassword()
        Returns:
        the local batch api user password
      • shouldCoreApiBatchTrustAll

        boolean shouldCoreApiBatchTrustAll()
        Returns:
        should we trust the calls to the backend
      • getCoreCosPartUploadTriggerSize

        int getCoreCosPartUploadTriggerSize()
        The size (in bytes) at which to begin writing a part for a COS multi-part upload.
        Returns:
      • getCoreCosObjectSizeThreshold

        long getCoreCosObjectSizeThreshold()
        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.
        Returns:
      • getCoreCosObjectResourceCountThreshold

        int getCoreCosObjectResourceCountThreshold()
        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.
        Returns:
      • getCoreAzureObjectSizeThreshold

        long getCoreAzureObjectSizeThreshold()
        The size (in bytes) at which to finish writing to a given AzureBlob object,
        Returns:
      • getProviderAzureServiceVersion

        java.lang.String getProviderAzureServiceVersion​(java.lang.String provider)
        The serviceVersion for the Azure API
        Parameters:
        provider -
        Returns:
      • getCoreAzureObjectResourceCountThreshold

        int getCoreAzureObjectResourceCountThreshold()
        The number of resources at which to finish writing to a given AzureBlob object,
        Returns:
      • shouldCoreCosUseServerTruststore

        boolean shouldCoreCosUseServerTruststore()
        Returns:
        the system wide setting for using the server truststore.
      • getCoreCosRequestTimeout

        int getCoreCosRequestTimeout()
        Returns:
        the timeout for the s3 request
      • getCoreCosSocketTimeout

        int getCoreCosSocketTimeout()
        Returns:
        the timeout for the s3 socket
      • getCoreFileWriteTriggerSize

        int getCoreFileWriteTriggerSize()
        The size (in bytes) to buffer before writing to file.
        Returns:
      • getCoreFileSizeThreshold

        long getCoreFileSizeThreshold()
        The size (in bytes) at which to finish writing to a given file, or 0 to indicate that there is no file size threshold.
        Returns:
      • getCoreFileResourceCountThreshold

        int getCoreFileResourceCountThreshold()
        The number of resources at which to finish writing to a given file, or 0 to indicate that there is no resource count threshold.
        Returns:
      • getCorePageSize

        int getCorePageSize()
        get the core page size used in Search.
        Returns:
      • getCoreBatchIdEncodingKey

        java.lang.String getCoreBatchIdEncodingKey()
        get core batch id encoding key for the job id that is returned
        Returns:
      • getCoreMaxPartitions

        int getCoreMaxPartitions()
        get core max partitions
        Returns:
      • getCoreIamEndpoint

        java.lang.String getCoreIamEndpoint()
        get the core iam endpoint (it is set one time for the whole system)
        Returns:
      • getCoreFastMaxReadTimeout

        long getCoreFastMaxReadTimeout()
        get the number ms to read payloads from the persistence layer before stopping to checkpoint
        Returns:
      • getDefaultImportProvider

        java.lang.String getDefaultImportProvider()
        get default import provider
        Returns:
      • getDefaultExportProvider

        java.lang.String getDefaultExportProvider()
        get default export provider
        Returns:
      • getOperationOutcomeProvider

        java.lang.String getOperationOutcomeProvider​(java.lang.String provider)
        get the OperationOutcome provider
        Parameters:
        provider - the storage provider
        Returns:
      • hasStorageProvider

        boolean hasStorageProvider​(java.lang.String storageProvider)
        Parameters:
        storageProvider -
        Returns:
        True, iff the provider exists in the configuration.
      • getStorageProviderType

        java.lang.String getStorageProviderType​(java.lang.String provider)
        gets the StorageProvider type which aligns with the StorageType
        Parameters:
        provider -
        Returns:
      • getStorageProviderValidBaseUrls

        java.util.List<java.lang.String> getStorageProviderValidBaseUrls​(java.lang.String provider)
        gets the StorageProvider's valid base urls for HTTPS sources.
        Parameters:
        provider -
        Returns:
      • getStorageProviderBucketName

        java.lang.String getStorageProviderBucketName​(java.lang.String provider)
        gets the StorageProvider's bucket name for cos sources.
        Parameters:
        provider -
        Returns:
      • getStorageProviderLocation

        java.lang.String getStorageProviderLocation​(java.lang.String provider)
        gets the location of the cos endpoint.
        Parameters:
        provider -
        Returns:
      • getStorageProviderEndpointInternal

        java.lang.String getStorageProviderEndpointInternal​(java.lang.String provider)
        get the internal endpoint for the storage provider.
        Parameters:
        provider -
        Returns:
      • getStorageProviderEndpointExternal

        java.lang.String getStorageProviderEndpointExternal​(java.lang.String provider)
        get the external endpoint for the storage provider.
        Parameters:
        provider -
        Returns:
      • getStorageProviderAuthType

        java.lang.String getStorageProviderAuthType​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • isStorageProviderAuthTypeIam

        boolean isStorageProviderAuthTypeIam​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • getStorageProviderAuthTypeIamApiKey

        java.lang.String getStorageProviderAuthTypeIamApiKey​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • getStorageProviderAuthTypeIamApiResourceInstanceId

        java.lang.String getStorageProviderAuthTypeIamApiResourceInstanceId​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • isStorageProviderAuthTypeHmac

        boolean isStorageProviderAuthTypeHmac​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • getStorageProviderAuthTypeHmacAccessKey

        java.lang.String getStorageProviderAuthTypeHmacAccessKey​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • getStorageProviderAuthTypeHmacSecretKey

        java.lang.String getStorageProviderAuthTypeHmacSecretKey​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • isStorageProviderAuthTypeBasic

        boolean isStorageProviderAuthTypeBasic​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • getStorageProviderAuthTypeUsername

        java.lang.String getStorageProviderAuthTypeUsername​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • getStorageProviderAuthTypePassword

        java.lang.String getStorageProviderAuthTypePassword​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • shouldStorageProviderValidateBaseUrl

        boolean shouldStorageProviderValidateBaseUrl​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • shouldStorageProviderCollectOperationOutcomes

        boolean shouldStorageProviderCollectOperationOutcomes​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • shouldStorageProviderCheckDuplicate

        boolean shouldStorageProviderCheckDuplicate​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • shouldStorageProviderValidateResources

        boolean shouldStorageProviderValidateResources​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • shouldStorageProviderCreate

        boolean shouldStorageProviderCreate​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • isStorageTypeAllowed

        boolean isStorageTypeAllowed​(java.lang.String storageType)
        checks if the
        Parameters:
        storageType -
        Returns:
      • getStorageProviderStorageType

        StorageType getStorageProviderStorageType​(java.lang.String provider)
        Parameters:
        provider - of the storage type
        Returns:
      • getInputLimit

        int getInputLimit()
        limit of inputs
        Returns:
      • getTenant

        java.lang.String getTenant()
        gets a tenant in the current context
        Returns:
      • isFastExport

        boolean isFastExport()
        indicating if it's the new fast export
        Returns:
      • getCoreCosTcpKeepAlive

        boolean getCoreCosTcpKeepAlive()
        get the COS TCP Keep alive setting (true or false)
        Returns:
      • getBaseFileLocation

        java.lang.String getBaseFileLocation​(java.lang.String provider)
        get the base file location
        Parameters:
        provider -
        Returns:
      • isStorageProviderHmacPresigned

        boolean isStorageProviderHmacPresigned​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • getEndOfFileDelimiter

        byte[] getEndOfFileDelimiter​(java.lang.String provider)
        Parameters:
        provider -
        Returns:
      • getImportNumberOfFhirResourcesPerRead

        int getImportNumberOfFhirResourcesPerRead​(java.lang.String provider)
        get the import fhir resources per read
        Parameters:
        provider -
        Returns:
      • getImportInflyRateNumberOfFhirResources

        int getImportInflyRateNumberOfFhirResources​(java.lang.String provider)
        the infly rate for the import
        Parameters:
        provider -
        Returns:
      • getPresignedUrlExpiry

        int getPresignedUrlExpiry()
        the expiry time of the generated presigned urls.
        Returns:
      • getStorageProviderAuthTypeConnectionString

        java.lang.String getStorageProviderAuthTypeConnectionString​(java.lang.String provider)
        get the connection string for the azure type account with a connection string.
        Parameters:
        provider -
        Returns:
      • isStorageProviderAuthTypeConnectionString

        boolean isStorageProviderAuthTypeConnectionString​(java.lang.String provider)
        checks the provider to see if this is an azure connection string.
        Parameters:
        provider -
        Returns:
        true, if connectionString
      • enableSkippableUpdates

        boolean enableSkippableUpdates()
        Returns:
        the status of skippable updates
      • getS3HostStyleByStorageProvider

        S3HostStyle getS3HostStyleByStorageProvider​(java.lang.String provider)
        gets the storage type
        Parameters:
        provider -
        Returns:
      • getStorageProviderUsesRequestAccessToken

        boolean getStorageProviderUsesRequestAccessToken​(java.lang.String provider)
        reports back to the client if the StorageProvider supports requestAccessTokens
        Parameters:
        provider -
        Returns:
      • shouldStorageProviderAllowAllResources

        boolean shouldStorageProviderAllowAllResources​(java.lang.String source)
        allows multiple resources in a single file.
        Parameters:
        source -
        Returns: