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

Add undeliveredUploads feature to UploadStats. #197

Merged
merged 12 commits into from
Oct 1, 2024

Conversation

mtammineni
Copy link
Collaborator

Update the GetUploadStats query to search for and provide the response for "undelivered uploads" and the associated counts as part of the query response.

Update the GetUploadStats query to search for and provide the response for "undelivered uploads" and the associated counts as part of the query response.
@@ -72,6 +71,18 @@ class UploadStatsLoader: CosmosLoader() {
+ ") r where r.totalCount > 1"
)

val unDeliveredUploadsQuery = (
Copy link
Collaborator

Choose a reason for hiding this comment

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

This query is sufficient for detecting explicitly undelivered uploads with reports that contain a failure status. However, we need a second query to look for uploads where this report is missing.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Updated the code to fetch the uploads where the report is missing for the stage, "blob-file-copy". For a given dataStreamId, dataStreamRoute and the start and the end dates, we check for any difference in the total uploads with stage-action = "metadata-verify" and stage-action ="blob-file-copy", get the respective undelivered upload ids as well.

Update the GetUploadStats query to search for and provide the response for "undelivered uploads" and the associated counts as part of the query response (Send the counts, filename and uploadId).
…es for blob-file-copy in teh reports container
Copy link
Collaborator

@mkrystof mkrystof left a comment

Choose a reason for hiding this comment

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

There looks to be some opportunities to improve the efficiency by reducing the number of queries run. Also, there may be some holes in the logic we should revisit. Approving so we can get this deployed, knowing we may be taking on some tech debt.

Copy link

sonarcloud bot commented Oct 1, 2024

@mtammineni
Copy link
Collaborator Author

Note: Need to work on query optimization and other improvements

@mtammineni mtammineni merged commit 9bf81a9 into develop Oct 1, 2024
1 of 2 checks passed
@mtammineni mtammineni deleted the dev-feature-undeliveredUploads branch October 1, 2024 13:00
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