Appc generate ejb.jar error

Hi
I tried weblogic.appc (WL8 sp2) to generate a very simple stateless ejb, it
has warings when compiling:
java weblogic.appc trader.jarE:\Tmp\appcgen\statelessSession_mt9oui_HomeImpl.java:43: warning:
non-varargs call of varargs method with
inexact argument type for last parameter;
cast to java.lang.Class for a varargs call
cast to java.lang.Class[] for a non-varargs call and to suppress this
warning
"ejbCreate", null);
^
E:\Tmp\appcgen\statelessSession_mt9oui_HomeImpl.java:47: warning:
non-varargs call of varargs method with
inexact argument type for last parameter;
cast to java.lang.Class for a varargs call
cast to java.lang.Class[] for a non-varargs call and to suppress this
warning
"ejbPostCreate", null);
^
2 warnings
then, when deploying it via WL console, it has exceptions:
Exception:weblogic.management.ApplicationException: prepare failed for
trader Module: trader Error: Exception preparing module:
EJBModule(trader,status=NEW) Unable to deploy EJB: statelessSession from
trader.jar: java.lang.AssertionError: Unable to find expected methods.
Please check your classpath for stale versions of your ejb classes and
re-run weblogic.ejbc at
statelessSession_mt9oui_HomeImpl.<clinit>(statelessSession_mt9oui_HomeImpl.j
ava:55) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method) at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAcces
sorImpl.java:39) at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstruc
torAccessorImpl.java:27) at
java.lang.reflect.Constructor.newInstance(Constructor.java:274) at
java.lang.Class.newInstance0(Class.java:306) at
java.lang.Class.newInstance(Class.java:259) at
weblogic.ejb20.deployer.ClientDrivenBeanInfoImpl.prepare(ClientDrivenBeanInf
oImpl.java:974) at
weblogic.ejb20.deployer.EJBDeployer.setupBeanInfos(EJBDeployer.java:983) at
weblogic.ejb20.deployer.EJBDeployer.prepare(EJBDeployer.java:1283) at
weblogic.ejb20.deployer.EJBModule.prepare(EJBModule.java:477) at
weblogic.j2ee.J2EEApplicationContainer.prepareModule(J2EEApplicationContaine
r.java:29
Can any help?
Thanks
John woo
Toronto

John,
"John Woo" <[email protected]> wrote in message news:[email protected]...
Thanks lots, Slava .
U r right, now instead of using javac, I'm using jikes, which is good for
all jdk.The problem is that your Java runtime may be still 1.5, so you may get other
strange errors. I don't think you will need 1.5 for a while, at least to develop
apps under weblogic. You may want to review your environment settings.
HTH.
Regards,
Slava Imeshev
>
>
>
>
John Woo
Toronto
"Slava Imeshev" <[email protected]> wrote in message
news:[email protected]...
Hi John,
Make sure that you are using JDK 1.4.2, not 1.5.x. You may know your javaversion by
running this command:
java -version
Hope this helps.
Regards,
Slava Imeshev
"John Woo" <[email protected]> wrote in message
news:[email protected]...
Hi
I tried weblogic.appc (WL8 sp2) to generate a very simple statelessejb, it
has warings when compiling:
java weblogic.appc trader.jarE:\Tmp\appcgen\statelessSession_mt9oui_HomeImpl.java:43: warning:
non-varargs call of varargs method with
inexact argument type for last parameter;
cast to java.lang.Class for a varargs call
cast to java.lang.Class[] for a non-varargs call and to suppress this
warning
"ejbCreate", null);
^
E:\Tmp\appcgen\statelessSession_mt9oui_HomeImpl.java:47: warning:
non-varargs call of varargs method with
inexact argument type for last parameter;
cast to java.lang.Class for a varargs call
cast to java.lang.Class[] for a non-varargs call and to suppress this
warning
"ejbPostCreate", null);
^
2 warnings
then, when deploying it via WL console, it has exceptions:
Exception:weblogic.management.ApplicationException: prepare failed for
trader Module: trader Error: Exception preparing module:
EJBModule(trader,status=NEW) Unable to deploy EJB: statelessSession from
trader.jar: java.lang.AssertionError: Unable to find expected methods.
Please check your classpath for stale versions of your ejb classes and
re-run weblogic.ejbc at
statelessSession_mt9oui_HomeImpl.<clinit>(statelessSession_mt9oui_HomeImpl.j
ava:55) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method) at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAcces
sorImpl.java:39) at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstruc
torAccessorImpl.java:27) at
java.lang.reflect.Constructor.newInstance(Constructor.java:274) at
java.lang.Class.newInstance0(Class.java:306) at
java.lang.Class.newInstance(Class.java:259) at
weblogic.ejb20.deployer.ClientDrivenBeanInfoImpl.prepare(ClientDrivenBeanInf
oImpl.java:974) at
weblogic.ejb20.deployer.EJBDeployer.setupBeanInfos(EJBDeployer.java:983)at
weblogic.ejb20.deployer.EJBDeployer.prepare(EJBDeployer.java:1283) at
weblogic.ejb20.deployer.EJBModule.prepare(EJBModule.java:477) at
weblogic.j2ee.J2EEApplicationContainer.prepareModule(J2EEApplicationContaine
r.java:29
Can any help?
Thanks
John woo
Toronto

Similar Messages

  • Failed to load java type corresponding to e=weblogic-ejb-jar Error

    Hi,
    I am getting the following error when I try to build my application.
    [java] <Aug 21, 2007 11:56:52 AM IST> <Error> <J2EE> <BEA-160187> <weblogic.appc failed to compile your application. Recompile with the -verbose option for more details. Please see the error mess
    age(s) below.>
    [java] failed to load java type corresponding to e=weblogic-ejb-jar@http://www.bea.com/ns/weblogic/910
    Note that I am upgrading my 8.1 descriptors to 9.1.
    Any help is appriciated.
    Thanks
    Rajaram

    Try the 90 namespace, even if you are running 9.1 or 9.2
    <weblogic-ejb-jar xmlns="http://www.bea.com/ns/weblogic/90"

  • XDoclet  and ejb-jar.xml - No Entity tags?

    build.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <project name="XDoclet" default="ejbdoclet">
         <property file="build.properties"/>
         <target name="init">
              <property name="dir" value="G:\JAVA Tools"/>
              <property name="lib.dir" value="lib"/>
    <!-- library/jar path -->
              <property name="xdoclet.jar.path" value="${dir}\XDoclet\lib\xdoclet.jar"/>
              <property name="log4j.jar.path" value="${dir}\XDoclet\samples\lib\log4j.jar"/>
              <property name="ant.jar.path" value="${dir}\ANT\lib\ant.jar"/>
              <property name="src.dir" value="src"/>
              <property name="generated.src.dir" value="XDoclet/gen-src-code"/>
              <property name="web.dir" value="${src.dir}/web"/>
         <property name="generated.java.dir" value="${generated.src.dir}/java"/>
              <property name="config.dir" value="config"/>
              <property name="build.dir" value="XDoclet/build"/>
              <property name="dist.dir" value="XDoclet/dist"/>
              <property name="build.compiler" value="modern"/>
              <path id="project.class.path">
                   <fileset dir="${lib.dir}">
                        <include name="**/*.jar"/>
                   </fileset>
                   <!-- append the external classpath lastly -->
                   <pathelement path="${java.class.path};${log4j.jar.path}"/>
              </path>
         </target>
         <!-- Prepare -->
         <target name="prepare" depends="init">
              <mkdir dir="${build.dir}"/>
              <mkdir dir="${build.dir}/ejb"/>
              <mkdir dir="${build.dir}/ejb/META-INF"/>
              <mkdir dir="${build.dir}/web"/>
              <mkdir dir="${build.dir}/web/WEB-INF"/>
              <mkdir dir="${build.dir}/web/WEB-INF/tlds"/>
              <mkdir dir="${build.dir}/web/WEB-INF/classes"/>
              <mkdir dir="${build.dir}/j2ee"/>
              <mkdir dir="${build.dir}/j2ee/META-INF"/>
              <mkdir dir="${build.dir}/jmx"/>
              <mkdir dir="${dist.dir}"/>
              <mkdir dir="${generated.src.dir}"/>
              <mkdir dir="${generated.java.dir}"/>
              <echo message="XDoclet Path = ${xdoclet.jar.path}"/>
              <echo message="Log4J Path = ${log4j.jar.path}"/>
              <echo message="Ant Path = ${ant.jar.path}"/>
              <echo message="ClassPath = ${java.class.path}"/>
              <property name="cp" refid="project.class.path"/>
              <echo message="CLASSPATH/REF ID:${cp}"/>
              <echo message="base dir = ${basedir}/${src.dir}"/>
         </target>
         <target name="delete" >
         <echo message = "Deleting directories"/>
              <delete dir="${build.dir}"/>
              <delete dir="${build.dir}/ejb"/>
              <delete dir="${build.dir}/ejb/META-INF"/>
              <delete dir="${build.dir}/web"/>
              <delete dir="${build.dir}/web/WEB-INF"/>
              <delete dir="${build.dir}/web/WEB-INF/tlds"/>
              <delete dir="${build.dir}/web/WEB-INF/classes"/>
              <delete dir="${build.dir}/j2ee"/>
              <delete dir="${build.dir}/j2ee/META-INF"/>
              <delete dir="${build.dir}/jmx"/>
              <delete dir="${dist.dir}"/>
              <delete dir="${generated.src.dir}"/>
              <delete dir="${generated.java.dir}"/>
         </target>
         <!-- Run EJBDoclet -->
         <target name="ejbdoclet" depends="prepare">
              <taskdef name="ejbdoclet"
                   classname="xdoclet.ejb.EjbDocletTask"
                   classpath="${java.class.path};${log4j.jar.path};${ant.jar.path};${xdoclet.jar.path} "/>
              <ejbdoclet sourcepath="${src.dir}"
    destdir="${generated.java.dir}"
                   classpathref="project.class.path"
                   excludedtags="@version,@author"
                   ejbspec="2.0"
                   >
                   <fileset dir="${src.dir}">
                        <include name="**/*EJB.java"/>
                   </fileset>
                   <dataobject/>
    <!-- <localinterface/>
    <localhomeinterface/> -->
                   <remoteinterface/>
                   <homeinterface/>
                   <entitypk/>
    <!--               <entitycmp/> -->
                   <deploymentdescriptor destdir="${build.dir}/ejb/META-INF" validatexml="true"/>
                   <jboss version="2.4" xmlencoding="UTF-8" validatexml="true" typemapping="Hypersonic
                   SQL" datasource="java:/DefaultDS" destdir="${build.dir}/ejb/META-INF"/>
                   <!--
                   <weblogic xmlencoding="UTF-8" destdir="${build.dir}/ejb/META-INF" validatexml="true"/>
         <webSphere destdir="${build.dir}/ejb/META-INF" />
         <orion/>
                   <apachesoap destdir="${build.dir}/web"/>
         -->
                   <!--
    Have struts form objects generated based on entity beans'
    data objects. Will require struts.jar to compile.
    <strutsform />
    -->
              </ejbdoclet>
         </target>
    </project>
    My Session Bean:
    package com.uniserv.comn.controller.ejb.session.terminalfacade;
    * <p>Title: </p>
    * <p>Description: </p>
    * <p>Copyright: Copyright (c) 2003</p>
    * <p>Company: </p>
    * @author unascribed
    * @version 1.0
    import javax.ejb.*;
    import java.util.*;
    import com.uniserv.comn.util.*;
    import com.uniserv.comn.model.*;
    import com.uniserv.comn.controller.ejb.entity.tenderconfig.*;
    public class TerminalSessionFacadeEJB implements SessionBean {
    private SessionContext ctx = null;
    private ServiceLocator serviceLocator = null;
    public TerminalSessionFacadeEJB() throws ServiceLocatorException {
    try {
    serviceLocator = ServiceLocator.getInstance();
    } catch (Exception e) {
    System.out.println("TerminalSessionFacade Exception : " + e.getMessage());
    * Adds an tenderConfig record
    * @param tenderConfigVO TenderConfig's Value Object
    * @return boolean true if successful, false if not
    public boolean addTenderConfig(TenderConfigVO tenderConfigVO) {
              System.out.println("TerminalSessionFacadeEJB.addTenderConfig - START");
    boolean blnRet = false;
    try {
    LocalTenderConfigHome home = (LocalTenderConfigHome)
    serviceLocator.getLocalHome(ServiceLocator.Services.TENDERCONFIG);
    LocalTenderConfig local = null;
    try {
    TenderConfigPK pk
    = new TenderConfigPK(tenderConfigVO.getTndrID(), tenderConfigVO.getTndrCfgName());
    local = home.findByPrimaryKey(pk);
    } catch (Exception e) {
    System.out.println(e.getMessage());
    } finally {
    if (local == null) {
    home.create(tenderConfigVO);
    blnRet = true;
    } else {
    blnRet = false;
    } catch (Exception e) {
    System.out.println("Error in TerminalSessionFacadeEJB.addTenderConfig "
    + "method (Exception) : "
    + e.getMessage());
    } finally {
    System.out.println("Returned value : " + blnRet);
              System.out.println("TerminalSessionFacadeEJB.addTenderConfig - END");
    return blnRet;
    public void setSessionContext(SessionContext parm1) throws javax.ejb.EJBException, java.rmi.RemoteException {
    this.ctx = parm1;
    public void ejbRemove() throws javax.ejb.EJBException, java.rmi.RemoteException
    public void ejbActivate() throws javax.ejb.EJBException, java.rmi.RemoteException
    public void ejbPassivate() throws javax.ejb.EJBException, java.rmi.RemoteException
    public void ejbCreate() throws javax.ejb.EJBException
    My Entity Bean:
    package com.uniserv.comn.controller.ejb.entity.tenderconfig;
    * @ejb.bean
    * type="CMP"
    * cmp-version="2.x"
    * name="TenderConfigEJB"
    * schema="TenderConfig"
    * view-type="local"
    import javax.ejb.*;
    import com.uniserv.comn.model.*;
    public abstract class TenderConfigEJB implements EntityBean{
    private EntityContext ctx = null;
    * @ejb.pk
    public abstract int getTndrID();
    public abstract void setTndrID(int iTndrID);
    * @ejb.pk
    public abstract String getTndrCfgName();
    public abstract void setTndrCfgName(String strTndrCfgName);
    public abstract int getTndrType();
    public abstract void setTndrType(int iTndrType);
    public abstract String getTndrCfgValue();
    public abstract void setTndrCfgValue(String strTndrCfgValue);
    public abstract String getTndrCfgDataType();
    public abstract void setTndrCfgDataType(String strTndrCfgDataType);
    public abstract String getTndrCfgDesc();
    public abstract void setTndrCfgDesc(String strTndrCfgDesc);
    public TenderConfigVO getTenderConfigVO() {
    TenderConfigVO tenderConfigVO = new TenderConfigVO();
    tenderConfigVO.setTndrID(this.getTndrID());
    tenderConfigVO.setTndrCfgName(this.getTndrCfgName());
    tenderConfigVO.setTndrType(this.getTndrType());
    tenderConfigVO.setTndrCfgValue(this.getTndrCfgValue());
    tenderConfigVO.setTndrCfgDataType(this.getTndrCfgDataType());
    tenderConfigVO.setTndrCfgDesc(this.getTndrCfgDesc());
    return tenderConfigVO;
    public void setTenderConfigVO(TenderConfigVO tenderConfigVO) {
    this.setTndrID(tenderConfigVO.getTndrID());
    this.setTndrCfgName(tenderConfigVO.getTndrCfgName());
    this.setTndrType(tenderConfigVO.getTndrType());
    this.setTndrCfgValue(tenderConfigVO.getTndrCfgValue());
    this.setTndrCfgDataType(tenderConfigVO.getTndrCfgDataType());
    this.setTndrCfgDesc(tenderConfigVO.getTndrCfgDesc());
    * Constructor
    public TenderConfigEJB() {
    * ejbCreate callback method
    * @return int
    public TenderConfigPK ejbCreate(TenderConfigVO tenderConfigVO)
    throws CreateException {
    this.setTenderConfigVO(tenderConfigVO);
    return null;
    * ejbPostCreate
    * @param TerminalConfigTypeVO
    public void ejbPostCreate(TenderConfigVO tenderConfigVO) {
    * setEntityContext callback method
    public void setEntityContext(EntityContext ctx) {
    this.ctx = ctx;
    * unsetEntityContext callback method
    public void unsetEntityContext() {
    this.ctx = null;
    * ejbActivate callback method
    public void ejbActivate() {
    * ejbPassivate callback method
    public void ejbPassivate() {
    * ejbLoad callback method
    public void ejbLoad() {
    * ejbRemove callback method
    public void ejbRemove() {
    * ejbStore callback method
    public void ejbStore() {
    But the generated ejb-jar.xml only contains
    <?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">
    <ejb-jar>
         <description>No Description.</description>
         <display-name>Generated by XDoclet</display-name>
         <enterprise-beans>
              <!-- Session Beans -->
              <session>
                   <description><![CDATA[No Description.]]></description>
                   <ejb-name>com.uniserv.comn.controller.ejb.session.terminalfacade.TerminalSessionFacade</ejb-name>
                   <home>com.uniserv.comn.controller.ejb.session.terminalfacade.TerminalSessionFacadeHome</home>
                   <remote>com.uniserv.comn.controller.ejb.session.terminalfacade.TerminalSessionFacade</remote>
                   <ejb-class>com.uniserv.comn.controller.ejb.session.terminalfacade.TerminalSessionFacadeEJB</ejb-class>
                   <session-type>Stateless</session-type>
                   <transaction-type>Container</transaction-type>
              </session>
              <!--
    To add session beans that you have deployment descriptor info for, add
    a file to your merge directory called session-beans.xml that contains
    the <session></session> markup for those beans.
    -->
              <!-- Entity Beans -->
              <!--
    To add entity beans that you have deployment descriptor info for, add
    a file to your merge directory called entity-beans.xml that contains
    the <entity></entity> markup for those beans.
    -->
              <!-- Message Driven Beans -->
              <!--
    To add message driven beans that you have deployment descriptor info for, add
    a file to your merge directory called message-driven-beans.xml that contains
    the <message-driven></message-driven> markup for those beans.
    -->
         </enterprise-beans>
         <!-- Relationships -->
         <!-- Assembly Descriptor -->
         <assembly-descriptor>
              <!-- finder permissions -->
              <!-- transactions -->
              <!-- finder transactions -->
         </assembly-descriptor>
    </ejb-jar>
    this ejb-jar.xml only contains entries for session beans? where did the entries for entity beans went?Ive written XDoclet tags for the Entity Bean as what ive posted above....help!!!

    you comment the generation of CMP entity beans out :
    build.xml:
    replace
    <!-- <entitycmp/> -->
    with
    <entitycmp/>i've already removed the comments of the tag <entitycmp> and yet the resulting ejb-jar.xml contains no <entity> tags....i'm just wondering how can i include the generation of entity tags (not only session tags) in the resulting ejb-jar.xml
    <ejb-jar>
    <description>No Description.</description>
         <display-name>Generated by XDoclet</display-name>
         <enterprise-beans>
              <!-- Session Beans -->
              <session>
                   <description><![CDATA[No Description.]]></description>
                   <ejb-name>com.uniserv.comn.controller.ejb.session.terminalfacade.TerminalSessionFacade</ejb-name>
                   <home>com.uniserv.comn.controller.ejb.session.terminalfacade.TerminalSessionFacadeHome</home>
                   <remote>com.uniserv.comn.controller.ejb.session.terminalfacade.TerminalSessionFacade</remote>
                   <ejb-class>com.uniserv.comn.controller.ejb.session.terminalfacade.TerminalSessionFacadeEJB</ejb-class>
                   <session-type>Stateless</session-type>
                   <transaction-type>Container</transaction-type>
              </session>
              <!--
    To add session beans that you have deployment descriptor info for, add
    a file to your merge directory called session-beans.xml that contains
    the <session></session> markup for those beans.
    -->
              <!-- Entity Beans -->
              <!--
    To add entity beans that you have deployment descriptor info for, add
    a file to your merge directory called entity-beans.xml that contains
    the <entity></entity> markup for those beans.
    -->
              <!-- Message Driven Beans -->
              <!--
    To add message driven beans that you have deployment descriptor info for, add
    a file to your merge directory called message-driven-beans.xml that contains
    the <message-driven></message-driven> markup for those beans.
    -->
         </enterprise-beans>
         <!-- Relationships -->
         <!-- Assembly Descriptor -->
         <assembly-descriptor>
              <!-- finder permissions -->
              <!-- transactions -->
              <!-- finder transactions -->
         </assembly-descriptor>
    </ejb-jar>

  • How to add environment entry in EJB3 ejb-jar.xml

    Hi,
    Is that a build in way of add environment entries in JDev for EJB 3 beans? For EJB 2 beans you can do that using properties. But the bean properties is not available in EJB 3. Please help.
    Thanks
    Kenny

    Thank you for the reply. But I need a way to enter env-entry value in ejb-jar.xml for EJB 3 in Jdev. In EJB 2, Jdev generate ejb-jar.xml for the bean and also let you add env-entry through bean's properties menu. But in there in no properties menu for EJB 3, also generated ejb-jar.xml is only a empty file doesn't contain any EJB depolyment information. That means you have to code ejb-jar.xml all manually.
    If I am wrong, can someone show me how to do this right?

  • Oc4j generated finders in orion-ejb-jar.xml file causing errors

    Any information or assistance would be greatly appreciated.
    I have encountered a problem with the generated orion-ejb-jar.xml file.
    It looks like the additional finder methods that are generated when the application
    is deployed are incorrect from the 9.0.3 version to the new 10.1.2.0.2 version.
    The original content of orion-ejb-jar.xml before additional finder syntax is added:
    <finder-method query=
    "NO_SYS_USER_OBJECT_HISTORY.USER_ID=UPPER($1) and
      NO_SYS_USER_OBJECT_HISTORY.AUTOID NOT IN(
      SELECT H1.AUTOID                             
      FROM   NO_SYS_USER_OBJECT_HISTORY H1,                                
             (SELECT AUTOID                                     
              FROM   NO_SYS_USER_OBJECT_HISTORY                                    
              WHERE  USER_ID=UPPER($1)                                    
              ORDER BY DATE_TIME DESC) H2                            
      WHERE  ROWNUM &lt;= $2
        AND  H1.AUTOID = H2.AUTOID)">
    <method>
      <ejb-name>NoUserHistoryEntry</ejb-name>
      <method-name>findOldest</method-name>
      <method-params>
       <method-param>java.lang.String</method-param>
       <method-param>java.lang.Integer</method-param>
      </method-params>
    </method>
    </finder-method>
    After deploying in 9.0.3 the following information is added to the orion-ejb-jar.xml file:
    <finder-method query=
    "NO_SYS_USER_OBJECT_HISTORY.USER_ID=UPPER($1) and
      NO_SYS_USER_OBJECT_HISTORY.AUTOID NOT IN(
      SELECT H1.AUTOID
      FROM   NO_SYS_USER_OBJECT_HISTORY H1,
             (SELECT AUTOID                                     
              FROM   NO_SYS_USER_OBJECT_HISTORY
              WHERE  USER_ID=$1   
              ORDER BY DATE_TIME DESC) H2
      WHERE  ROWNUM &lt;= $2
        AND  H1.AUTOID = H2.AUTOID)">
    <!-- Generated SQL:
      "select NO_SYS_USER_OBJECT_HISTORY.autoid
       from   NO_SYS_USER_OBJECT_HISTORY
       where  NO_SYS_USER_OBJECT_HISTORY.USER_ID=UPPER(?)
         and  NO_SYS_USER_OBJECT_HISTORY.AUTOID NOT IN(
              SELECT H1.AUTOID                             
              FROM   NO_SYS_USER_OBJECT_HISTORY H1,
                     (SELECT AUTOID
                      FROM   NO_SYS_USER_OBJECT_HISTORY
                      WHERE  USER_ID=?
                      ORDER BY DATE_TIME DESC) H2
              WHERE ROWNUM <= ?
                AND H1.AUTOID = H2.AUTOID) -->
    <method>
      <ejb-name>NoUserHistoryEntry</ejb-name>
      <method-name>findOldest</method-name>
      <method-params>
       <method-param>java.lang.String</method-param>
       <method-param>java.lang.Integer</method-param>
      </method-params>
    </method>
    </finder-method>
    After deploying in 10.1.2.0.2 the following information is added to the
    orion-ejb-jar.xml file:
    <finder-method query=
    "NO_SYS_USER_OBJECT_HISTORY.USER_ID=UPPER($1) and
      NO_SYS_USER_OBJECT_HISTORY.AUTOID NOT IN(
      SELECT H1.AUTOID
      FROM   NO_SYS_USER_OBJECT_HISTORY H1,
             (SELECT AUTOID
              FROM   NO_SYS_USER_OBJECT_HISTORY
              WHERE  USER_ID=UPPER($1)
              ORDER BY DATE_TIME DESC) H2
      WHERE  ROWNUM &lt;= $2
        AND  H1.AUTOID = H2.AUTOID)">
    <!-- Generated SQL (pk only):
      "select H1.autoid
       from   NO_SYS_USER_OBJECT_HISTORY
       where  NO_SYS_USER_OBJECT_HISTORY.USER_ID=UPPER(?)
         and  NO_SYS_USER_OBJECT_HISTORY.AUTOID NOT IN(
              SELECT H1.AUTOID
              FROM   NO_SYS_USER_OBJECT_HISTORY H1,
                     (SELECT AUTOID
                      FROM   NO_SYS_USER_OBJECT_HISTORY
                      WHERE  USER_ID=UPPER(?)
                      ORDER BY DATE_TIME DESC) H2
              WHERE  ROWNUM <= ?
                AND  H1.AUTOID = H2.AUTOID) -->
    <!-- Generated SQL (all columns):
      "select H1.autoid, H1.USER_ID, H1.OBJECT_CLASS_ID,
                 H1.DATE_TIME, H1.COMMENT_TEXT, H1.ACTION,
                 H1.ACTION_DATA, H1.SITE_DESCRIPTION
       from   NO_SYS_USER_OBJECT_HISTORY
       where  NO_SYS_USER_OBJECT_HISTORY.USER_ID=UPPER(?)
         and  NO_SYS_USER_OBJECT_HISTORY.AUTOID NOT IN(
              SELECT H1.AUTOID
              FROM   NO_SYS_USER_OBJECT_HISTORY H1,
                     (SELECT AUTOID
                      FROM   NO_SYS_USER_OBJECT_HISTORY
                      WHERE  USER_ID=UPPER(?)
                      ORDER BY DATE_TIME DESC) H2
              WHERE  ROWNUM <= ?
                AND  H1.AUTOID = H2.AUTOID) -->
    <method>
      <ejb-name>NoUserHistoryEntry</ejb-name>
      <method-name>findOldest</method-name>
      <method-params>
       <method-param>java.lang.String</method-param>
       <method-param>java.lang.Integer</method-param>
      </method-params>
    </method>
    </finder-method>
    The problem with the 10.1.2.0.2 generated finders is that it is prepending H1 when
    it should be NO_SYS_USER_OBJECT_HISTORY which results in the following error:
    Exception in thread "main" com.cdtelecom.vygroe.configuration.ConfigurationException:
    com.evermind.server.rmi.OrionRemoteException:
    Transaction was rolled back: Database error: java.sql.SQLException:
    ORA-00904: "H1"."SITE_DESCRIPTION": invalid identifier
    ; nested exception is:
            java.sql.SQLException: ORA-00904: "H1"."SITE_DESCRIPTION": invalid identifier
            at com.cdtelecom.vygroe.configuration.ConfigurationSession.internalRecordAction(ConfigurationSession.java:869)
            at com.cdtelecom.vygroe.configuration.ConfigurationSession.recordAction(ConfigurationSession.java:401)
            at com.cdtelecom.vygroe.configuration.Configuration.recordActionSaveOrder(Configuration.java:886)
            at com.cdtelecom.vygroe.configuration.Configuration.getOrder(Configuration.java:239)
            at test10g.main(test10g.java:47)
    I tried to manually edit the file but when I shutdown and restart oc4j it regenerates the file again.

    Jingzhi -- If you define the correct EJB-QL you should get the correct SQL generated for the finder. If that's not happening can you verify it against the OC4J v903 production release and see if it is still happening. I don't know if this helps with the JDeveloper problem specifically but if you don't need to create your own finders then that I hope should help.
    Thanks -- Jeff

  • [EJB:010112] - error with WLI8.1 Event Generator for foreign JMS/MQ provider

    I'm getting following error in weblogic server log when starting a JMS Event generator
    to a foreign JMS(MQ5.3) Queue.
    <May 4, 2004 4:44:35 PM PDT> <Warning> <EJB> <BEA-010096> <The Message-Driven
    EJ
    B: mqQueueEventGen is unable to connect to the JMS destination: WAL1021852D_Test
    JMSQueue. Connection failed after 2 attempts. The MDB will attempt to reconnect
    every 10 seconds. This log message will repeat every 600 seconds until the condi
    tion clears.>
    <May 4, 2004 4:44:35 PM PDT> <Warning> <EJB> <BEA-010061> <The Message-Driven
    EJ
    B: mqQueueEventGen is unable to connect to the JMS destination: WAL1021852D_Test
    JMSQueue. The Error was:
    [EJB:010112]The Message Driven Bean 'mqQueueEventGen' is transacted, but the pro
    vider defined in the EJB is not transacted. Provider should be transacted if onM
    essage method in MDB is transacted.>
    My WLI8.1.2 is patched with CR131686_812.zip to support event generator for foreign
    JMS destinations. The foreign JMS/MQ provider is configured properly. QueueSend/Receive
    were tested fine with JMS java code using local JNDI names of foreign JMS objects.
    So we know that foreign Queue is active and accessiable from webLogic.
    Anyone run into this? Solution?
    Thanks,
    Scott

    Hi Scott,
    I need a transaction from the MDB since I am not using an EJb to pursue the action.
    Hence I need to retain the <trans-attribute>Required</trans-attribute> at the
    MDB.
    Have any answers?
    Pradip
    "Scott Yen" <[email protected]> wrote:
    >
    It's resolved.
    The MDB automatically created by JMS Event Generator defaults to be deployed
    with
    “transacted”. That requires the foreign JMS provider to be “XA”.
    The deployment descriptor is created as <domain-directory>/WLIJmsEG_<event_gen_name>.jar
    e.g. C:\bea812\user_projects\domains\jmsInterop\WLIJmsEG_mqQueueEventGen.jar
    Since MQ in the localhost and remote SLUDV18 are not XA-enabled, we had
    to manually
    change the <container-transaction> section in ejb-jar.xml:
    From :
    <trans-attribute>Required</trans-attribute>
    To:
    <trans-attribute>NotSupported</trans-attribute>
    "Scott Yen" <[email protected]> wrote:
    I'm getting following error in weblogic server log when starting a JMS
    Event generator
    to a foreign JMS(MQ5.3) Queue.
    <May 4, 2004 4:44:35 PM PDT> <Warning> <EJB> <BEA-010096> <The Message-Driven
    EJ
    B: mqQueueEventGen is unable to connect to the JMS destination: WAL1021852D_Test
    JMSQueue. Connection failed after 2 attempts. The MDB will attempt to
    reconnect
    every 10 seconds. This log message will repeat every 600 seconds until
    the condi
    tion clears.>
    <May 4, 2004 4:44:35 PM PDT> <Warning> <EJB> <BEA-010061> <The Message-Driven
    EJ
    B: mqQueueEventGen is unable to connect to the JMS destination: WAL1021852D_Test
    JMSQueue. The Error was:
    [EJB:010112]The Message Driven Bean 'mqQueueEventGen' is transacted,
    but the pro
    vider defined in the EJB is not transacted. Provider should be transacted
    if onM
    essage method in MDB is transacted.>
    My WLI8.1.2 is patched with CR131686_812.zip to support event generator
    for foreign
    JMS destinations. The foreign JMS/MQ provider is configured properly.
    QueueSend/Receive
    were tested fine with JMS java code using local JNDI names of foreign
    JMS objects.
    So we know that foreign Queue is active and accessiable from webLogic.
    Anyone run into this? Solution?
    Thanks,
    Scott

  • Deployment Tool Error - unknown document type - Add to Application EJB jar

    I am creating a new application in the J2EE deployment tool and adding an EJB JAR to it. The jar contains the ejb-jar.xml file. This file has the standard doctype:
    <!DOCTYPE ejb-jar PUBLIC
    '-//Sun Microsystems, INC.//DTD Enterprise JavaBeans 1.1//EN'
    'file:/C:/j2sdkee1.3/lib/dtds/ejb-jar_2_0.dtd'>
    I get the Unknown Document Type error when I try to add this jar to the application:
    Error: Adding EJB JAR - java.lang.RuntimeException: Invalid XML : Unknown document type : org.apache.crimson.tree.Doctype@e8647
    The xml file validates fine in NetBeans 3.4. I use NetBeans to generate the jar file.
    Any ideas as to what is happening would be appreciated.

    Try replacing the DTD definition as specified below.
    http://java.sun.com/dtd/ejb-jar_2_0.dtd
    regards,
    Siddique

  • Error compiling EJB.jar  + cannot resolve symbol+while deploying

    I am getting following
    Error compiling EJB.jar , cannot resolve symbol ,Syntax error in source, am getting around 17 errors while deploying EAR generated using Jdev905 into standalone oc4jContainers(10g).
    Can anyone please help me out where is the problem.
    Regards,
    Anup

    cannot resolve symbol ,Syntax error in source
    indicates some jar file is not in the Classpath. Is j2ee.jar in the Classpath?

  • Generating EJB Client jars

    Hi,
    i want to know wheather there is any way to generate client jars for any specified ejb's in oracle 10g. In weblogic using appc generates a client jar that contains all required classes for the ejb's including the Stub implementation classes.
    I need the client jar's in order to make it available to a war file which does a lookup of these beans.
    Any ant taks that oracle provides for this??

    You need to deploy the class files specific to your client as well as the generated stubs for the EJB.

  • Error deploying EJB.jar 40k via console.

    Hi,
    I have an ejb.jar thats over 40k, containing std_ejb.jar (non ejb-compiled jar) that I am trying to load into WLS6.1 via the console. I copied the file into <wls.home>/../applications dir and when I try to load this file via the console, the console tries to load the file to generate the stubs and skeletons. The process to upload fails after a about 10 secs with a "Read timed out" error and I can see the file I copied to the apps dir, which was originally 45k is now 40k.. Please note that I have an eval version of WLS6.1. Dont know if that impacts uploads ?
    thanx
    -Ram

    Hi,
    I have an ejb.jar thats over 40k, containing std_ejb.jar (non ejb-compiled jar) that I am trying to load into WLS6.1 via the console. I copied the file into <wls.home>/../applications dir and when I try to load this file via the console, the console tries to load the file to generate the stubs and skeletons. The process to upload fails after a about 10 secs with a "Read timed out" error and I can see the file I copied to the apps dir, which was originally 45k is now 40k.. Please note that I have an eval version of WLS6.1. Dont know if that impacts uploads ?
    thanx
    -Ram

  • Using JarSettings to generate EJB client jar, but supported classes missed

    Appreciated for any comments in advance.
    I am using @jarSetting to generate EJB client jar file from workshop 9.2. The remote method of EJB has one input parameter that is defined as an interface. The interface is included in client jar, but the implementation of this interface is not.
    Please advise how I can add the implementation of this interface to client jar?
    Best Regards,
    James

    Hi James,
    I believe the algorithm for creating the client jar is to simply inspect the EJB interfaces using reflection and to include all user defined classes and exceptions that are referenced by the interfaces. In your case, it sounds like a class is not being included because it is not directly referenced by one of the EJB interfaces.
    I think the client jar creation algorithm can be described as "best effort" and unfortunately, it does not always end up including all classes needed by the client. I would recommend you add the additional classes manually using the jar tool.
    - Matt

  • Error while migrating orion-ejb-jar.xml from OC4J 9.0.4.1

    I am trying to use Toplink migration tool to take our existing orion-ejb-jar.xml file and toplink-ejb-jar.xml file to new 10.1.3 deployment. While running the migration tool I get the following error
    WARNING: Oc4j native CMP setting optimistic-locking on
    entity(TransactionTypeEntityBean) is not migrated and supported.
    java.lang.IllegalArgumentException: MWDatabaseField[9BE2B5]
    (TAX_RULE.TAX_RULE_ID)
    at
    oracle.toplink.workbench.mappingsmodel.desc.relational.MWRelationalPrima
    ryKeyPolicy.addPrimaryKey(MWRelationalPrimaryKeyPolicy.java:99)
    at
    oracle.toplink.tools.migration.RuntimeCMPProjectToMWProjectConverter.con
    vertDescriptor(RuntimeCMPProjectToMWProjectConverter.java:297)
    at
    oracle.toplink.tools.migration.RuntimeCMPProjectToMWProjectConverter.con
    vertDescriptors(RuntimeCMPProjectToMWProjectConverter.java:265)
    at
    oracle.toplink.tools.migration.RuntimeCMPProjectToMWProjectConverter.con
    vertProject(RuntimeCMPProjectToMWProjectConverter.java:144)
    at
    oracle.toplink.tools.migration.MigrationManagerBase.convertAndWriteoutMW
    Project(MigrationManagerBase.java:369)
    at
    oracle.toplink.tools.migration.MigrationManagerBase.migrate(MigrationMan
    agerBase.java:358)
    at
    oracle.toplink.tools.migration.io.MigrationIOManager.buildMigratedJarFil
    e(MigrationIOManager.java:243)
    at
    oracle.toplink.tools.migration.io.MigrationIOManager.operateEarEntry(Mig
    rationIOManager.java:181)
    at
    oracle.toplink.tools.migration.io.MigrationIOManager.operateEar(Migratio
    nIOManager.java:145)
    at
    oracle.toplink.tools.migration.io.MigrationIOManager.operateIO(Migration
    IOManager.java:88)
    at
    oracle.toplink.tools.migration.MigrationManagerBase.startMigration(Migra
    tionManagerBase.java:280)
    at
    oracle.toplink.tools.migration.MigrationManagerBase.run(MigrationManager
    Base.java:121)
    at
    oracle.toplink.tools.migration.MigrationManagerBase.run(MigrationManager
    Base.java:97)
    at
    oracle.toplink.tools.migration.TopLinkCMPMigrator.main(TopLinkCMPMigrato
    r.java:59)

    Hello,
    The warning message looks to be unrelated to the java.lang.IllegalArgumentException error. The warning states that optimistic locking cannot be migrated to the toplink-ejb-jar.xml file; this is stated in chapter 7 of the TopLink developer's guide at
    http://download-west.oracle.com/otn_hosted_doc/toplink/1013/MAIN/_pdf/b13593_v1_01.pdf
    The exception though seems to indicate that your orion-ejb-jar.xml contains EJBs mapped to the same table that are not related through EJB inheritance. I do it all the time with POJOs so this will work in TopLink, but you will need a support case to help get your project migrated if this is the case.
    Best Regards,
    Chris Delahunt

  • Weblogic 10.3.0 Deployment error when using ejb-jar.xml

    Hi,
    I am getting the following error while deploying my EJB3 application on Weblogic 10.3.0. This is happening only if I include ejb-jar.xml.
    As per the EJB3 descriptor spec, Remote Home or Local home are not exists.
    Is this a issue in Weblogic 10.3.0 or am I missing any special setup ?
    Please help.
    weblogic.application.ModuleException: Exception preparing module: EJBModule(egm-poc.jar)
    Unable to deploy EJB: C:\appsrv\domains\WeblogicRS1.1-domain\servers\admin\tmp\_WL_user\_appsdir_egmear_ear\ot2591\egm-poc.
    jar from egm-poc.jar:
    In EJB JPATestBean, both the remote home and remote component interface must be specified. Currently, only one of them is spec
    ified.
    at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:452)
    at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93)
    at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:387)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
    at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:58)
    My ejb-jar.xml is
    - <ejb-jar version="3.0" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd">
    <description>JPA Test Application</description>
    <display-name>JPATest</display-name>
    - <enterprise-beans>
    - <session>
    <ejb-name>JPATestBean</ejb-name>
    <remote>egm.poc.jpa.JPATestBeanRemote</remote>
    <local>egm.poc.jpa.JPATestBeanLocal</local>
    <ejb-class>egm.poc.jpa.JPATestBean</ejb-class>
    <session-type>Stateless</session-type>
    <transaction-type>Container</transaction-type>
    </session>
    - <session>
    <ejb-name>AuditInfoDAOH</ejb-name>
    <local>egm.poc.jpa.Audit</local>
    <ejb-class>egm.poc.jpa.AuditInfoDAOH</ejb-class>
    <session-type>Stateless</session-type>
    <transaction-type>Container</transaction-type>
    </session>
    </enterprise-beans>
    - <assembly-descriptor>
    - <container-transaction>
    - <method>
    <ejb-name>JPATestBean</ejb-name>
    <method-name>*</method-name>
    </method>
    <trans-attribute>RequiresNew</trans-attribute>
    </container-transaction>
    - <container-transaction>
    - <method>
    <ejb-name>AuditInfoDAOH</ejb-name>
    <method-name>*</method-name>
    </method>
    <trans-attribute>Required</trans-attribute>
    </container-transaction>
    </assembly-descriptor>
    </ejb-jar>
    Regards
    Saji

    Hi,
    Seems the issue is not common. Can anyone throw some light on this ?
    Regards
    Saji

  • Error in starting Websphere: during loading of EJB jar

    Hi,
    i am using Websphere. When i restart server and one EJB jar gets deployed. following error comes
    java.lang.NoClassDefFoundError: org/omg/CORBA/por4able/InputStream
    at java.lang.Class.getDeclaredConstructors0(Native Method)
    Can any one have any pointers
    In case of more details. Please let me know ASAP.
    Thanks
    ~Aman

    Hi,
    This is an issue related to classpath. Make sure that all the jars required are placed in your classpath, specially j2ee.jar, bootstrap.jar and so on I don't remember the names.
    HTH
    VJ

  • Ejb-jar.xml DTD validation error?

    I am attempting to deploy a JAR on App Server 8 PE. The application does not contain any EJBs but I understand that the ejb-jar.xml descriptor is still needed. I am running the app server on Windows XP.
    My issue is as follows:
    I understand that the root element for the ejb-jar.xml file (<ejb-jar>) is required. Since I have no EJBs, I should be able to leave this root element blank (as I have in previoius successful deployments to earlier versions of Sun App Server). When I attempt to deploy, I receive the following DTD Validation error via the admin console:
    The content of element type "ejb-jar" is incomplete, it must match "(description?,display-name?,small-icon?,large-icon?,enterprise-beans,relationships?,assembly-descriptor?,ejb-client-jar?)".
    Am I missing something?
    My ejb-jar.xml file looks like:
    <!DOCTYPE ejb-jar PUBLIC
         "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN"
         "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
    <ejb-jar>
    </ejb-jar>
    Many thanks in advance to any assistance...

    I am attempting to deploy a JAR on App Server 8 PE.
    The application does not contain any EJBs but I
    I understand that the ejb-jar.xml descriptor is still
    needed. I am running the app server on Windows XP.
    My issue is as follows:
    I understand that the root element for the
    ejb-jar.xml file (<ejb-jar>) is required. Since I
    have no EJBs, I should be able to leave this root
    element blank (as I have in previoius successful
    deployments to earlier versions of Sun App Server).
    When I attempt to deploy, I receive the following
    g DTD Validation error via the admin console:
    The content of element type "ejb-jar" is incomplete,
    it must match
    "(description?,display-name?,small-icon?,large-icon?,e
    nterprise-beans,relationships?,assembly-descriptor?,ej
    b-client-jar?)".
    Am I missing something?
    My ejb-jar.xml file looks like:
    <!DOCTYPE ejb-jar PUBLIC
    "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans
    s 2.0//EN"
         "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
    <ejb-jar>
    </ejb-jar>
    Many thanks in advance to any assistance...I hav tried this and it is working
    <?xml version="1.0" encoding="UTF-8" ?>
    <ejb-jar
    xmlns="http://java.sun.com/xml/ns/j2ee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
    http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd"
    version="2.1">

Maybe you are looking for