Skip to content

Added code to print out byte array data #305

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

Merged

Conversation

timmattison
Copy link
Contributor

I was working with Greengrass V2 IPC and sent an invalid IPC message to the Nucleus. When it received the message it printed out the following message:

2022-08-03T16:13:13.896Z [ERROR] (Thread-7) software.amazon.awssdk.eventstreamrpc.OperationContinuationHandler: [aws.greengrass#PublishToIoTCore] operation threw unexpected software.amazon.awssdk.eventstreamrpc.DeserializationException: Could not deserialize data: [[B@41467268]. {}

The deserialized data is hidden by the [B@41467268 string. This commit adds a stringify() method to the DeserializationException class to convert the data into a string that can be used for debugging and shows the exact array contents byte by byte.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@TwistedTwigleg
Copy link
Contributor

Thank you for making this PR! Merging into main...

@TwistedTwigleg TwistedTwigleg merged commit 06ae9c4 into aws:main Aug 11, 2022
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