aws / aws/aws-cloudtrail-processing-library

BasicPollQueueInfo.getPolledMessageCount() is always 0

Open
#15 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
95
Forks
32
PR merge metrics
No merged PRs in 30d

Description

When initialized the new BasicPollQueueInfo(), the polledMessageCount is set to 0: https://github.com/aws/aws-cloudtrail-processing-library/blob/9e03e4384742b5915c0da60b552d4c53252187fe/src/main/java/com/amazonaws/services/cloudtrail/processinglibrary/manager/SqsManager.java#L115

Upon getting the results of the request, the sqsMessages are set up and the actual count is logged: https://github.com/aws/aws-cloudtrail-processing-library/blob/9e03e4384742b5915c0da60b552d4c53252187fe/src/main/java/com/amazonaws/services/cloudtrail/processinglibrary/manager/SqsManager.java#L129

The BasicPollQueueInfo of the ProgressStatus is never updated to set the actual count.

I want to be able to check if the getSuccessPolledMessageCount() == 0, then do some additional logic, specifically, once the queue is empty, then I want to exit.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.