Skip to content

Conversation

irina-herciu
Copy link
Contributor

Add

  • support for the [DynamoDBAutoGeneratedTimestamp] attribute to the .NET SDK for DynamoDB, enabling automatic setting of timestamp fields during save operations. This feature aligns with the Java SDK's @DynamoDbAutoGeneratedTimestampAttribute.

Description

  • New Attribute: [DynamoDBAutoGeneratedTimestamp]

    • [DynamoDBAutoGeneratedTimestamp] Automatically sets the property to the current UTC timestamp (DateTime.UtcNow) on item save.
  • Usage:

    class Order
    {
        [DynamoDBHashKey]
        public string Id { get; set; }
    
        [DynamoDBAutoGeneratedTimestamp]
        public DateTime CreatedAt { get; set; }
    }

Motivation and Context

Testing

unit and integration tests added

Screenshots (if appropriate)

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • My code follows the code style of this project
  • My change requires a change to the documentation
  • I have updated the documentation accordingly
  • I have read the README document
  • I have added tests to cover my changes
  • All new and existing tests passed

License

  • I confirm that this pull request can be released under the Apache 2 license

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.

1 participant