I think you have the tag name reversed:
>> *  jndi-local-name="UserLocalHome"
should be
* local-jndi-name="UserLocalHome"

-Joe

>>> "Eric Jablow" <[EMAIL PROTECTED]> 12/09/02 07:52PM >>>
I am having a strange problem using XDoclet 1.2-beta1.

I have a session bean, LogonBean:

/**
 * A session bean that determines whether a user may log onto the
(censored)
 * system.
 * Its {@link #validate(String, String)} method returns a value object
for the
 * user giving her privileges.
 * If the user does not exist, it throws an exception.
 *
 * @see com.praxiseng.(censored).exception.InvalidLogonException
 *
 * @ejb.bean type="Stateless"
 *           name="Logon"
 *             jndi-name="LogonHome"
 *           transaction-type="Container"
 *
 * @ejb.ref view-type="local"
 *          ejb-name="User"
 *          
 * @ejb.transaction type="Required"
 *
 * @weblogic.ejb-local-reference-description
ejb-ref-name="ejb/UserLocalHome"
 *                                           jndi-name="UserLocalHome"
 */

 public abstract class LogonBean implements javax.ejb.SessionBean {
   // ...
 }
 
I get this in the generated ejb-jar.xml file:

      <session >
         <description><![CDATA[A session bean that determines whether a
user may log onto the (censored) system.]]></description>

         <ejb-name>Logon</ejb-name>

         <home>com.praxiseng.poconnect.interfaces.LogonHome</home>
         <remote>com.praxiseng.poconnect.interfaces.Logon</remote>
 
<local-home>com.praxiseng.poconnect.interfaces.LogonLocalHome</local-hom
e>
         <local>com.praxiseng.poconnect.interfaces.LogonLocal</local>
         <ejb-class>com.praxiseng.poconnect.ejb.LogonSession</ejb-class>
         <session-type>Stateless</session-type>
         <transaction-type>Container</transaction-type>

      </session>

No <ejb-local-ref> section at all.

Furthermore, the weblogic-ejb-jar.xml file provides me with:

   <weblogic-enterprise-bean>
      <ejb-name>Logon</ejb-name>
      <stateless-session-descriptor>
      </stateless-session-descriptor>
      <reference-descriptor>
         <ejb-local-reference-description>
            <ejb-ref-name>ejb/UserLocalHome</ejb-ref-name>
            <jndi-name>UserLocalHome</jndi-name>
         </ejb-local-reference-description>
      </reference-descriptor>
      <jndi-name>LogonHome</jndi-name>
      <local-jndi-name>LogonLocal</local-jndi-name>
   </weblogic-enterprise-bean>

I didn't expect a LogonLocal entry here, but that's all right.
However, it does the same thing with an entity bean:

/**
 * A user, and her password.
 *
 * @ejb.bean
 *  type="CMP"
 *  cmp-version="2.x"
 *  name="User"
 *  jndi-name="UserHome"
 *  jndi-local-name="UserLocalHome"
 *  view-type="both"
 *  primkey-field="id"
 *
 *  @ejb:value-object name="User" match="*" instantiation="eager"
 *
 * @ejb.ref view-type="local" 
 *          ejb-name="Role"
 *
 *  @weblogic.table-name T_USER
 *  @weblogic.data-source-name (censored).database
 *
 * @weblogic.ejb-local-reference-description
ejb-ref-name="ejb/RoleLocalHome"
 *                                           jndi-name="RoleLocalHome"
 *
 * @author Eric Jablow
 */

 public abstract class UserBean implements javax.ejb.EntityBean {
 // ...
 }

and I get no <ejb-local-ref> in my ejb-jar.xml file, and I get this in
my weblogic-ejb-jar.xml file:

   <weblogic-enterprise-bean>
      <ejb-name>User</ejb-name>
      <entity-descriptor>
         <persistence>
            <persistence-type>
               <type-identifier>WebLogic_CMP_RDBMS</type-identifier>
               <type-version>6.0</type-version>
 
<type-storage>META-INF/weblogic-cmp-rdbms-jar.xml</type-storage>
            </persistence-type>
            <persistence-use>
               <type-identifier>WebLogic_CMP_RDBMS</type-identifier>
               <type-version>6.0</type-version>
            </persistence-use>
         </persistence>
      </entity-descriptor>
      <reference-descriptor>
         <ejb-local-reference-description>
            <ejb-ref-name>ejb/RoleLocalHome</ejb-ref-name>
            <jndi-name>RoleLocalHome</jndi-name>
         </ejb-local-reference-description>
      </reference-descriptor>
      <jndi-name>UserHome</jndi-name>
      <local-jndi-name>UserLocal</local-jndi-name>
   </weblogic-enterprise-bean>

Why did it not use the jndi names I expected?  Did I leave any tags out?
The UserHome.java file has the declarations

   public static final String COMP_NAME="java:comp/env/ejb/User";
   public static final String JNDI_NAME="UserHome";

But the UserLocalHome.java has:

   public static final String COMP_NAME="java:comp/env/ejb/UserLocal";
   public static final String JNDI_NAME="UserLocal";

Not UserLocalHome?

Please help; I'm at my wits' end, and my wits are pretty small as it is.
----
Respectfully,
Eric Jablow
Praxis Engineering Technologies, Inc.
301-490-4299 x. 131.






-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf 
_______________________________________________
Xdoclet-user mailing list
[EMAIL PROTECTED] 
https://lists.sourceforge.net/lists/listinfo/xdoclet-user


-------------------------------------------------------
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
_______________________________________________
Xdoclet-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-user

Reply via email to