NameNotFoundException on lookup

I see a bunch of questions in this area, but not a solution.
I have an applet that tries to instantiate a stateless session bean to talk back
to the server.
I have an ear deployment that contains a bean (jar) & a application (war). The
bean has a jndi entry (that I can see in the admin console, I can test the ejb
in the admin console as well), but when the applet (that is in the war), does
a lookup, it gets a NameNotFoundException.
ejb-jar.xml:
<!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>
<enterprise-beans>
<session>
<ejb-name>TADGenerateMapService</ejb-name>
<home>TAD.ejbs.TADGenerateMapEJBHome</home>
<remote>TAD.ejbs.TADGenerateMapEJBRemote</remote>
<ejb-class>TAD.ejbs.TADGenerateMapEJB</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
</enterprise-beans>
</ejb-jar>
Weblogic-ejb-jar.xml:
<?xml version="1.0"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC
'-//BEA Systems, Inc.//DTD WebLogic 8.1.0 EJB//EN'
'http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd'>
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>TADGenerateMapService</ejb-name>
<jndi-name>TAD.map.statelessSession</jndi-name>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
web.xml contains
<ejb-ref>
<ejb-ref-name>TADGenerateMapService</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<home>TAD.ejbs.TADGenerateMapEJBHome</home>
<remote>TAD.ejbs.TADGenerateMapEJBRemote</remote>
<ejb-link>TAD_EJB.jar#TADGenerateMapService</ejb-link>
</ejb-ref>
Lookup snippet:
String hostName = this.getCodeBase().getHost();
Hashtable env = new Hashtable();
env.put(Context.PROVIDER_URL, "t3://" + hostName + ":7001");
env.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory");
try {
context = new InitialContext(env);
catch( Exception e ) {
System.out.println("Caught exception " + e.toString() + " in init");
try
// Get Initial JNDI Context
// Get EJB
TADGenerateMapEJBHome mapHome = (TADGenerateMapEJBHome) context.lookup
("TAD.map.statelessSession");
TADGenerateMapEJBRemote mapRemote = mapHome.create () ;
mapNameWithPath = mapRemote.generateMap (mapProjection,
mapType,
mapWidth,
mapCenterLat,
mapCenterLon);
catch (NamingException e)
System.out.println ("TADMapClient.generateMap - NamingException => " +
e) ;
e.printStackTrace();
Error I receive in the browser java console:
TADMapClient.generateMap - NamingException => javax.naming.NameNotFoundException:
remaining name: java:/comp/env/TAD.map.statelessSession
javax.naming.NameNotFoundException: remaining name: java:/comp/env/TAD.map.statelessSession
     at weblogic.j2eeclient.SimpleContext.resolve(SimpleContext.java:35)
     at weblogic.j2eeclient.SimpleContext.resolve(SimpleContext.java:39)
     at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:57)
     at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:62)
     at javax.naming.InitialContext.lookup(Unknown Source)
     at TAD.common.TestApp.generateMap(TestApp.java:67)
     at TAD.common.TestApp.start(TestApp.java:45)
     at sun.applet.AppletPanel.run(Unknown Source)
     at java.lang.Thread.run(Unknown Source)
I think I am missing a piece.
Thanks

Yes. it is in the JNDI tree.
"eran" <[email protected]> wrote:
>
Does the bean's JNDI name appears in the server JNDI tree?
"James Martin" <[email protected]> wrote:
I do have a remote and home interface. Can't use an intermediate servlet
for this.
"eran" <[email protected]> wrote:
Hi,
If you use the EJB from your applet you must make the home and remote
interfaces
avavilable for your applet.
Wouldn't it be easier to use an intermediate servlet.
Eran
"James Martin" <[email protected]> wrote:
I see a bunch of questions in this area, but not a solution.
I have an applet that tries to instantiate a stateless session beanto
talk back
to the server.
I have an ear deployment that contains a bean (jar) & a application(war).
The
bean has a jndi entry (that I can see in the admin console, I can
test
the ejb
in the admin console as well), but when the applet (that is in thewar),
does
a lookup, it gets a NameNotFoundException.
ejb-jar.xml:
<!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD EnterpriseJavaBeans
2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
<ejb-jar>
<enterprise-beans>
<session>
<ejb-name>TADGenerateMapService</ejb-name>
<home>TAD.ejbs.TADGenerateMapEJBHome</home>
<remote>TAD.ejbs.TADGenerateMapEJBRemote</remote>
<ejb-class>TAD.ejbs.TADGenerateMapEJB</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
</enterprise-beans>
</ejb-jar>
Weblogic-ejb-jar.xml:
<?xml version="1.0"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC
'-//BEA Systems, Inc.//DTD WebLogic 8.1.0 EJB//EN'
'http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd'>
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>TADGenerateMapService</ejb-name>
<jndi-name>TAD.map.statelessSession</jndi-name>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
web.xml contains
<ejb-ref>
<ejb-ref-name>TADGenerateMapService</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<home>TAD.ejbs.TADGenerateMapEJBHome</home>
<remote>TAD.ejbs.TADGenerateMapEJBRemote</remote>
<ejb-link>TAD_EJB.jar#TADGenerateMapService</ejb-link>
</ejb-ref>
Lookup snippet:
String hostName = this.getCodeBase().getHost();
Hashtable env = new Hashtable();
env.put(Context.PROVIDER_URL, "t3://" + hostName + ":7001");
env.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory");
try {
context = new InitialContext(env);
catch( Exception e ) {
System.out.println("Caught exception " + e.toString() + " in
init");
try
// Get Initial JNDI Context
// Get EJB
TADGenerateMapEJBHome mapHome = (TADGenerateMapEJBHome)context.lookup
("TAD.map.statelessSession");
TADGenerateMapEJBRemote mapRemote = mapHome.create () ;
mapNameWithPath = mapRemote.generateMap (mapProjection,
mapType,
mapWidth,
mapCenterLat,
mapCenterLon);
catch (NamingException e)
System.out.println ("TADMapClient.generateMap - NamingException
=> " +
e) ;
e.printStackTrace();
Error I receive in the browser java console:
TADMapClient.generateMap - NamingException => javax.naming.NameNotFoundException:
remaining name: java:/comp/env/TAD.map.statelessSession
javax.naming.NameNotFoundException: remaining name: java:/comp/env/TAD.map.statelessSession
     at weblogic.j2eeclient.SimpleContext.resolve(SimpleContext.java:35)
     at weblogic.j2eeclient.SimpleContext.resolve(SimpleContext.java:39)
     at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:57)
     at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:62)
     at javax.naming.InitialContext.lookup(Unknown Source)
     at TAD.common.TestApp.generateMap(TestApp.java:67)
     at TAD.common.TestApp.start(TestApp.java:45)
     at sun.applet.AppletPanel.run(Unknown Source)
     at java.lang.Thread.run(Unknown Source)
I think I am missing a piece.
Thanks

Similar Messages

  • NameNotFoundException on lookup in JSP

    I'm new to EJBs. I got an extremely basic stateless session bean to work on a JSP,
    now I'm trying to get an entity bean working.
    I'm getting a javax.naming.NameNotFoundException on my lookup. Here's my JSP code:
    Hashtable ht = new Hashtable();
    ht.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory");
    ht.put(Context.PROVIDER_URL, "t3://localhost" );
    Context ctx = new InitialContext( ht );
    WBaseUserLocalHome userLocalHome = (VWBaseUserLocalHome) ctx.lookup("VWBaseUser");
    (yes, I've changes my weblogic port from the default port 7001 to 80)
    I thought that the string that you perform the lookup on is supposed to match
    the <jndi-name> in the weblogic-ejb-jar.xml, and it is.

    Inline.
    Brian Preston wrote:
    Excellent explanation, thanks. I think I followed most of it. Your explanation
    also seems to describe my problem - I'm trying to deploy this test EJB as an 'exploded'
    application, but I've only built the EJB with local interfaces. I previously
    thought that since the JSP and EJB were running on the same server, the calls
    would be local, not remote. I didn't know about the classloader issues.
    So if I want to stick with the exploded app, I need to use Remote Interfaces then?Not necessarily. You could deploy the JSP in an exploded WAR format in the same exploded EAR
    that contains the exploded JAR for the EJB. This deploys the JSP and the EJB in the same
    classloader hierarchy allowing by reference semantics, therefore supporting the call to a Local
    Interface fromt the JSP. Or, yes, you could just change the Local Interfaces to Remote
    Interfaces. Really depends on the app, other apps, how you are using it, etc.
    Bill
    >
    I'll go ahead and try both that, and packaging everything into a WAR and EAR.
    I haven't tried that yet because I'm still trying to find explanation/documentation
    about how to create those and what the directory structure is supposed to be before
    you jar it.
    Thanks,
    Brian
    William Kemp <[email protected]> wrote:
    The EJB 2.0 Spec defines EJB Local Interfaces. The object that implements
    these is not a
    java.rmi.Remote object, and therefore may only be passed by reference.
    When you refer to
    them, you must be in the same JVM, and in the same enterprise app, on
    WebLogic. They are
    available and looked up through the local JNDI tree, which is common,
    or local, to all of
    the components in a J2EE app. An object reference may be returned when
    looked up through the
    local JNDI tree because the accessor and the object have been loaded
    by the same classloader
    hierarchy. You may not look them up and use them from outside of the
    app because that
    implies pass by value, which requires a java.rmi.Remote object.
    So, if you access an EJB Local Interface, you must do it from the same
    JVM and the same
    enterprise application. As for examples, WLS is shipped with several
    EJB 2.0 CMP examples
    that demonstrate the use of Local Interfaces. In your example, you need
    to package the JSP
    and the EJB Local Inteface in the same EAR. Here are some good links
    for this:
    http://edocs.bea.com/wls/docs70/programming/index.html
    http://edocs.bea.com/wls/docs70/programming/classloading.html#1029830
    http://edocs.bea.com/wls/docs70/ejb/cmp.html#1070133
    Bill
    Brian Preston wrote:
    Could you explain this a little more? I'm not following you when yousay 'access
    to the local interfaces is scoped at the application level.' Somecode samples
    would probably help, too. I'm pretty new to JNDI and RMI. I'm tryingto understand
    these underlying APIs behind EJBs.
    Thanks,
    Brian
    William Kemp <[email protected]> wrote:
    The app can be exploded. The requirement is that access to the local
    interfaces is scoped
    at the application level.
    Bill
    Brian Preston wrote:
    Thanks for your reply. Does that mean there's no way to do this
    with
    an 'exploded'
    applicationk? I.e., without using an ear file?
    William Kemp <[email protected]> wrote:
    Looks like you are trying to look up a local interface in the global
    jndi tree. Local
    interfaces are only available in the local jndi tree. The JSP and
    the
    entity bean,
    with the local interface you are trying to lookup, must be in thesame
    J2EE
    application which means they must be in the same application ear
    file.
    Bill
    Brian Preston wrote:
    I'm new to EJBs. I got an extremely basic stateless session bean
    to
    work on a JSP,
    now I'm trying to get an entity bean working.
    I'm getting a javax.naming.NameNotFoundException on my lookup.
    Here's
    my JSP code:
    Hashtable ht = new Hashtable();
    ht.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory");
    ht.put(Context.PROVIDER_URL, "t3://localhost" );
    Context ctx = new InitialContext( ht );
    WBaseUserLocalHome userLocalHome = (VWBaseUserLocalHome) ctx.lookup("VWBaseUser");
    (yes, I've changes my weblogic port from the default port 7001
    to
    80)
    I thought that the string that you perform the lookup on is supposedto match
    the <jndi-name> in the weblogic-ejb-jar.xml, and it is.

  • ERROR:NameNotFoundException: Object not found in lookup of MYDB

    NW 7.0 SP3
    I have defined a datasource MYDB by VA,and it tests OK.
    I wonder about how to use it in J2EE project or in WebDynpro Project.
    I created a J2EE project ,in the Web Model ,i new a class Test:
    public static Connection myconn(){    
         Context ctx = new InitialContext();
         Connection conn = null;
         DataSource dataSource = null;
         dataSource = (DataSource) ctx.lookup("MYDB");
        conn = dataSource.getConnection();
        return conn;
    then in webcontent ,I new a JSP page:
    <%
      Connection conn = com.Test.myconn();
    java.sql.Statement st = conn.createStatement();
    String str = "select * from TMP_NAME";
    ResultSet rs = st.executeQuery(str);
    rs.next();
    String str1 = rs.getString(1);
    %>
    after build and deploy the *.ear,the server returns an error:
             com.sap.engine.services.jndi.persistent.exceptions.NameNotFoundException: Object not found in lookup of MYDB.
    Now I do not know anything else should I do,such as create a reference,and so on.
    Thanks for you all help!

    Hi,
    Try the code as below:
    DataSource ds = (DataSource) context.lookup("java:comp/env/jdbc/MYDB")
    Go through the below help link:
    http://help.sap.com/saphelp_nw2004s/helpdata/en/82/fdbf2085f65f43a71e755fc904478d/content.htm
    Go through the below thread for more info:
    Re: datasource using VA
    Regards,
    Charan

  • NameNotFoundException: Object not found in lookup of FilenameModuleBean

    Hello,
    after migration from XI 3.0 to PI 7.10 we have a problem with a Java-Module in the File-Adapter.
    In XI 3.0 we hat only a EAR-File. We converted it into a SCA-File an deploy it with the JSPM.
    I also can see the Objekt in the JNDI-Browser under:
    localejbs/sap.com/fnmodear/FilenameModuleBean
    rfcaccessejb/sap.com/fnmodear/FilenameModuleBean
    sap.com/fnmodear/FilenameModuleBean
    ejbCosNaming/sap.com/fnmodear/FilenameModuleBean
    but not under:
    AF_Modules/ (I don´t know if it matters)
    In the File-Adapter we try FilenameModuleBean in the Module Name, but we get the following error message:
    18.11.2010 17:02:59 Fehler Adapter Framework caught exception: Object not found in lookup of FilenameModuleBean.
    18.11.2010 17:02:59 Fehler Delivering the message to the application using connection File_http://sap.com/xi/XI/System failed, due to: com.sap.engine.interfaces.messaging.api.exception.MessagingException: com.sap.engine.services.jndi.persistent.exceptions.NameNotFoundException: Object not found in lookup of FilenameModuleBean..
    It seems that he can´t look up the JNDI name.
    I hope anyone can help me with the problem.
    Best Regards
    Georg
    Edited by: Georg Kunkel on Nov 18, 2010 5:21 PM

    Hi Georg,
    I believe the java module "FilenameModuleBean" in your case is a custom adapter module and hence it would not be available under AF_Modules. The AF_Module is for the modules which are shipped with PI by SAP like PayloadSwapBean, XMLConvertorBean etc.
    As a checklist, please check the following entries in the module tab of the channel configuration:
    1. Module Name: FilenameModuleBean
    2. Type: Local Enterprise Bean
    3. Module Key: Any Constant Value
    4. Module parameters for this module key (Necessary only if the custom module expects any inputs)
    Also as you mentioned,
    >>In XI 3.0 we hat only a EAR-File. We converted it into a SCA-File an deploy it with the JSPM.
    For this, there might be a case that the .SCA file was not generated properly. To properly generate the .SCA or .SDA file you can:
    1. Build sca from ear using nwpacktool described in SAP note:1223957
    2. Use NWDS 7.1. You can convert your EAR file to SDA file with the help of CECTL & nwcetool provided with NWDS 7.1
    Check: Re: How to build an adapter module in NWDS 7.1?
    You might also want to look at the following link for creating custom adapter module for PI 7.10
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/c0b39e65-981e-2b10-1c9c-fc3f8e6747fa?quicklink=index&overridelayout=true
    In case everything looks fine to you, a manual re-start (if possible) of the PI Server should solve the problem.
    I hope this helps.
    Regards, Gaurav.

  • NameNotFoundException: Object not found in lookup

    Hi all!
    I have a problem with my Netweaver SP18 WebAS EJB application. The JNDI lookup fails with the following runtime error:
    com.sap.engine.services.jndi.persistent.exceptions.NameNotFoundException: Object not found in lookup of CaTreeServerIFBean.
         at com.sap.engine.services.jndi.implserver.ServerContextImpl.lookup(ServerContextImpl.java:649)
         at com.sap.engine.services.jndi.implserver.ServerContextRedirectableImpl.lookup(ServerContextRedirectableImpl.java:80)
         at com.sap.engine.services.jndi.implserver.ServerContextImplp4_Skel.dispatch(ServerContextImplp4_Skel.java:555)
         at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:320)
         at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:198)
         at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4SessionProcessor.java:129)
         at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
         at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    predecessor system -
    com.sap.engine.services.jndi.persistent.exceptions.NameNotFoundException: Object not found in lookup of CaTreeServerIFBean.
         at com.sap.engine.services.jndi.implserver.ServerContextImpl.lookup(ServerContextImpl.java:649)
         at com.sap.engine.services.jndi.implserver.ServerContextRedirectableImpl.lookup(ServerContextRedirectableImpl.java:80)
         at com.sap.engine.services.jndi.implserver.ServerContextImplp4_Skel.dispatch(ServerContextImplp4_Skel.java:555)
         at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:320)
         at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:198)
         at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4SessionProcessor.java:129)
         at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
         at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    I use the following code to lookup the EJB:
    Object homeTreeObj = ctx.lookup("sap.com/anafee-server-ear/CaTreeServerIFBean");
    I think the JNDI name should be right, because it's a composite name
    of "provider-name/application-name/EJB-name".
    My provider-name is defined in the application-j2ee-engine.xml:
    <application-j2ee-engine>
        <provider-name>sap.com</provider-name>
        <fail-over-enable mode="disable" />
    </application-j2ee-engine>
    My application-name is defined in the application.xml:
    <application>
        <display-name>anafee-server-ear</display-name>
        <description>EAR description</description>
        <module>
            <ejb>anafee-server-ejb-3_2.jar</ejb>
        </module>
    </application>
    My Session EJB is declared in the ejb-jar.xml:
    <session>
                <description>test</description>
                <ejb-name>CaTreeServerIFBean</ejb-name>
    <home>com.catenic.anafee.server.common.serverinterface.CaTreeServerIFHome</home>
    <remote>com.catenic.anafee.server.common.serverinterface.CaTreeServerIF</remote>
                <ejb-class>com.catenic.anafee.server.common.serverinterface.CaTreeServerIFBean</ejb-class>
                <session-type>Stateless</session-type>
                <transaction-type>Container</transaction-type>
                <ejb-ref>
                    <ejb-ref-name>ejb/CaFastReaderManager</ejb-ref-name>
                    <ejb-ref-type>Session</ejb-ref-type>
    <home>com.catenic.anafee.server.manager.reader.CaFastReaderManagerHome</home>
    <remote>com.catenic.anafee.server.manager.reader.CaFastReaderManager</remote>
                    <ejb-link>CaFastReaderManagerBean</ejb-link>
                </ejb-ref>
                <ejb-ref>
                    <ejb-ref-name>ejb/CaTreeManager</ejb-ref-name>
                    <ejb-ref-type>Session</ejb-ref-type>        <home>com.catenic.anafee.server.manager.tree.CaTreeManagerHome</home>
    <remote>com.catenic.anafee.server.manager.tree.CaTreeManager</remote>
                    <ejb-link>CaTreeManagerBean</ejb-link>
                </ejb-ref>
                <ejb-ref>
                    <ejb-ref-name>ejb/CaTNBasicManager</ejb-ref-name>
                    <ejb-ref-type>Session</ejb-ref-type>
    <home>com.catenic.anafee.server.manager.tree.CaTNManagerHome</home>      <remote>com.catenic.anafee.server.manager.tree.CaTNBasicManager</remote>
                    <ejb-link>CaTNBasicManagerBean</ejb-link>
                </ejb-ref>
                <ejb-ref>
                    <ejb-ref-name>ejb/CaTreeRole2IFMappingService</ejb-ref-name>
                    <ejb-ref-type>Session</ejb-ref-type>
                    <home>com.catenic.anafee.server.manager.rolemapping.tree.CaTreeRole2IFMappingServiceHome</home>
    <remote>com.catenic.anafee.server.manager.rolemapping.tree.CaTreeRole2IFMappingService</remote>
                    <ejb-link>CaTreeRole2IFMappingServiceBean</ejb-link>
                </ejb-ref>
                <ejb-ref>
                    <ejb-ref-name>ejb/CaRoleInfoManager</ejb-ref-name>
                    <ejb-ref-type>Session</ejb-ref-type>
    <home>com.catenic.anafee.server.metadata.CaRoleInfoManagerHome</home>
    <remote>com.catenic.anafee.server.metadata.CaRoleInfoManager</remote>
                    <ejb-link>CaRoleInfoManagerBean</ejb-link>
                </ejb-ref>
                <ejb-ref>
                    <ejb-ref-name>ejb/CaNestedTreeManager</ejb-ref-name>
                    <ejb-ref-type>Session</ejb-ref-type>
    <home>com.catenic.anafee.server.manager.tree.CaNestedTreeManagerHome</home>
    <remote>com.catenic.anafee.server.manager.tree.CaNestedTreeManager</remote>
                    <ejb-link>CaNestedTreeManagerBean</ejb-link>
                </ejb-ref>
            </session>
    Do you have any idea why the lookup fails? (I don't have any special JNDI mappings
    defined in the ejb-j2ee-engine.xml, if this could matter.)
    Regards,
    Matthias

    Hi, Experts,
    I have same exceiption as this one, my error message as:
    com.sap.engine.services.jndi.persistent.exceptions.NameNotFoundException: Object not found in lookup of Route.
    I register in Object: "Route" using JNDI in my RMI over IIOP server. However in my SAP Web Dynpro application, the javaBean model cannot talk with external RMI over IIOP server. my source code as:
                Context ctx = new InitialContext();
                Object obj = ctx.lookup("Route");
                route = (Route)PortableRemoteObject.narrow(obj, Route.class);
    How to make SAP J2EE server talk with external Cobra Server?

  • NameNotFoundException: Object not found in lookup of DataSource

    Hello All,
    I am getting the below error. I configure the Datasource in visual admin it is working in visual admin.
    I am trying to connect to java webservices it is not connecting to data souce.
    Exception:
    com.sap.engine.services.jndi.persistent.exceptions.NameNotFoundException: O
    bject not found in lookup of WSDataSource.
            at com.sap.engine.services.jndi.implserver.ServerContextImpl.lookup(ServerContextImpl.java:649)
            at com.sap.engine.services.jndi.implclient.ClientContext.lookup(ClientContext.java:344)
            at com.sap.engine.services.jndi.implclient.OffsetClientContext.lookup(OffsetClientContext.java:254)
            at com.sap.engine.services.jndi.implclient.OffsetClientContext.lookup(OffsetClientContext.java:271)
            at javax.naming.InitialContext.lookup(InitialContext.java:347)
            at javax.naming.InitialContext.lookup(InitialContext.java:347)
    com.sap.engine.services.webservices.runtime.EJBImplementationContainer.invokeMethod(EJBImplementationContainer.java:126)
            at com.sap.engine.services.webservices.runtime.RuntimeProcessor.process(RuntimeProcessor.java:157)
            at com.sap.engine.services.webservices.runtime.RuntimeProcessor.process(RuntimeProcessor.java:79)
            at com.sap.engine.services.webservices.runtime.servlet.ServletDispatcherImpl.doPost(ServletDispatcherImpl.java:92)
            at SoapServlet.doPost(SoapServlet.java:51)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
            at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)
            at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)
            at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:387)
            at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:365)
            at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:944)
            at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:266)
            at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)
            at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:160)
            at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
            at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
            at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
            at java.security.AccessController.doPrivileged(Native Method)
            at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
            at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    Please Help me .
    Thanks & Regards,
    Veera.

    It is not clear if you already created a Datasource to a specified database. This can be done via the Visual Admin.
    Services --> JDBC Connector. There you can upload vendor specific drivers and bind it to a database.
    This is possible usings the standards. JDBC 1.x and 2.0 way.
    Success.

  • NameNotFoundException in JNDI lookup in for stand alone App client in EJB3

    I created an ejb module in netbeans 5.5 added a session facade (SavingsaccountFacade) and downloaded it to SunAppServer 9 (java EE 5). When I try and access the JNDI name in a stand alone java application client using the following code
    Context initial = new InitialContext();
    Object objref = initial.lookup("ejb/SavingsaccountFacade");
    I get the following errors:
    javax.naming.NameNotFoundException: SavingsaccountFacade not found
    at com.sun.enterprise.naming.TransientContext.doLookup(TransientContext.java:203)
    I have added j2ee.jar, appserv-rt.jar, and the dist/SavingsAccount.jar to the library. When I do a similar thing in J2EE1.4 it worked fine.
    Can somebody help please.
    Thanks

    Hi Dave,
    Here's our EJB FAQ entry that explains how EJB Global JNDI names are set in the
    Java EE 5 SDK and Glassfish. The most likely explanation is that the name used
    in the client does not match the one assigned to your EJB in sun-ejb-jar.xml.
    https://glassfish.dev.java.net/javaee5/ejb/EJB_FAQ.html#SessionBeanGlobalJNDINameAssignment
    --ken                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • JNDI lookup from OC4J to weblogic throws javax.naming.NameNotFoundException

    Hi All,
    We have the below setup in our production environment.
    EJB application is deployed in the Weblogic 10.3.4.0 Server on Sun Solaris. The EJB version is 3.0
    OC4J 10.2.0 is running on another Sun Solaris machine.
    There are 2 webservice applications WEBSERV1 & TestSoapEJB running on this OC4J container.
    We need to do lookup the EJBs deployed on the Weblogic server. For this we used the below logic in the web service's Stateless session bean:
    String weblogicURL = "";
    Properties props = new Properties();
    try
    props.load(Thread.currentThread().getContextClassLoader().getResourceAsStream("wl.properties"));
    weblogicURL     = props.getProperty("weblogicURL");     
    catch (FileNotFoundException e)
    e.printStackTrace();
    catch (IOException e)
    e.printStackTrace();
    Context ctx = null;
    Hashtable ht = new Hashtable();
    ht.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory");
    ht.put(Context.SECURITY_PRINCIPAL,"weblogic");
    ht.put(Context.SECURITY_CREDENTIALS,"weblogic654");
    ht.put(Context.PROVIDER_URL, weblogicURL);
    ctx = NamingManager.getInitialContext(ht) ;
    // tried using //ctx = new InitialContext(ht); same behavior.
    TestEJB.AdministratorEJB ejb = (TestEJB.AdministratorEJB) ctx.lookup("TestEJB#TestEJB.AdministratorEJB");
    ctx.close();
    When we first test first WEBSER1, the lookup is fine.
    But when we test the second webservice WEBSER2, the webservice name itself not able to lookup: It gives the below error:
    javax.naming.NameNotFoundException: remaining name: env/TestSoapEJB
    Below is the stack throws thrown on browser:
    500 Internal Server Error
    javax.naming.NameNotFoundException: remaining name: env/TestSoapEJB     
    at weblogic.j2eeclient.SimpleContext.resolve(SimpleContext.java:35)     
    at weblogic.j2eeclient.SimpleContext.resolve(SimpleContext.java:39)     
    at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:59)     
    at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:59)     
    at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:64)     
    at weblogic.jndi.factories.java.ReadOnlyContextWrapper.lookup(ReadOnlyContextWrapper.java:45)     
    at weblogic.jndi.internal.AbstractURLContext.lookup(AbstractURLContext.java:130)     
    at javax.naming.InitialContext.lookup(InitialContext.java:392)     
    at oracle.j2ee.ws.SessionBeanRpcWebService.init(SessionBeanRpcWebService.java:65)     
    at javax.servlet.GenericServlet.init(GenericServlet.java:258)     
    at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpApplication.loadServlet(HttpApplication.java:2354)     
    at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpApplication.findServlet(HttpApplication.java:4795)     
    at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpApplication.getRequestDispatcher(HttpApplication.java:2821)     
    at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:680)     
    at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:285)     
    at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:126)     
    at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)     
    at java.lang.Thread.run(Thread.java:662)
    It seems that, the OC4J is looking in Weblogic context. But it should be looking in its own context. How to resolve this issue.
    The same case happens if i restart the OC4J and first test the TestSoapEJB the lookup is fine . But if i test the WEBSERV1 , it throws the same error as above. In short, if one of the webservices lookup is working fine, the other webservice is not working. At the same time only one webservice's lookup is working.
    Kindly help me to resolve this issue.
    regards,
    Zia
    Edited by: PT Expert on Sep 9, 2012 3:16 AM

    I work now more that two days on this error!!!
    -> I remade my complete jdev project, it did not work!
    -> I deleted the jdev/system/j2ee/oc4j/workspace dir
    -> I search for some .lock files
    -> and many more tries!!! But without success...
    Is there a way to reset the Embedded OC4J?

  • JNDI NameNotFoundException on ctx.lookup in WLS 6.1

    Hi dear all
    When deploying several entity beans in WLS 6.1 we always get a
    NameNotFoundException on the ctx.lookup for each bean. The JNDI name is
    defined (for every bean) in the IDE and also available in the WLS console
    (i.e. also in the deployment descriptor).
    Calling the ctx.lookup on the JNDI name for a DataSource defined in WLS does
    not raise an NameNotFoundException but a ClassCastException on the following
    "narrow" method (a DataSource object is not a bean --> so the WLS/VM runtime
    environment works right).
    Obviously, the JNDI names for the beans can not be determined/found
    correctly because of a deployment/version problem?!
    We're using JBuilder 5.0 and WLS 6.1SP1 on NT 4.0 (might be a/the problem?).
    Thx in advance
    Markus

    The java:comp/env namespace is specific to each individual component (i.e.,
    every component can potentially see a different set of objects with different
    names and/or the same objects with different names). For an EJB reference
    lookup, I believe that we automatically bind it under java:comp/env/ejb so if
    you specify the name of the ejb-ref as MyBeanHome in the ejb-jar.xml file, then
    the EJB whose deployment descriptor contains this ejb-ref entry can look up that
    referenced bean's home at java:comp/env/ejb/MyBeanHome. When you specify the
    JNDI name under which a bean will be deployed, we do not automatically make that
    bean home available to other beans in their respective java:comp/env/ejb
    namespaces (though they are accessible via the global JNDI name used to register
    the bean). To get this, you must create the ejb-ref entries and their
    corresponding ejb-reference-description entries in the deployment descriptors.
    Hope this helps,
    Robert
    Programit wrote:
    Ditto. I'm experiencing the same problem.
    I've spent a great deal of time working with this stuff. I believe Weblogic
    is lacking in their support here. It's obvious that something isn't working
    correctly, because everything was working fine before I installed WLS6.1
    with SP1. In fact, I have two systems running right now: The code and
    deployment descriptors are exactly the same. The System works fine in
    WLS6.1. The System does NOT work in WLS6.1 SP1 becuase of these damn Naming
    issues.
    We've deployed with the BEA RDBMS Security Realm -- without modification.
    Other than that, everything else is pretty standard. The JNDI tree on the
    Weblogic console doesn't work either. It says it can resolve "comp"!!!!
    "kefah Seyed" <[email protected]> wrote in message
    news:[email protected]...> Hi Markus
    I send this message because I have the same
    problem with JNDI. My envirronment is the
    same : I'm under nt 4.0 with weblogic 6.1
    but I use Together 5.5 and I tried to deploy manually the EJB.
    But it's always the same error.
    I tried under WebSphere and with a name
    like "java:comp/env/ejb-name" it work.
    So I tried all I could if you have a solution now please send me amessage.

  • NameNotFoundException: Object not found in lookup of 'JDBC-Alias Name'

    Hi Experts,
    I am getting the NameNotFoundException: Object not found in lookup exception, when accessing the DataSource  using the alias name EMPLOYEE_DS from JspDynpage.
    Here is the code for lookup
    InitialContext ctx = new InitialContext();
    // TODO  chenage the alias to the right one
    DataSource  ds = (DataSource) ctx.lookup("jdbc/EMPLOYEE_DS ");
    The same application is running using the above alias name in our development environment, but the same is not working in production system.
    I have created the same Alias Name for JDBC Datasource, but still is not working.
    Here is the Exception trace.
    com.sap.engine.services.jndi.persistent.exceptions.NameNotFoundException: Object not found in lookup of EMPLOYEE_DS.
    at com.sap.engine.services.jndi.implserver.ServerContextImpl.lookup(ServerContextImpl.java:649)
    at com.sap.engine.services.jndi.implclient.ClientContext.lookup(ClientContext.java:344)
    at com.sap.engine.services.jndi.implclient.OffsetClientContext.lookup(OffsetClientContext.java:254)
    at com.sap.engine.services.jndi.implclient.OffsetClientContext.lookup(OffsetClientContext.java:271)
    at javax.naming.InitialContext.lookup(InitialContext.java:347)
    at javax.naming.InitialContext.lookup(InitialContext.java:347)
    Should this alias name existed any where else, any configuration is missed.
    Thanks in Advance,
    Chinna.

    Hi Anup,
    As I said, My application is working in both Development and Quality system with the lookup
    DataSource ds = (DataSource) context.lookup("jdbc/MYDB")
    but the problem is in only Production system, I believe there might be some configuration missed.
    As you said I have tried with
    DataSource ds = (DataSource) context.lookup("java:comp/env/jdbc/MYDB")
    with the abvoe lookup my application stopped working and getting the below exception and throws the below exception
    com.sap.engine.services.jndi.persistent.exceptions.NameNotFoundException: Path to object does not exist at java:comp, the whole lookup name is java:comp/env/jdbc/REPORTING_DASHBOARD.
    I believe my lookup is working without any issues, because it is working in dev and quality systems, problem might be in configuration. I have done the alias creation through nwa, following
    http://<server:port>/nwa>Configuration>Application Resources-->JDBC Datasource Alias
    Any more suggestions regarding this.
    Thanks,
    Chinna.

  • JNDI lookup failed:javax.naming.NameNotFoundException

    Hello:
    I have a application (not web) that publish messages to a specific topic, i want to receive these messages in a Web Service, but when the web service make the call to a class that is the JMS Client it can't find the Connection factory Name that i create in the aplication.
    I want to know what i have to do,
    I work with J2EE1.3.1 and JMS1.0.2 for the application that publish the messages
    and Jwsdp1.1, tomcat 4 and j2sdk 1.4.0 for the web service.
    I create the connection factory with this command:
    j2eeadmin -addJmsFactory jms/DurableTopicB topic -props clientID=IdTopicB
    Then in the class that the web service invoke i trying to join with this:
    try {
    jndiContext =new InitialContext();
    }catch (NamingException e){
    System.err.println("Could not create JNDI API "+
    "context:"+e.toString());
    return;
    *Look up connection factory and topic.If either  
    *does not exist,exit.                            
    try {
    topicConnectionFactory =(TopicConnectionFactory)
    jndiContext.lookup(conFacName);
    }catch (NamingException e){                      
    System.err.println("JNDI API lookup failed:"+
    e.toString());
    return;
    //System.exit(1);
    But i receive a error message in the log of Tomcat:
    JNDI API lookup failed:javax.naming.NameNotFoundException: El nombre DurableTopicB no este asociado a este contexto
    Thanks

    Hello:
    I display the full context of the connection factory in the application that publish the message:
    Full context is :
    Enviroment is : {java.naming.corba.orb=com.sun.enterprise.iiop.POAEJBORB@ec4a87}
    And in the web service when i create the initial context the full context is:
    Full context is : java:
    Enviroment is : {java.naming.factory.initial=org.apache.naming.java.javaURLContextFactory, java.naming.factory.url.pkgs=org.apache.naming}
    How can i see the connection factory in the Web Service, because the connection factory was created in other Application?

  • Tried to lookup an EJB (succ dply) got: javax.naming.NameNotFoundException

    Hi
    I use JDev Studio 10.1.3.40.66 and EJB 3.0 with annotations. I am working in the same Project (Model) with two stateless beans and some entities. In the same Project I have one test-client which implemented the lookup.
    Here a snippet of the EJB:
    @Stateless( name = "MyDao" )
    public class MyDaoImpl implements IMyDao {
    ... }Here piece of code out of test-client:
    final Context context = getInitialContext();
    IMyDao iMyDao = (IMyDao)context.lookup("MyDao");Now everything worked fine and nobody changed anything in the project. So it may be that after a "power off" and a restart I couldn't find my EJBs with the lookup?!
    Here is what I get from OC4J log:
    07/04/02 10:32:09 FEIN: TxSecIORInterceptor.addCSIv2Components Unable to obtain mutual auth port
    07/04/02 10:32:09 FEIN: TxSecIORInterceptor.addCSIv2Components UnknownType exceptioncom.sun.corba.ee.spi.legacy.interceptor.UnknownType
    (Here is some more stack trace!)
    FEIN: [current-workspace-app:Azima_AzimaModel_0] Initializing EntityManagerFactory named Azima-local with persistence provider oracle.toplink.essentials.ejb.cmp3.EntityManagerFactoryProvider.
    07/04/02 10:32:13 WARNUNG: Application.setConfig Application: current-workspace-app is in failed state as initialization failed.
    java.lang.LinkageError: loader constraints violated when linking javax/persistence/spi/PersistenceUnitInfo class
    Checking that EJBs were successfully deployed in embedded OC4J...
    All EJBs are successfully deployed.From my test-client log I get:
    javax.naming.NameNotFoundException: MyDao not found
         at com.evermind.server.rmi.RMIClientContext.lookup(RMIClientContext.java:52)
         at javax.naming.InitialContext.lookup(InitialContext.java:351)
         at com.promatis.azima.model.test.Client.main(Client.java:390)
    ...So I couldn't test my EJB anymore. If you have some suggestions or if you need more information about my project just post...
    I need some help with this problem!
    Thanks

    I work now more that two days on this error!!!
    -> I remade my complete jdev project, it did not work!
    -> I deleted the jdev/system/j2ee/oc4j/workspace dir
    -> I search for some .lock files
    -> and many more tries!!! But without success...
    Is there a way to reset the Embedded OC4J?

  • Javax.naming.NameNotFoundException: While trying to lookup 'mail.NewMailSes

    Hi All,
    Am using jdeveloper 11.1.1.6. Am trying to send a mail through ADF
    I have verfied the link which given below and trying to do the same.
    http://adfblogs.blogspot.in/2012/01/sending-e-mail-from-adf-application.html
    While am pressing the send button am getting the exception as
    <LifecycleImpl> <_handleException> ADF_FACES-60098:Faces lifecycle receives unhandled exceptions in phase INVOKE_APPLICATION 5
    javax.faces.el.EvaluationException: javax.naming.NameNotFoundException: While trying to lookup 'mail.NewMailSession' didn't find subcontext 'mail'. Resolved ''; remaining name 'mail/NewMailSession'
         at org.apache.myfaces.trinidadinternal.taglib.util.MethodExpressionMethodBinding.invoke(MethodExpressionMethodBinding.java:58)
         at org.apache.myfaces.trinidad.component.UIXComponentBase.broadcastToMethodBinding(UIXComponentBase.java:1256)
         at org.apache.myfaces.trinidad.component.UIXCommand.broadcast(UIXCommand.java:183)
         at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
         at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._invokeApplication(LifecycleImpl.java:889)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:379)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:194)
    Could any one pls help me to resolve it?

    I had restarted the weblogic server even though am getting the same error
    javax.naming.NameNotFoundException: While trying to lookup 'mail.NewMailSession' didn't find subcontext 'mail'. Resolved ''; remaining name 'mail/NewMailSession'
         at weblogic.jndi.internal.BasicNamingNode.newNameNotFoundException(BasicNamingNode.java:1139)
         at weblogic.jndi.internal.BasicNamingNode.lookupHere(BasicNamingNode.java:247)
         at weblogic.jndi.internal.ServerNamingNode.lookupHere(ServerNamingNode.java:182)
         at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:206)
         at weblogic.jndi.internal.WLEventContextImpl.lookup(WLEventContextImpl.java:254)
         at weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:411)
         at javax.naming.InitialContext.lookup(InitialContext.java:392)
         at Mail.SendAction(Mail.java:49)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.sun.el.parser.AstValue.invoke(Unknown Source)
         at com.sun.el.MethodExpressionImpl.invoke(Unknown Source)

  • Javax.naming.NameNotFoundException: While trying to lookup 'jdbc.SampleHR1DS' didn't find subcontext

    hi,
    i have installed hr schema and created a page with a table.when i run the page,
    i am getting  javax.naming.NameNotFoundException: While trying to lookup 'jdbc.SampleHR1DS' didn't find subcontext 'jdbc'. Resolved ''; remaining name 'jdbc/SampleHR1DS'
    Do i need to create data source for this.How to resolve this.
    i am using 11.1.2.4.0 jdev

    there are multiple option of creating data source.which one i should use.
    should i use generic one. what is URL information for oracle xe client.what is driver name?

  • Lookup DataSource: NameNotFoundException

    I am having a terrible time looking up a data source. I always get a NameNotFoundException.
    Here is what I've got:
    WEB.XML
    <resource-ref>
         <res-ref-name>impresaDataSource</res-ref-name>
         <res-type>javax.sql.DataSource</res-type>
    <res-auth>CONTAINER</res-auth>
    </resource-ref>
    WEBLOGIC.XML
    <reference-descriptor>
         <resource-description>
              <res-ref-name>impresaDataSource</res-ref-name>
              <jndi-name>jdbc/impresaDataSource</jndi-name>
         </resource-description>
    </reference-descriptor>
    CONFIG.XML
    <JDBCConnectionPool CapacityIncrement="5"
    DriverName="oracle.jdbc.driver.OracleDriver"
    InitialCapacity="5"
    MaxCapacity="50" Name="impresaPool"
    Password="{3DES}vWu5VQp5y9k=" Properties="user=world"
    Targets="impresa-server"
    URL="jdbc:oracle:thin:@orion:1521:devl7"/>
    <JDBCDataSource JNDIName="jdbc/impresaDataSource"
    Name="impresaDataSource" PoolName="impresaPool"
    RowPrefetchEnabled="false" Targets="impresa-server"/>
    THE CODE:
    Properties props = new Properties();
    IntialContext ctx = new InitialContext(props);
    DataSource ds = ctx.lookup("impresaDataSource");
    I've tried everything I can think of, but nothing seems to work. Another thread
    from about a year ago suggested adding the following properties to the connection
    pool:
    dll=ocijdbc8;protocol=thin
    But that did not work either.
    Any ideas?

    TRY:
    WEB.XML
    <resource-ref>
    <res-ref-name>jdbc/impresaDataSource</res-ref-name>
    <res-type>javax.sql.DataSource</res-type>
    <res-auth>CONTAINER</res-auth>
    </resource-ref>
    WEBLOGIC.XML
    <reference-descriptor>
    <resource-description>
    <res-ref-name>jdbc/impresaDataSource</res-ref-name>
    <jndi-name>impresaDataSource</jndi-name>
    </resource-description>
    </reference-descriptor>
    CONFIG.XML
    <JDBCConnectionPool CapacityIncrement="5"
    DriverName="oracle.jdbc.driver.OracleDriver"
    InitialCapacity="5"
    MaxCapacity="50" Name="impresaPool"
    Password="{3DES}vWu5VQp5y9k=" Properties="user=world"
    Targets="impresa-server"
    URL="jdbc:oracle:thin:@orion:1521:devl7"/>
    <JDBCDataSource JNDIName="jdbc/impresaDataSource"
    Name="impresaDataSource" PoolName="impresaPool"
    RowPrefetchEnabled="false" Targets="impresa-server"/>"kai" <[email protected]> wrote:
    >
    I would say it must be: java:comp/env/jdbc/impresaDataSource
    Regards,
    Kai
    Rajesh Mirchandani <[email protected]> wrote:
    Try
    DataSource ds = ctx.lookup("java:comp/env/impresaDataSource");
    Aidan Monroe wrote:
    I should have mentioned that I am running on WLS 7.0
    I am having a terrible time looking up a data source. I always geta NameNotFoundException.
    Here is what I've got:
    WEB.XML
    <resource-ref>
    <res-ref-name>impresaDataSource</res-ref-name>
    <res-type>javax.sql.DataSource</res-type>
    <res-auth>CONTAINER</res-auth>
    </resource-ref>
    WEBLOGIC.XML
    <reference-descriptor>
    <resource-description>
    <res-ref-name>impresaDataSource</res-ref-name>
    <jndi-name>jdbc/impresaDataSource</jndi-name>
    </resource-description>
    </reference-descriptor>
    CONFIG.XML
    <JDBCConnectionPool CapacityIncrement="5"
    DriverName="oracle.jdbc.driver.OracleDriver"
    InitialCapacity="5"
    MaxCapacity="50" Name="impresaPool"
    Password="{3DES}vWu5VQp5y9k=" Properties="user=world"
    Targets="impresa-server"
    URL="jdbc:oracle:thin:@orion:1521:devl7"/>
    <JDBCDataSource JNDIName="jdbc/impresaDataSource"
    Name="impresaDataSource" PoolName="impresaPool"
    RowPrefetchEnabled="false" Targets="impresa-server"/>
    THE CODE:
    Properties props = new Properties();
    IntialContext ctx = new InitialContext(props);
    DataSource ds = ctx.lookup("impresaDataSource");
    I've tried everything I can think of, but nothing seems to work. Anotherthread
    from about a year ago suggested adding the following properties tothe connection
    pool:
    dll=ocijdbc8;protocol=thin
    But that did not work either.
    Any ideas?--
    Rajesh Mirchandani
    Developer Relations Engineer
    BEA Support

Maybe you are looking for

  • Keyword "this"

    What exactly is keyword -"this" ? can nyone explain me "this" in regards with execution on cpu?

  • HFM Config - Cluster Config

    Hi, I have a "working" HFM environment. I lost some servers due to a hardware failure and I want to re-run the config utility to remove those servers from the Cluster. I run the EPMA Confg utility and the "Confgiure Cluster Application" and "Register

  • Can't update device package for adobe DC in cd photo shop CS3 beta)

    i've installed device central from CD Photoshop CS3 BETA , the problem is i can not install new device package for the file that download from net , and it always shown ( the file update is too new for this version of adobe device central ).... someb

  • What output format is needed for Cambodian broadcast TV?

    I am in the USA.  I have been asked to shoot a video for use on Cambodian TV, which looks like 4:3.  I have only newer equipment that shoots in H.264.  My main camera is a Sony HDR AX-2000 camcorder that is capable of shooting at 480/30p or 480/24 as

  • Arch Linux Support for Atmel ATmega168

    I'm thinking about buying this ATmega168: http://www.amazon.com/NerdKits-USB-Micr - B001I08PK8 I'm wondering if the avrdude, binutils-avr, and gcc-avr packages (http://www.archlinux.org/packages/?q=avr) will work with it... Does anyone know? Last edi