Skip to content

Commit

Permalink
don't put limit=0 to all metadata endpoints
Browse files Browse the repository at this point in the history
  • Loading branch information
redmitry committed Apr 26, 2024
1 parent 6565bb6 commit 2096b9b
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -134,13 +134,14 @@ public BeaconInformationalResponse parseMetadata(String json, BeaconMetadataSche
}

public String loadMetadata(String endpoint, BeaconMetadataSchema schema, ValidationObserver reporter) {
return loadMetadata(endpoint + ENDPOINTS.get(schema), reporter);
return loadMetadata(endpoint + ENDPOINTS.get(schema) +
(schema == BeaconMetadataSchema.BEACON_FILTERING_TERMS_SCHEMA ? "?limit=0": ""), reporter);
}

public String loadMetadata(String endpoint, ValidationObserver reporter) {
reporter.message(String.format("loading metadata: %s", endpoint));
try {
final URI uri = new URI(endpoint + "?limit=0");
final URI uri = new URI(endpoint);
if (!uri.isAbsolute()) {
reporter.error(new BeaconValidationMessage(
BeaconValidationErrorType.CONNECTION_ERROR,
Expand Down

0 comments on commit 2096b9b

Please sign in to comment.