@Retention(value=RUNTIME) @Target(value={TYPE,FIELD,METHOD}) public @interface DynamoDBTypeConvertedEnum
Alternately, the DynamoDBTyped
annotation may be used,
public static enum Status { OPEN, PENDING, CLOSED } @DynamoDBTyped(DynamoDBAttributeType.S) public Status getStatus()
Please note, there are some risks in distributed systems when using enumerations as attributes intead of simply using a String. When adding new values to the enumeration, the enum only changes must be deployed before the enumeration value can be persisted. This will ensure that all systems have the correct code to map it from the item record in DynamoDB to your objects.
DynamoDBTypeConverted
Copyright © 2013 Amazon Web Services, Inc. All Rights Reserved.