【发布时间】:2016-01-24 01:12:44
【问题描述】:
这个错误信息是什么意思?
2016-01-23 19:07:24,914 WARN ta.neo4j.mapping.Neo4jPersistentProperty: 73 - Owning ClassInfo is null for field: private java.lang.Long com.xenoterracide.rpf.AbstractPersistable.id and propertyDescriptor: org.springframework.beans.GenericTypeAwarePropertyDescriptor[name=id]
这是这个类
public abstract class AbstractPersistable implements Identified<Long> {
private Long id;
@Override
public Long getId() {
return this.id;
}
}
【问题讨论】:
-
请发布如何使用这个抽象类的完整代码。它是
warning而不是error。似乎 Spring 期望ID字段用@GraphId注释,但如果您的实体中有其他字段用@GraphId注释,那么您可以忽略此警告。 -
@Sumit 我没有用它注释的其他字段,我尝试添加它,并没有使警告消失。我在其他领域也收到同样的警告
标签: java neo4j spring-data spring-data-neo4j spring-data-neo4j-4