[x] You have created a feature request first to discuss your contribution intent. Please reference the feature request ticket number in the pull request.
[x] You use the code formatters provided here and have them applied to your changes. Don’t submit any formatting related changes.
[x] You submit test cases (unit or integration tests) that back your changes.
Closes #2861
Added a convenience utility method to read the last message from a stream
Make sure that:
[x] You submit test cases (unit or integration tests) that back your changes.