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

Similar Messages

  • DAO pattern & Lookup datasource with NamingException in the same J2EE APP

    Hello Experts:
    I'm developing an J2EE application with EJB's for transactional operations (that works fine!) and I'm implementing the J2EE DAO Pattern using a DAO ConnectionFactory with OpenSQL/JDBC standard for Querying the DB, but here my problems begins:
    The DAOConnectionFactory Singleton Class is placed in a java package inside the same application that holds my Entitys & Sessions (remember this ejb's works fine!) and I'm trying to get the "localy-configured-in-the-j2ee-application" alias-datasource for my DAO Querys, but "lookup" doesn't find this resource!!!.
    I'm thinking, there's not remote access to this resouce because the DAO-CF is in the same context and JVM, but this appreciation is correct? or  what I miss?
    Another remark: I've been used the Telnet Administrator and the same lookup string is founded correctly!.
    Here is the Codec:
    public class ConexionFactory implements Serializable {
         private static ConexionFactory singleton = null;
         private DataSource ds;
         protected ConexionFactory() {
              String source = "jdbc/BURO_COMM";
              try {
                   Context ctx = new InitialContext();
                   ds = (DataSource) ctx.lookup(source);
                   if (null == ds) {
                        throw new RuntimeException("Couldn't get the datasource");
              } catch (NameNotFoundException e) {
                   throw new RuntimeException(e.getMessage());
              } catch (NamingException e) {
                   throw new RuntimeException(e.getMessage());
         public static ConexionFactory getInstance() {
              if (null == singleton) {
                   singleton = new ConexionFactory();
              return singleton;
    .... (some other methods)

    Hello all again:
    I've been making some tests (and investigation reading other posts) and I found that everything is related with the Resource Sharing Scope of my Session Object that commands the process. And it works fine.
    By now, for my conceptual test is Ok and finally i must work in this app arquitecure path:
    ->Web Service (with a POJO in a web module)
    >ProcessRender Class (a POJO with the main control logic)
    >BussinesDelegate's -->ServiceLocator
    >SessionFacades --->Entity's
    >DAO Connection Factory---->OpenSQL/JDBC Querys

  • Unable lookup Datasource from EJB

    I am unable to lookup the datasource from my entity bean. I am using BMP in Weblogic
    81. The call in the bean is :
    ds = (DataSource)jndiContext.lookup("java:comp/env/jdbc/myPool");
    I get the following exception:
    javax.naming.LinkException: . Root exception is javax.naming.NameNotFoundExcept
    ion: While trying to lookup 'jdbc.myPool' didn't find subcontext 'jdbc' Re
    solved ; remaining name 'jdbc/myPool'
    at weblogic.jndi.internal.BasicNamingNode.newNameNotFoundException(Basic
    NamingNode.java:869)
    at weblogic.jndi.internal.BasicNamingNode.lookupHere(BasicNamingNode.jav
    In my config.xml file, I have the pool setup as:
    <JDBCConnectionPool DriverName="oracle.jdbc.OracleDriver"
    Name="myPool" Password="{3DES}PKeN6pXlt/o="
    Properties="user=dmluser" Targets="myserver"
    TestConnectionsOnCreate="true" TestConnectionsOnReserve="true"
    TestTableName="SQL SELECT 1 FROM DUAL" URL="jdbc:oracle:thin:@localhost:1521:DEV"/>
    <JDBCTxDataSource JNDIName="myPool" Name="myPool"
    PoolName="myPool" Targets="myserver"/>
    Any ideas of what might be wrong?
    Thanks
    Tom

    You have defined the datasource with a global JNDI name, so
    jndiContext.lookup("myPool") would work.
    java:/comp/env is a JNDI namespace local to your component. So if you
    will need to add a mapping in your BMP's ejb-jar.xml and
    weblogic-ejb-jar.xml that maps comp/env/jdbc/myPool to the myPool name
    in the global JNDI.
    -- Rob
    Tom Jordan wrote:
    I am unable to lookup the datasource from my entity bean. I am using BMP in Weblogic
    81. The call in the bean is :
    ds = (DataSource)jndiContext.lookup("java:comp/env/jdbc/myPool");
    I get the following exception:
    javax.naming.LinkException: . Root exception is javax.naming.NameNotFoundExcept
    ion: While trying to lookup 'jdbc.myPool' didn't find subcontext 'jdbc' Re
    solved ; remaining name 'jdbc/myPool'
    at weblogic.jndi.internal.BasicNamingNode.newNameNotFoundException(Basic
    NamingNode.java:869)
    at weblogic.jndi.internal.BasicNamingNode.lookupHere(BasicNamingNode.jav
    In my config.xml file, I have the pool setup as:
    <JDBCConnectionPool DriverName="oracle.jdbc.OracleDriver"
    Name="myPool" Password="{3DES}PKeN6pXlt/o="
    Properties="user=dmluser" Targets="myserver"
    TestConnectionsOnCreate="true" TestConnectionsOnReserve="true"
    TestTableName="SQL SELECT 1 FROM DUAL" URL="jdbc:oracle:thin:@localhost:1521:DEV"/>
    <JDBCTxDataSource JNDIName="myPool" Name="myPool"
    PoolName="myPool" Targets="myserver"/>
    Any ideas of what might be wrong?
    Thanks
    Tom

  • Lookup datasource on middle tier

    Hi All,
    I need help looking up a datasource stored in the middle-tier. The program I will be performing the lookup from doesn't run from within the container and as such is external. Is this possible? What values would I need to place in the environment settings for the InitialContext? What other pre-conditions exist for this sort of lookup?
    Thanks in advance.
    Elisha

    Hi Laosfalvi,
    I am actually trying to access the database using parameters set in the Datasource without actually writing a web component like a servlet or such stuff. In effect I only need to access the container for the datasource after that the J2SE program does the other functions of the application.
    Regards
    Elisha

  • NamingException when trying to lookup DataSource (Oracle)

    I am using Sun 6.1 Web Server with Oracle 9i, and we are evaluating these products (so no support contract).
    I have a connection pool configured as follows:
    <RESOURCES>
    <JDBCCONNECTIONPOOL name="foo_pool" datasourceclassname="oracle.jdbc.pool.OracleDataSource" steadypoolsize="8" maxpoolsize="32" poolresizequantity="2" idletimeout="300" maxwaittime="60000" connectionvalidationrequired="on" connectionvalidationmethod="meta-data" validationtablename="" failallconnections="off" transactionisolationlevel="read-committed" isolationlevelguaranteed="off">
    <PROPERTY name="URL" value="jdbc:oracle:thin:@XX.XX.XX.XXX:1521:oracledv"/>
    <PROPERTY name="User" value=" . . . "/>
    <PROPERTY name="Password" value=" . . . "/>
    </JDBCCONNECTIONPOOL>
    <JDBCRESOURCE jndiname="jdbc/foo_pool" poolname="foo_pool" enabled="on"/>
    </RESOURCES>
    Of course the user and password values are filled in.
    The foo_pool object is there within the JDBC context, and the class of the object as reported by listBindings is javax.sql.DataSource.
    I am trying to lookup the DataSource from a JSP deployed within a web app.
    However, I am getting a NamingException with the explanation "cannot create resource instance". The cause and rootCause Throwable fields of this NamingException are null (big help that is).
    The line that causes the exception is the one that invokes lookup on the "jdbc" sub context, with the parameter "foo_pool".
    I have set up JDBC connection pools to Oracle in the past using WebLogic and JBoss, so I am at least somewhat competent at this. Still somehow I get the feeling that some class is missing, or there is an attempt to instantiate the wrong class or an incompatible class, but since there is no information beyond "cannot instantiate" I have no idea where else to look, after having googled until I am blue in the face.
    Can anyone help?
    Thanks,
    Erik

    Does this help?
    http://swforum.sun.com/jive/thread.jspa?forumID=16&threadID=24492

  • 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.

  • NameNotFoundException when looking up datasource jndi from standalone clien

    Hi,
    I'm trying to lookup datasource jndi from standalone client, but always get exceptions.
    I configured an oralce datasource with jndi name "oracleDataSource". When looking it up in servlet, I can get connection.
    In order to test it from standalone client, I created following code:
    public class DataSourceTest
    * Attempt to authenticate the user.
    public static void main(String[] args)
    String datasource = null;
    if (args.length == 1 ) {
    datasource = args[0];
    System.out.println("datasource = "+datasource);
    if(datasource == null)
    datasource = "oracleDataSource";
    try{
    Connection conn = null;
    Properties env = new Properties();
    env.put("java.naming.factory.initial","com.sun.jndi.cosnaming.CNCtxFactory");
    env.put("java.naming.provider.url", "iiop://localhost:3700");
    Context initial = new InitialContext(env);
    if(datasource != null){
    DataSource ds = (DataSource)initial.lookup(datasource);
    conn = ds.getConnection();
    if(conn != null){
    System.out.println("datasource is gotten.");
    conn.close();
    else
    System.out.println("datasource is error.");
    System.exit(0);
    } catch (Exception ex) {
    System.err.println("Caught an unexpected exception!");
    ex.printStackTrace();
    When running, I get following exception:
    [java] datasource = oracleDataSource
    [java] Caught an unexpected exception!
    [java] javax.naming.NameNotFoundException. Root exception is org.omg.CosNaming.NamingContextPackage.NotFound
    [java] at org.omg.CosNaming.NamingContextPackage.NotFoundHelper.read(NotFoundHelper.java:34)
    [java] at org.omg.CosNaming._NamingContextExtStub.resolve(_NamingContextExtStub.java:402)
    [java] at com.sun.jndi.cosnaming.CNCtx.callResolve(CNCtx.java:368)
    [java] at com.sun.jndi.cosnaming.CNCtx.lookup(CNCtx.java:417)
    [java] at com.sun.jndi.cosnaming.CNCtx.lookup(CNCtx.java:395)
    [java] at javax.naming.InitialContext.lookup(InitialContext.java:350)
    [java] at com.tbcn.ceap.test.cilent.DataSourceTest.main(DataSourceTest.java:42)
    I also tried many other methods but always got exceptions. What's wrong with it? How can I lookup the datasource jndi from standalone client?
    Thanks in advance!

    Thank Tuan!
    I tried. When running, the server will read security.properties and ejb.properties. But I didn't use ejb and I didn't know how to configure ejb.properties, so I let ejb.properties empty. The security.properties is as following:
    client.sendpassword=true
    server.trustedhosts=*
    interop.ssl.required=false
    interop.authRequired.enabled=false
    interop.nameservice.ssl.required=false
    The result is:
    [java] javax.naming.CommunicationException: Can't find SerialContextProvider
    [java] at com.sun.enterprise.naming.SerialContext.getProvider(SerialContext.java:63)
    [java] at com.sun.enterprise.naming.SerialContext.lookup(SerialContext.java:120)
    [java] at javax.naming.InitialContext.lookup(InitialContext.java:347)
    [java] at com.tbcn.ceap.test.cilent.DataSourceTest.main(DataSourceTest.java:42)
    Also, I tried it with ACC. In sun sample ConverterClient.java under rmi-iiop/simple, I added following code under with ACC and without ACC. With ACC, I can get connection. But without ACC, I can't get it.
    try{
              DataSource ds = (DataSource)initial.lookup("oracleDataSource");
              Connection conn = ds.getConnection();
              if(conn != null){
              System.out.println("datasource oracleDataSource gotten.");
              conn.close();
              else
              System.out.println("oracleDataSource is error.");
    Does it means that we must lookup datasource jndi with ACC?

  • DataSource lookup error in bpel 10.1.3

    Hi,
    i have a java client program in jdeveloper 10.1.3 from which i am trying to connect bpel 10.1.3 datasource but it is not able to find the datasource even it is able to connect bpel server RMI port where all datasouces has been defined.
    as part of code is-
    Hashtable env = new Hashtable();
    env.put("java.naming.factory.initial",
    "com.evermind.server.ApplicationClientInitialContextFactory");
    env.put("java.naming.provider.url", "ormi://localhost:12401");
    \\ loacl bpel server RMI port connection
    env.put("java.naming.security.principal", "oc4jadmin"); \\username
    env.put("java.naming.security.credentials", "sadmin01"); \\Password
    context = new InitialContext(env);
    \\Till here it is able to create initial context using hashtable
    dataSource = (DataSource) context.lookup("jdbc/XRefFunctionsSource");
    \\ Here it failed to lookup datasource
    I had defined the datasouce in bpel sever through enterprise manager.
    I tried to connect all by default datasources which are there initially but it failed.
    Please tell any suggestion to change in my code to connect datasource.
    Thanks.

    This is the complete piece of code in which i am trying to get DB Connection from jdeveloper 10.1.3 -
    public class Test
    public Test() throws Exception
    static Test instance= null;
    Context context;
    Connection connection;
    DataSource dataSource;
    try{
    * Create access to the naming context, initialized from the
    * Hashtable parameter to the constructor.
    Hashtable env = new Hashtable();
    env.put("java.naming.factory.initial",
    "com.evermind.server.ApplicationClientInitialContextFactory");
    env.put("java.naming.provider.url", "ormi://localhost:12401");
    env.put("java.naming.security.principal", "oc4jadmin");
    env.put("java.naming.security.credentials", "sadmin01");
    context = new InitialContext(env);
    System.out.println("InitialContext created using Hashtable...");
    * Lookup the jdbc/BPELSamplesDataSource object.
    dataSource = (DataSource)
    context.lookup("jdbc/XRefFunctionsSource");
    System.out.println("jdbc/XRefFunctionsSource found...");
    System.out.println("Connecting to database ...");
    //dataSource =
    connection = dataSource.getConnection("orabpel","orabpel");
    System.out.println("Got database connection ...");
    catch(Exception e)
    System.out.println("" + e);
    throw e;
    private static Test instance() throws Exception
    if (instance== null)
    instance = new Test();
    return instance;
    private Connection getConnection() throws Exception
    return connection;
    public static void main(String[] args)
    Connection con = Test.instance().getConnection();
    I tried a lot with different options but still it is not working..
    As i told the same code is working for bpel 10.1.2 using jdeveloper 10.1.2.
    Is there any other way to get DB connection here?
    Thanks,
    Anil
    Message was edited by:
    user516357

  • Could not retreive datasource oracle in webdynpro

    Hi,
    I've defined a datasource for oracle in the visual administrator :
    jdbc datasource :
    Data Source Type:   driver-based
    Driver Library:  ojdbc14.jar
    SQL Engine:   vendor sql
    Isolation Level:   default
    driver class :   oracle.jdbc.OracleDriver
    URL:  jdbc:oracle:thin:@<host>:<port>:<sid>
    I try to use it in my webdynpro :
    javax.sql.DataSource ds=(javax.sql.DataSource)ctx.lookup(<dataSource name>);
    java.sql.Connection con=ds.getConnection();
    java.sql.Statement stmt=con.createStatement();
    con.close();
    But it throws the following exception :
    com.sap.engine.services.jndi.persistent.exceptions.NameNotFoundException: Object not found in lookup of Baical_V1.
    Does someone know what I could do ?
    Thanks
    Regards
    Claire

    Thanks Anilkumar,
    I've resolved my problem :
    this parameters can't work :
    Data Source Type: driver-based
    Driver Library: ojdbc14.jar
    SQL Engine: vendor sql
    Isolation Level: default
    driver class : oracle.jdbc.OracleDriver
    URL: jdbc:oracle:thin:@<host>:<port>:<sid>
    like it is explained in thread :
    JDBC Connector in NetWeaver Dev Studio WebAS
    I couldn't issue with a "driver-based" dataSource type AND the ojdbc14.jar driver like indicated in note 941594.
    I've used this parameters :
    Datasource type: ConnectionPoolDataSource
    JDBC Version: 2.0
    Driver: <name of the ojdbc14.jar deployed driver> (this driver has to be deployed before ! : http://help.sap.com/saphelp_nw04/helpdata/en/80/4f34c587f05048adee640f4c346417/frameset.htm)
    SQL Engine: vendor sql
    Isolation Level: default
    Driver class: oracle.jdbc.pool.OracleDataSourceFactory
    CPDS Classname: oracle.jdbc.pool.OracleConnectionPoolDataSource
    Additional properties:
    url = jdbc:oracle:thin:@host:port:instance
    user = xxxx
    password = yyyyy
    (Names of properties must be lower-cased)
    A good solution to find where was the problem, was to try to declare the datasource directly in the application (adding a data-sources.xml in the META-INF directory http://help.sap.com/saphelp_nw04/helpdata/en/64/0bee3da7138e5be10000000a114084/frameset.htm
    ) so you can have the detail of the exception in the datasource when you deploy the application, whereas when you create a wrong datasource, in the WAS, you have no message !
    Regards,
    Claire

  • Error Connecting to Database using Weblogic Datasource

    Hi,
    I am trying to connect to oracle database from my program using weblogic DataSource. I am using JDK1.3.1.08 , weblogic 7.
    I am using the following code to get Connection object.
    contextFactory ="weblogic.jndi.WLInitialContextFactory";
    providerURL="t3://192.168.0.29:7001";
    dataSource ="temp_ds";
    if(contextFactory!=null)
    properties.put(Context.INITIAL_CONTEXT_FACTORY,contextFactory);
    if(providerURL !=null)
    properties.put(Context.PROVIDER_URL, providerURL);
    initCtx = new InitialContext(properties);
    DataSource ds= (javax.sql.DataSource) initCtx.lookup(dataSource);
    Connection con = ds.getConnection();
    con.setAutoCommit(false);
    I am getting the following error while running the program. Can any body help?
    javax.naming.CommunicationException. Root exception is weblogic.socket.Unrecove
    rableConnectException: [JDK 1.3 or higher required]
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.io.IOException.<init>(IOException.java:47)
    at java.net.SocketException.<init>(SocketException.java:36)
    at java.net.ConnectException.<init>(ConnectException.java:34)
    at weblogic.socket.UnrecoverableConnectException.<init>(UnrecoverableCon
    nectException.java:19)
    at weblogic.rjvm.RJVMManager.checkVersion(RJVMManager.java:451)
    at weblogic.rjvm.RJVMManager.findOrCreateRemoteInternal(RJVMManager.java
    :201)
    at weblogic.rjvm.RJVMManager.findOrCreate(RJVMManager.java:191)
    at weblogic.rjvm.RJVMFinder.findOrCreateRemoteServer(RJVMFinder.java:203)
    at weblogic.rjvm.RJVMFinder.findOrCreate(RJVMFinder.java:169)
    at weblogic.rjvm.ServerURL.findOrCreateRJVM(ServerURL.java:262)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compi
    led Code)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLIni
    tialContextFactoryDelegate.java:221)
    at weblogic.jndi.WLInitialContextFactory.getInitialContext(WLInitialCont
    extFactory.java:149)
    at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:671)
    at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:242)
    at javax.naming.InitialContext.init(InitialContext.java:218)
    at javax.naming.InitialContext.<init>(InitialContext.java:194)
    at WeblogicTest.getConnection(WeblogicTest.java:40)
    at WeblogicTest.<init>(WeblogicTest.java:23)
    at WeblogicTest.main(WeblogicTest.java:18)
    at WeblogicTest.printTableData(Compiled Code)
    at WeblogicTest.<init>(WeblogicTest.java:24)
    at WeblogicTest.main(WeblogicTest.java:18)
    Regards
    Kumar

    I am not sure if this is the reason, but going thru the stack trace ...
    javax.naming.CommunicationException. Root exception is weblogic.socket.Unrecove
    rableConnectException: [JDK 1.3 or higher required]Make sure you have JDK 1.3 or higher installed.
    Cheers
    Sekar

  • Error in Validating datasource

    I'm installing LivCycle on SUSE 10 with Weblogic 11g and Oracle 10.
    When trying to validate, the following error occurs:
    Validating datasource...
    Datasource Fail
    Name:IDP_DS
    JNDI:IDP_DS
    Data source settings failed validation. Failed to find/lookup datasource IDP_DS. The datasource may not be configured or may have failed to come online or is not accessible outside the LiveCycle application.
    ALC-LCM-120-301: Data source settings failed validation. Failed to find/lookup datasource IDP_DS. The datasource may not be configured or may have failed to come online or is not accessible outside the LiveCycle application.
    Datasource Fail
    Name:RM_DS
    JNDI:EDC_DS
    Data source settings failed validation. Failed to find/lookup datasource EDC_DS. The datasource may not be configured or may have failed to come online or is not accessible outside the LiveCycle application.
    ALC-LCM-120-301: Data source settings failed validation. Failed to find/lookup datasource EDC_DS. The datasource may not be configured or may have failed to come online or is not accessible outside the LiveCycle application.
    Any ideas?
    Thanks!

    Are you using secured data sources?  More here:
    http://blogs.adobe.com/livecycle/2010/04/livecycle_on_weblogic_-_securi.html
    http://blogs.adobe.com/livecycle/2010/09/increasing-weblogic-as-jdbc-connection-pool-size- for-livecycle-content-services-es2.html

  • Validate  datasource falied in configuration manager

    During Livecycle ES2 installation In configuration manager -> When i click on validate the datasource under the step Application server Validation  i get the error
    Note: I am using Weblogic 11g,Sql server 2005 sp3
    Please Help
    Datasource Fail
    Name:IDP_DS
    JNDI:IDP_DS
    Data source settings failed validation. Failed to                        find/lookup datasource IDP_DS. The datasource may not be                        configured or may have failed to come online or is not                        accessible outside the LiveCycle application.
    ALC-LCM-120-301: Data source settings failed validation.                        Failed to find/lookup datasource IDP_DS. The datasource                        may not be configured or may have failed to come online                        or is not accessible outside the LiveCycle application.
    Datasource Fail
    Name:RM_DS
    JNDI:EDC_DS
    Data source settings failed validation. Failed to                        find/lookup datasource EDC_DS. The datasource may not be                        configured or may have failed to come online or is not                        accessible outside the LiveCycle application.
    ALC-LCM-120-301: Data source settings failed validation.                        Failed to find/lookup datasource EDC_DS. The datasource                        may not be configured or may have failed to come online                        or is not accessible outside the LiveCycle application.

    just create a new package from source: \\sccm2012server\SMS_CAS\Client
    Rob Szarszewski
    That's what I did to keep me going but that won't fix the issue, will it? I tried to remove all all the XXX00002 related ini files under the contentlib folder with no luck
    I'm also having "hash value" incorrect on the CCM client package - created 3 different CCM client packages with source as SCCM client folder and other locations - keep getting hash value not correct most of the time.

  • Trying To make DB connection using DataSource

    Hi ,
    I am working on Jdev 11g . Getting exception while trying to execute below code:
    import java.sql.*;
    import java.util.Hashtable;
    import javax.naming.*;
    import javax.sql.*;
    final class GetConnection {
    /** Uses JNDI and Datasource (preferred style). */
    static Connection getJNDIConnection(){
    // String DATASOURCE_CONTEXT = "java:comp/env/jdbc/blah";
    String DATASOURCE_CONTEXT = "JNDIDataSource-0";
    // String DATASOURCE_CONTEXT = "TESTJNDI_CONN";
    System.out.println("Control till here :1");
    Connection result = null;
    try {
    Context initialContext = new InitialContext();
    if ( initialContext == null){
    System.out.println("JNDI problem. Cannot get InitialContext.");
    System.out.println("Control till here :2");
    Hashtable<String, String> table = new Hashtable<String, String>();
    System.out.println("Here");
    table.put(Context.INITIAL_CONTEXT_FACTORY,
    "weblogic.jndi.WLInitialContextFactory");
    System.out.println("Control till here :3");
    table.put(Context.PROVIDER_URL, "hostName");
    System.out.println("Control till here :4");
    table.put(Context.SECURITY_PRINCIPAL, "weblogic");
    System.out.println("Control till here :5");
    table.put(Context.SECURITY_CREDENTIALS, "weblogic123");
    System.out.println("Control till here :6");
    initialContext = new InitialContext(table);
    System.out.println("Control till here :7");
    initialContext = new InitialContext(table);
    System.out.println("Control till here :8");
    DataSource datasource = (DataSource)initialContext.lookup(DATASOURCE_CONTEXT);
    DataSource source = (DataSource)new InitialContext().lookup("DataSource");
    // result = source.getConnection();
    System.out.println("Control till here :9");
    if (datasource != null) {
    System.out.println("Control till here :3");
    result = datasource.getConnection();
    System.out.println("Control till here :4");
    else {
    System.out.println("Failed to lookup datasource.");
    catch ( NamingException ex ) {
    System.out.println("Cannot get connection: 1" + ex);
    catch(SQLException ex){
    System.out.println("Cannot get connection: 2" + ex);
    return result;
    public static void main(String[] args) throws Exception {
    //WBSCallingProc WbsProc = new WBSCallingProc();
    String returnValue;
    GetConnection getConnection = new GetConnection();
    // returnValue =home.callingProcedure();
    Connection returnValue1 =getConnection.getJNDIConnection();
    System.out.println("returnValue1 " + returnValue1);
    Log
    Control till here :1
    Control till here :2
    Here
    Control till here :3
    Control till here :4
    Control till here :5
    Control till here :6
    Cannot get connection: 1javax.naming.NamingException: String index out of range: -1
    returnValue1 null
    Can anyone please help me here.Many Thanks.
    Regards
    Kumar

    What is the full Java and os versions you are using to compile and to run. Note that with JDEV the platform used for your code may be different than the platform used by JDEV itself.
    Please modify all of your exception handlers to print the stack trace. Add this as the first line in each handler.
    ex.printStackTrace();The stacktrace contains important information about where the problem really occured.
    See the Java docs for NamingException - http://docs.oracle.com/javase/6/docs/api/javax/naming/NamingException.html
    >
    This is the superclass of all exceptions thrown by operations in the Context and DirContext interfaces. The nature of the failure is described by the name of the subclass. This exception captures the information pinpointing where the operation failed, such as where resolution last proceeded to.
    •Resolved Name. Portion of name that has been resolved.
    •Resolved Object. Object to which resolution of name proceeded.
    •Remaining Name. Portion of name that has not been resolved.
    •Explanation. Detail explaining why name resolution failed.
    •Root Exception. The exception that caused this naming exception to be thrown.

  • Jboss & Looking up DataSource from Client (not in Jboss)

    I have a project that will be describered as follows,
    1. Using Jboss server in which a DataSource is deployed
    2. Developing the Java client that looking up the above DataSource.
    My little problem is the java client is not deployed in Jboss, that is the normal java program. So can the client look up the DataSouce?
    Any help is appropriate!

    Actually I was wrong, and it makes sense why. This post is from
    David Jencks, if I recall he is the author of the JCA subsystem on jboss. This was his post on the jboss web-board (Had to look cause I tried it). I hope that you can develop some session facade beans to do whatever you would like. : )
    davidjencks
    Posts: 1,927
    Registered: Jun, 2001
    Re: Lookup DataSource from remote client      Posted: Apr 2, 2003 12:31 AM
    This is impossible and an extremely bad idea for numerous reasons.
    Write a session bean to do the db work, and call it from the remote clients.

  • Datasource properties????

    Hello, hopefully someone can help me with this one. First of all, what I am trying to do is set up a datasource to implement connection pooling. The datasource is being set up, using the following code....
    try {
                        java.util.Properties parms = new java.util.Properties();
                        parms.put(Context.INITIAL_CONTEXT_FACTORY,"com.ibm.ejs.ns.jndi.CNInitialContextFactory");
                        parms.put("user",dbUserName);
                        parms.put("password",dbPassword);
                        Context ctx = new InitialContext(parms);
                        ds = (DataSource)ctx.lookup("jdbc/DataSource Name");          
                        ctx.close();
                   } catch (Exception e) {}
    My problem arises when trying to get a connection to the datasource as I am being forced to use the getConnection(username, password) method and not the getConnection() method. Thus I think that connection pooling is not being implemented and a new connection is being obtained everytime. Please can someone shed some light on this for me.
    Thanks

    Properties h = new Properties();
    h.put(javax.naming.Context.PROVIDER_URL,"iiop://localhost:900");
    h.put(javax.naming.Context.INITIAL_CONTEXT_FACTORY,"com.ibm.ejs.ns.jndi.CNInitialContextFactory");
    initCtx = new InitialContext(h);
    DataSource ds = (javax.sql.DataSource)initCtx.lookup("<datasource-name>");
    java.sql.Connection conn = ds.getConnection();

Maybe you are looking for

  • Stupid slow lag with iTunes 11 on Windows7

    Before I mention anything else: - Running on Windows 7 64-bit with a 1.3GHz processor. My baby's getting old, but my only problems besides iTunes 11 in the past year was some lag playing Skyrim. - My iTunes library is tiny. We're talking less than 25

  • Need to incorporate a new field in J1IEX

    Hi, My requirement is I need add a Z field in the transaction code J1IEX. I really need to know the field exit which can be incorporated in the screen. Please help.

  • 10.5.1 - Can't boot at all from volume anymore

    Installed 10.5.1 onto my MacBook Pro using Software Update. Left my computer to eat some dinner. When I returned, my computer had auto-rebooted, but into Windows on my BootCamp partition. I tried to reboot into MacOS, but when I hold down alt/opt on

  • Adobe  - Failing to install - HELP!!!

    Hello. I am having trouble installing A. Reader 7.0 to my Dual Boot G4. After the loading bar has finished, a window appears with the following:- Adobe Reader was unable to install and must quit. I have also borrowed a friend's A. Professional 6.0 an

  • Data in iCloud inaccessible

    After upgrading to Mavericks all data kept in the iCloud drive (/Library/Mobile document) is invisible in the finder. Clicking on the map doesn't show any result. However, accessing one of the files via the recent file options in Excel or Word is pos