Skip to content

Commit

Permalink
allow max imagesets to return to be customizable
Browse files Browse the repository at this point in the history
  • Loading branch information
IbrahimCSAE committed Dec 30, 2023
1 parent 0423fa9 commit df99bdd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
3 changes: 1 addition & 2 deletions src/imageLoader/loadImageSets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ async function getImageSets(datastoreId, config, awsFilter, _nextToken = '') {
console.log('awsFilter=', awsFilter)

let imageSetSummaries = []
const maxImageSetsToReturn = 300
do {

const uri = `${config.endpoint}/datastore/${datastoreId}/searchImageSets?maxResults=50&${_nextToken ? 'nextToken='+_nextToken : ''}`;
Expand All @@ -52,7 +51,7 @@ async function getImageSets(datastoreId, config, awsFilter, _nextToken = '') {
imageSetSummaries = imageSetSummaries.concat(imageSetsMetadataSummaries)
_nextToken = nextToken

} while (imageSetSummaries.length < maxImageSetsToReturn && _nextToken)
} while (imageSetSummaries.length < config.maxImageSetsToReturn && _nextToken)
return imageSetSummaries;
}

Expand Down
1 change: 1 addition & 0 deletions src/utils/DicomTreeClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ export default class DicomTreeClient extends api.DICOMwebClient {
} = qidoConfig;
this.healthlake = {
groupSeriesBy: 'SeriesInstanceUID',
maxImageSetsToReturn: 300,
region: 'us-east-1',
endpoint: 'https://runtime-medical-imaging.us-east-1.amazonaws.com',
tree: true,
Expand Down

0 comments on commit df99bdd

Please sign in to comment.