Skip to content

Commit

Permalink
Remove isStorageProviderExportPublic and the legacy config impl
Browse files Browse the repository at this point in the history
Both of these were previously deprecated.

Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
  • Loading branch information
lmsurpre committed Jun 23, 2021
1 parent e352112 commit eff5586
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 260 deletions.
14 changes: 6 additions & 8 deletions docs/src/pages/guides/FHIRServerUsersGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -1363,17 +1363,17 @@ For more information about Liberty JavaBatch configuration, please refer to [IBM

For BulkData storage types of `ibm-cos` and `aws-s3`, the IBM FHIR Server supports two styles of accessing the `s3` bucket - virtual host and path. In the IBM FHIR Server, `path` is the default access. [Link](https://docs.aws.amazon.com/AmazonS3/latest/userguide/VirtualHosting.html)

With path style access, the objects in a bucket are accessed using the pattern - `https://s3.region.host-name.com/bucket-name/object-key`. To configure path style access, one needs to configure the fhir-server-config.json.
With path style access, the objects in a bucket are accessed using the pattern - `https://s3.region.host-name.com/bucket-name/object-key`. To configure path style access, one needs to configure the fhir-server-config.json.

There are three critical elements in the configuration to configure path style:
There are three critical elements in the configuration to configure path style:

|Configuration|Details|
|-------------|-------|
|`endpointInternal`|the direct S3 API provider for the S3 API|
|`endpointExternal`|the endpoint url used to generate the downloadUrl used in S3 Export|
|`accessType`|"path", the default access type|

Example of `path` based access:
Example of `path` based access:

``` json
"bulkdata": {
Expand All @@ -1392,7 +1392,6 @@ Example of `path` based access:
},
"enableParquet": false,
"disableBaseUrlValidation": true,
"exportPublic": true,
"disableOperationOutcomes": true,
"duplicationCheck": false,
"validateResources": false,
Expand All @@ -1404,9 +1403,9 @@ Example of `path` based access:
}
```

With virtual host style access, the objects in a bucket are accessed using the pattern - `https://bucket-name.s3.region.host-name.com/object-key`. To configure virtual host style access, one needs to configure the API.
With virtual host style access, the objects in a bucket are accessed using the pattern - `https://bucket-name.s3.region.host-name.com/object-key`. To configure virtual host style access, one needs to configure the API.

There are three critical elements in the configuration to configure virtual host style:
There are three critical elements in the configuration to configure virtual host style:

|Configuration|Details|
|-------------|-------|
Expand All @@ -1416,7 +1415,7 @@ There are three critical elements in the configuration to configure virtual host

Note, while the endpointInternal is specified with the S3 region endpoint, the calls to the API will use the virtual host directly.

Example of `host` based access:
Example of `host` based access:

``` json
"bulkdata": {
Expand All @@ -1435,7 +1434,6 @@ Example of `host` based access:
},
"enableParquet": false,
"disableBaseUrlValidation": true,
"exportPublic": true,
"disableOperationOutcomes": true,
"duplicationCheck": false,
"validateResources": false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -377,14 +377,6 @@ public interface ConfigurationAdapter {
*/
boolean shouldStorageProviderValidateBaseUrl(String provider);

/**
*
* @param provider
* @return
*/
@Deprecated
boolean isStorageProviderExportPublic(String provider);

/**
*
* @param provider
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,27 +6,17 @@

package com.ibm.fhir.operation.bulkdata.config;

import com.ibm.fhir.config.FHIRConfigHelper;
import com.ibm.fhir.operation.bulkdata.config.impl.LegacyConfigurationImpl;
import com.ibm.fhir.operation.bulkdata.config.impl.V2ConfigurationImpl;

/**
* Controls the selection of the legacy versus the new implementation.
*/
@SuppressWarnings("deprecation")
public class ConfigurationFactory {
private ConfigurationFactory() {
// No Operation
}

public static ConfigurationAdapter getInstance() {
boolean legacy = FHIRConfigHelper.getBooleanProperty("fhirServer/bulkdata/legacy", Boolean.FALSE);
ConfigurationAdapter adapter;
if (legacy) {
adapter = new LegacyConfigurationImpl();
} else {
adapter = new V2ConfigurationImpl();
}
return adapter;
return new V2ConfigurationImpl();
}
}

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -145,11 +145,6 @@ public boolean shouldStorageProviderValidateBaseUrl(String provider) {
return FHIRConfigHelper.getBooleanProperty("fhirServer/bulkdata/storageProviders/" + provider + "/disableBaseUrlValidation", Boolean.FALSE);
}

@Override
public boolean isStorageProviderExportPublic(String provider) {
return false;
}

@Override
public boolean shouldStorageProviderCollectOperationOutcomes(String provider) {
// Double negation... carefully change this line.
Expand Down

0 comments on commit eff5586

Please sign in to comment.