我正在尝试在Hibernate-ogm中使用GridFS。这只是我的班级
import org.hibernate.ogm.datastore.mongodb.type.GridFS;
@Embeddable
public class MyEntity implements Serializable{
private String name;
public MyEntity () {
}
GridFS list;
}当我试图使这个实体持久化时,我在运行时得到了title中的错误。list上的Eclipse IDE字段显示“属性列表在此上下文中具有无效的映射类型”。
发布于 2019-02-13 01:46:00
目前,GridFS类型不能与关联一起使用。您只能将其用作实体的属性。
这里有一个问题:https://hibernate.atlassian.net/browse/OGM-1553你也可以在论坛上找到更多信息:https://discourse.hibernate.org/t/org-hibernate-hibernateexception-ogm000080-could-not-load-an-entity-batch/2148
https://stackoverflow.com/questions/54362067
复制相似问题