用Jackson反序列化PrimaryKey(DynamoDB)

时间:2017-03-22 09:31:10

标签: jackson amazon-dynamodb aws-java-sdk

当我尝试反序列化PrimaryKey时会抛出错误(序列化与Jackson相处得很好)。

我正在尝试以下方法:

Myobject myObject =(Myobject) mapper.convertValue(obj.get("myObject"), MyObject.class);

对象:

public class MyObject {

    private PrimaryKey primaryKey;
    private String attributeName;
    private String metaDataFieldName;
    private long numRepeated;

得到错误:

java.lang.IllegalArgumentException: (was java.lang.UnsupportedOperationException) (through reference chain: com.scanner.dynamodb.DynamoDBDataLink["primaryKey"]->com.amazonaws.services.dynamodbv2.document.PrimaryKey["componentNameSet"]->java.util.LinkedKeySet[0])

由于

0 个答案:

没有答案