Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/sql-server-2008/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
WebLogic 12中使用EJB3.0进行Eclipse3.8Web开发时出现项目依赖性错误_Eclipse_Weblogic_Ejb 3.0 - Fatal编程技术网

WebLogic 12中使用EJB3.0进行Eclipse3.8Web开发时出现项目依赖性错误

WebLogic 12中使用EJB3.0进行Eclipse3.8Web开发时出现项目依赖性错误,eclipse,weblogic,ejb-3.0,Eclipse,Weblogic,Ejb 3.0,在Eclipse中,我用EJB项目、EJBClient项目和WebProject创建了一个EAR项目 // at EJB Project @Entity public class Person { private int id; private String name; ...setter and getter } //SessionBean public class PersonTask implements PersonTaskRemote { Person f

在Eclipse中,我用EJB项目、EJBClient项目和WebProject创建了一个EAR项目

// at EJB Project
@Entity
public class Person {
    private int id;
    private String name;
    ...setter and getter
}

//SessionBean
public class PersonTask implements PersonTaskRemote {
  Person findPerson(int personId){
      do something;
}
我在EJB项目中创建了EntityBean Person和SessionBean PersonTask。Eclipse在EJBClient项目中自动创建PersonTaskRemote接口。以及在WebProject中创建的Servlet wird

// at EJB Project
@Entity
public class Person {
    private int id;
    private String name;
    ...setter and getter
}

//SessionBean
public class PersonTask implements PersonTaskRemote {
  Person findPerson(int personId){
      do something;
}

通过运行,Eclipse会得到一个错误!因为它在依赖关系(Project EJB和Project EJBClient)中有一个循环。我该怎么办

我曾在谷歌上搜索过,但在所有资助的教程中,界面都是在clienthat中,而不是在EntityBeans中。只有类似于
String sayHello()的内容函数

我怎样才能避免这个问题?可能在客户端项目中为接口创建本地实体

或者给我一些关于这些案例的教程


谢谢。

人员
移动到EJBClient模块。它显然是客户机的一部分,因为它是业务方法的返回值。在此之后,就不再有循环了,因为EJBClient不依赖于其他模块。

感谢您的快速回答。你能解释一下为什么需要一个客户端项目和一个web项目吗?Web也是一个客户端吗?它不是严格需要的。不过这是个好主意,因为否则您将从EJB项目依赖到web项目。