Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pivotal ID # 171382047: Automate Stats Publishing #738

Merged
merged 4 commits into from
Aug 15, 2023

Conversation

jhoanmanuelms
Copy link
Contributor

  • Create async task to calculate the files size after submission
  • Add an endpoint to request the calculation of the files size stats for already existing submissions

- Create async task to calculate the files size after submission
- Add an endpoint to request the calculation of the files size stats for already existing submissions
@jhoanmanuelms jhoanmanuelms self-assigned this Aug 4, 2023
@jhoanmanuelms jhoanmanuelms requested a review from Juan-EBI August 4, 2023 15:54
Copy link
Contributor

@Juan-EBI Juan-EBI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM please consider minor comment

val sub = extSubmissionQueryService.getExtendedSubmission(accNo, includeFileListFiles = true)
logger.info { "${sub.accNo} ${sub.owner} Started calculating submission stats" }

val subFilesSize = serializationService.fileSequence(sub).fold(0L) { acc, extFile -> acc + extFile.size }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what about serializationService.fileSequence(sub).sumOf { it.size }

@jhoanmanuelms jhoanmanuelms merged commit b1d3938 into master Aug 15, 2023
@jhoanmanuelms jhoanmanuelms deleted the chore/pivotal-#171382047-file-size-stat branch August 15, 2023 17:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants