Skip to Content
author's profile photo Former Member
Former Member

JNDI name

Im trying to deploy an EAR onto SAP Web AS. It has an ejb.jar file with ejb-jar.xml and the ejb-j2ee-engine.xml. ive given my beans their JNDI names in the ejb-j2ee-engine.xml file.

But when i deploy it, it comes back with SAP's default JNDI names instead of the ones ive given there. Can someone please tell me if we can supply our own JNDI names and if there is a work around for this.I use ant to build by EAR file. Any help would be greatly appreciated.

thanks

-RD

Add a comment
10|10000 characters needed characters exceeded

Related questions

3 Answers

  • Best Answer
    Posted on Feb 11, 2005 at 09:17 PM

    Hi RD,

    this should be no problem. Here is an extract of one of my jeb-j2ee-engine.xml's generated by SAP Dev. Studio.

    <ejb-j2ee-engine>
      <enterprise-beans>
        <enterprise-bean>
          <ejb-name>BeanName</ejb-name>
          <jndi-name>MyBean</jndi-name>
          ...
          <session-props/>
        </enterprise-bean>
      </enterprise-beans>
    <ejb-j2ee-engine>
    

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Feb 14, 2005 at 06:28 AM

    Hi RD,

    to add a new jndi name for your bean class open the ejb-j2ee-engine.xml, click on the 'Enterprise Beans tab. Click on your bean name, it should be listed under session or entity or message dirven bean node as per the bean type. You will get a field to enter the JNDI name corresponding to the bean you have selected. Enter the jndi name, save it, you will get the required entry in the xml file. The resultant xml file will look like this...

    <enterprise-beans>

    <enterprise-bean>

    <ejb-name>MyTestSessionBean</ejb-name>

    <jndi-name>myTestSession</jndi-name>

    <session-props/>

    </enterprise-bean>

    </enterprise-beans>

    hope it helps...

    shubhadip

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Feb 14, 2005 at 11:40 AM

    Hi RD,

    As Helmut already wrote this shouldn't be a problem. Can you paste the parts of ejb-jar.xml and ejb-j2ee-engine.xml relevant to your EJB? Also the path where you find it in the JNDI tree.

    Best regards,

    Vladimir

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.