Skip to content

Commit

Permalink
rename env variable
Browse files Browse the repository at this point in the history
  • Loading branch information
redmitry committed Jul 19, 2024
1 parent f896720 commit eed7d4f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,18 +34,18 @@ public final class ConfigurationProperties {
public final static String BN_CONFIG_DIR_PROPERTY_NAME = "BEACON_NETWORK_CONFIG_DIR";

public final static String BN_REQUEST_TIMEOUT_PROPERTY_NAME = "BEACON_NETWORK_REQUEST_TIMEOUT";
public final static String BN_CANCEL_REQUEST_TIMEOUT_PROPERTY_NAME = "BEACON_NETWORK_CANCEL_REQUEST_TIMEOUT";
public final static String BN_DISCARD_REQUEST_TIMEOUT_PROPERTY_NAME = "BEACON_NETWORK_DISCARD_REQUEST_TIMEOUT";
public final static String BN_REFRESH_METADATA_TIMEOUT_PROPERTY_NAME = "BEACON_NETWORK_REFRESH_METADATA_TIMEOUT";

public final static String BN_CONFIG_DIR_PROPERTY;

public final static long BN_CANCEL_REQUEST_TIMEOUT_PROPERTY;
public final static long BN_DISCARD_REQUEST_TIMEOUT_PROPERTY;
public final static long BN_REQUEST_TIMEOUT_PROPERTY;
public final static long BN_REFRESH_METADATA_TIMEOUT_PROPERTY;

static {
BN_CONFIG_DIR_PROPERTY = System.getenv(BN_CONFIG_DIR_PROPERTY_NAME);
BN_CANCEL_REQUEST_TIMEOUT_PROPERTY = readProperty(BN_CANCEL_REQUEST_TIMEOUT_PROPERTY_NAME, 5);
BN_DISCARD_REQUEST_TIMEOUT_PROPERTY = readProperty(BN_DISCARD_REQUEST_TIMEOUT_PROPERTY_NAME, 5);
BN_REQUEST_TIMEOUT_PROPERTY = readProperty(BN_REQUEST_TIMEOUT_PROPERTY_NAME, 600);
BN_REFRESH_METADATA_TIMEOUT_PROPERTY = readProperty(BN_REFRESH_METADATA_TIMEOUT_PROPERTY_NAME, 60);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ private List<AbstractBeaconResponse> getResultsets(

try {
final HttpResponse<AbstractBeaconResponse> response =
invocation.get(ConfigurationProperties.BN_CANCEL_REQUEST_TIMEOUT_PROPERTY, TimeUnit.SECONDS);
invocation.get(ConfigurationProperties.BN_DISCARD_REQUEST_TIMEOUT_PROPERTY, TimeUnit.SECONDS);
if (response != null) {
if (response.body() != null) {
responses.add(response.body());
Expand Down

0 comments on commit eed7d4f

Please sign in to comment.