-
I'm trying to get the S3ObjectCreated field values out of an aws_sdk_s3::types::Event (via an SQS Message), and for the life of me I can't work out why. I've read and reread the documentation around aws_sdk_s3::types::Event, and there's nothing that describes how that works - Event is only an enum, can only test for type, and there doesn't seem to be functions to get fields from the json-like body, it seems like the only way to extract these is using serde_json... Is this correct? Have I missed something? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
There is not a built in way to serialize/deserialize S3 event notifications. You may be able to re-use aws_lambda_events which does provide serde implementations. See also the S3 event message structure for reference: https://docs.aws.amazon.com/AmazonS3/latest/userguide/notification-content-structure.html |
Beta Was this translation helpful? Give feedback.
There is not a built in way to serialize/deserialize S3 event notifications.
You may be able to re-use aws_lambda_events which does provide serde implementations.
See also the S3 event message structure for reference: https://docs.aws.amazon.com/AmazonS3/latest/userguide/notification-content-structure.html