Skip to content

Bug: Incorrect data types for sourceIPAddress and sequencer Fields in S3RecordSchema Model #3643

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

Closed
leandrodamascena opened this issue Feb 24, 2025 · 4 comments · Fixed by #3671
Assignees
Labels
bug Something isn't working completed This item is complete and has been merged/shipped good-first-issue Something that is suitable for those who want to start contributing parser This item relates to the Parser Utility

Comments

@leandrodamascena
Copy link
Contributor

Expected Behavior

When working with S3 LifecycleTransition events, the value of the sourceIPAddress field is s3.amazonaws.com instead of an IPv4 value. Additionally, the sequencer field is only populated on PUT and delete object events.

Current Behavior

These fields are using incorrect data types.

Code snippet

No code snippet.

Steps to Reproduce

use this payload with this model.

{
   "eventVersion":"2.3",
   "eventSource":"aws:s3",
   "awsRegion":"us-east-1",
   "eventTime":"2025-02-21T21:46:45.775Z",
   "eventName":"LifecycleTransition",
   "userIdentity":{
      "principalId":"s3.amazonaws.com"
   },
   "requestParameters":{
      "sourceIPAddress":"s3.amazonaws.com"
   },
   "responseElements":{
      "x-amz-request-id":"something-1",
      "x-amz-id-2":"something-2"
   },
   "s3":{
      "s3SchemaVersion":"1.0",
      "configurationId":"some-sns",
      "bucket":{
         "name":"bucket-name",
         "ownerIdentity":{
            "principalId":"PRICIPAL"
         },
         "arn":"arn:aws:s3:::bucket-name"
      },
      "object":{
         "key":"/path/to/file.parquet",
         "size":12345,
         "eTag":"abcdef1232423423",
         "versionId":"SomeThingThere"
      }
   },
   "lifecycleEventData":{
      "transitionEventData":{
         "destinationStorageClass":"INTELLIGENT_TIERING"
      }
   }
}

Possible Solution

No response

Powertools for AWS Lambda (TypeScript) version

latest

AWS Lambda function runtime

22.x

Packaging format used

npm

Execution logs

@leandrodamascena leandrodamascena added bug Something isn't working triage This item has not been triaged by a maintainer, please wait labels Feb 24, 2025
@dreamorosi dreamorosi added good-first-issue Something that is suitable for those who want to start contributing help-wanted We would really appreciate some support from community for this one parser This item relates to the Parser Utility and removed triage This item has not been triaged by a maintainer, please wait labels Feb 24, 2025
@dreamorosi dreamorosi moved this from Triage to Backlog in Powertools for AWS Lambda (TypeScript) Feb 24, 2025
@dreamorosi
Copy link
Contributor

Thanks for opening the issue Leo, I've put this in the backlog.

I've added the help-wanted and good-first-issue labels, so if anyone wants to pick this up in the next few days feel free to leave a comment to claim the issue.

If not, we'll work on it most likely before the end of the iteration, when we've completed the current backlog.

@ConnorKirk
Copy link
Contributor

I can pick this up

Copy link
Contributor

⚠️ COMMENT VISIBILITY WARNING ⚠️

This issue is now closed. Please be mindful that future comments are hard for our team to see.

If you need more assistance, please either tag a team member or open a new issue that references this one.

If you wish to keep having a conversation with other community members under this issue feel free to do so.

@github-actions github-actions bot added pending-release This item has been merged and will be released soon and removed help-wanted We would really appreciate some support from community for this one labels Feb 27, 2025
Copy link
Contributor

github-actions bot commented Mar 7, 2025

This is now released under v2.16.0 version!

@github-actions github-actions bot added completed This item is complete and has been merged/shipped and removed pending-release This item has been merged and will be released soon labels Mar 7, 2025
@dreamorosi dreamorosi moved this from Coming soon to Shipped in Powertools for AWS Lambda (TypeScript) Mar 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working completed This item is complete and has been merged/shipped good-first-issue Something that is suitable for those who want to start contributing parser This item relates to the Parser Utility
Projects
Development

Successfully merging a pull request may close this issue.

3 participants