我是spring-data-cassandra第一次设置并有这样的课程:
@Table(value = "contact")
public class Contact {
    @Id
    UUID id;
    ...
    Location Location;
    ...
    public void setLocation(Location location) {
        this.location = location;
    }
    public Location getLocation() {
        return location;
    }
}
这在启动时给了我一个错误:
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mySQLTransactionRepository': Invocation of init method failed; nested exception is org.springframework.data.cassandra.mapping.VerifierMappingExceptions: com.foo.backend.core.Location:
Cassandra entities must have the @Table, @Persistent or @PrimaryKeyClass Annotation
....
来自spring-data-jpa背景的简单注释以前就足够了Location。@Embeddable看起来这不适用于spring-data-cassandra. 如何使用复合实体spring-data-cassandra?
是否必须自己注释location并@Transient进行一些序列化?我试图用注释我的班级,@Persistent但收到关于PrimaryKey丢失的错误Location。我无法理解为什么需要主键...