【发布时间】:2011-05-06 06:57:43
【问题描述】:
我遇到了这个异常:
java.rmi.RemoteException: CORBA BAD_OPERATION 1330446343 No; nested exception is: org.omg.CORBA.BAD_OPERATION: WARNING: IOP01210007: Expected typecode kind to be one of [value, valueBox, abstractInterface] but got typecode kind null vmcid: OMG minor code: 7 completed: No
当我尝试在 jsf 客户端(支持 bean)中调用 ejb 方法以获取样本列表时 List<Sample> l = ejbBean.getSamples();
这是我的 JPA 实体:
import java.io.Serializable;
import java.util.Date;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
@Entity
public class Sample implements Serializable {
/**
*
*/
private static final long serialVersionUID = 1L;
public Sample() {
}
@Id
@GeneratedValue
private Long id;
@Temporal(TemporalType.TIMESTAMP)
private Date date;
private String title;
private String description;
private String type;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public Date getDate() {
return date;
}
public void setDate(Date date) {
this.date = date;
}
public String getTitle() {
return title;
}
public void setTitle(String title) {
this.title = title;
}
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
}
独立客户端可以很好地使用相同的会话 bean,并且当我将 JPA 实体更改为纯 java 类而没有任何从 jsf 调用 ejb 的注释时效果很好。
【问题讨论】:
标签: java jsf jpa glassfish ejb