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

admin/message-log: reflect sent time in sort order #2742

Merged
merged 3 commits into from
Dec 29, 2022

Conversation

cmarquis
Copy link
Contributor

@cmarquis cmarquis commented Dec 13, 2022

  • Identified the issue which this PR solves.
  • Read the CONTRIBUTING document.
  • Code builds clean without any errors or warnings.
  • Added appropriate tests for any new functionality.
  • All new and existing tests passed.
  • Added comments in the code, where necessary.
  • Ran make check to catch common errors. Fixed any that came up.

Description:
The admin message log will now display messages that have not yet been sent at the top of the list and then sort by the created time thereafter.

Which issue(s) this PR fixes:
Fixes #2650

Describe any introduced user-facing changes:

  • The sorting of the admin message logs was affected as described in the description above.
  • Added the sent at time to the message details
  • Added the retry count to the message details, if greater than 0

Describe any introduced API changes:
Added sentAt and retryCount to the DebugMessage type.

Additional Info:

  • Updated the sql query and model to retrieve the sent_at and retry_count values from the database
  • Updated the sql query to sort messages first by any messages where sent_at is null and then created_at
  • Added a new smoke test to validate the sorting is being applied properly

- Add sent time to message logs
- Add retry count to message logs
- Sort message logs first by null sent time then by created at to surface unsent messages
@mastercactapus mastercactapus changed the title Reflect sent time in message logs admin/message-log: reflect sent time in sort order Dec 15, 2022
@Forfold Forfold self-requested a review December 19, 2022 20:27
@mastercactapus mastercactapus merged commit 6650517 into master Dec 29, 2022
@mastercactapus mastercactapus deleted the 2650-sort-message-logs branch December 29, 2022 20:44
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.

admin: message log does not reflect sent time
3 participants