Развертывание EJB 2.1 в выпуске weblogic 12c

Я пытаюсь развернуть EJB 2.1, обернутый в приложении EAR maven, в weblogic 12c, я упомянул, что предпочитаю ejb 2.1 jar в моем classpath, но все же я получаю приведенную ниже ошибку, поскольку она ссылается на weblogic ejb jar.

Я пробую разные вещи, но все же это не мое. Пожалуйста, найдите ниже XML-файлы и не могли бы вы помочь мне в решении этой проблемы?

Мне надоело искать причину:(

There are 6 nested errors:

weblogic.ejb.container.compliance.ComplianceException: In EJB MonthlySessionStatMgmt, the bean class must implement directly or indirectly the javax.ejb.SessionBean interface.
 at weblogic.ejb.container.compliance.SessionBeanClassChecker.checkClassImplementsSessionBean(SessionBeanClassChecker.java:68)

weblogic.ejb.container.compliance.ComplianceException: In EJB MonthlySessionStatMgmt, method getHandle() defined in the local interface either does not exist in the bean class, or it is not a public method. Each method in the local interface must have a corresponding public method in the bean class.
 at weblogic.ejb.container.compliance.BeanClassChecker.checkBusinessMethods(BeanClassChecker.java:328)

weblogic.ejb.container.compliance.ComplianceException: In EJB MonthlySessionStatMgmt, method getEJBHome() defined in the local interface either does not exist in the bean class, or it is not a public method. Each method in the local interface must have a corresponding public method in the bean class.
 at weblogic.ejb.container.compliance.BeanClassChecker.checkBusinessMethods(BeanClassChecker.java:328)

weblogic.ejb.container.compliance.ComplianceException: In EJB MonthlySessionStatMgmt, method getPrimaryKey() defined in the local interface either does not exist in the bean class, or it is not a public method. Each method in the local interface must have a corresponding public method in the bean class.
 at weblogic.ejb.container.compliance.BeanClassChecker.checkBusinessMethods(BeanClassChecker.java:328)

weblogic.ejb.container.compliance.ComplianceException: In EJB MonthlySessionStatMgmt, method isIdentical(javax.ejb.EJBObject) defined in the local interface either does not exist in the bean class, or it is not a public method. Each method in the local interface must have a corresponding public method in the bean class.
 at weblogic.ejb.container.compliance.BeanClassChecker.checkBusinessMethods(BeanClassChecker.java:328)

weblogic.ejb.container.compliance.ComplianceException: In EJB MonthlySessionStatMgmt, method remove() defined in the local interface either does not exist in the bean class, or it is not a public method. Each method in the local interface must have a corresponding public method in the bean class.
 at weblogic.ejb.container.compliance.BeanClassChecker.checkBusinessMethods(BeanClassChecker.java:328)

application.xml

    <?xml version="1.0" encoding="UTF-8"?>`enter code here
    <application xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xmlns="http://java.sun.com/xml/ns/javaee"
     xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_6.xsd"
     id="Application_ID" version="6">
     <display-name>XYZ</display-name>
     <module>
      <ejb>logar.jar</ejb>
     </module>
     <library-directory>lib</library-directory>
    </application>

WebLogic-application.xml

<?xml version='1.0' encoding='UTF-8'?>
<weblogic-application
 xmlns="http://xmlns.oracle.com/weblogic/weblogic-application"
 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
 xsi:schemaLocation="http://xmlns.oracle.com/weblogic/weblogic-application http://xmlns.oracle.com/weblogic/weblogic-application/1.5/weblogic-application.xsd">
 <ejb>
  <start-mdbs-with-application>false
  </start-mdbs-with-application>
 </ejb>
 <application-param>
  <param-name>webapp.encoding.default</param-name>
  <param-value>UTF-8</param-value>
 </application-param>
 <prefer-application-packages xsi:type="prefer-application-packagesType">
  <package-name>javax.ejb.*</package-name>
 </prefer-application-packages>
</weblogic-application>

EJB-jar.xml

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE ejb-jar PUBLIC '-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN' 'http://java.sun.com/dtd/ejb-jar_2_0.dtd'>
<!--
  ** This file was automatically generated by EJBGen 2.16
  ** Build: 20031001-1049
-->
<ejb-jar>
 <enterprise-beans>
  <session>
   <ejb-name>MonthlySessionStatMgmt</ejb-name>
   <home>com.xyz.MonthlySessionStatMgmtHome</home>
   <remote>com.xyz.MonthlySessionStatMgmt</remote>
   <ejb-class>com.xyz.MonthlySessionStatMgmtBean</ejb-class>
   <session-type>Stateless</session-type>
   <transaction-type>Container</transaction-type>
  </session>
 </enterprise-beans>
 <assembly-descriptor>
  <container-transaction>
   <method>
    <ejb-name>MonthlySessionStatMgmt</ejb-name>
    <method-name>*</method-name>
   </method>
    <trans-attribute>Required</trans-attribute> 
  </container-transaction>
  </assembly-descriptor>
</ejb-jar>

WebLogic-EJB-jar.xml

<weblogic-ejb-jar>
 <weblogic-enterprise-bean>
  <ejb-name>MonthlySessionStatMgmt</ejb-name>
  <stateless-session-descriptor>
   <pool>
    <max-beans-in-free-pool>1000</max-beans-in-free-pool>
    <initial-beans-in-free-pool>0</initial-beans-in-free-pool>
   </pool>
  </stateless-session-descriptor>
  <transaction-descriptor>
   <trans-timeout-seconds>45</trans-timeout-seconds>
  </transaction-descriptor>
  <enable-call-by-reference>true</enable-call-by-reference>
  <jndi-name>com/xyz/MonthlySessionStatMgmt</jndi-name>
 </weblogic-enterprise-bean>
</weblogic-ejb-jar>

0 ответов

Другие вопросы по тегам