Weblogic connection pool fails

Hi
I am trying to connect to sqlserver using the weblogic connection pool from the
console.It throws me the following error inspite of adding the appropriate drivers
in the classpath.It works out really fine when connection to oracle database when
connecting to oracle it gives out :connection pool created, BUT WHEN TRYING TO
ACCESS THE SQLSERVER ..OOOhh.
anybody please immediate help is very much required and would be highly appreciated.
Thanks
Nov 1, 2001 9:18:40 AM EST> <Error> <JDBC> <Cannot startup connection pool "MessageLoggerDB"
weblogic.com
on.ResourceException:
ould not create pool connection. The DBMS driver exception was:
ava.sql.SQLException: I/O exception while talking to the server, java.io.EOFException:
TdsInputStream.rea
Fully - len 149 Unable to connect, please check your server's version and availability.
at weblogic.jdbc.mssqlserver4.TdsStatement.microsoftLogin(TdsStatement.java:2872)
at weblogic.jdbc.mssqlserver4.MicrosoftConnection.beginLogin(MicrosoftConnection.java:42)
at weblogic.jdbc.mssqlserver4.TdsConnection.login(TdsConnection.java:57)
at weblogic.jdbc.mssqlserver4.MicrosoftConnection.login(MicrosoftConnection.java:53)
at weblogic.jdbc.mssqlserver4.BaseConnection.prepareConnection(BaseConnection.java:187)
at weblogic.jdbc.mssqlserver4.Driver.newConnection(Driver.java:34)
at weblogic.jdbc.mssqlserver4.ConnectDriver.connect(ConnectDriver.java:151)
at weblogic.jdbc.common.internal.ConnectionEnvFactory.makeConnection(ConnectionEnvFactory.java:192

This looks like you're using the mssqlserver4v70 driver to connect to
an MS SQLServer 6.5. Is that the case?
Joe
Srini wrote:
>
Hi
I am trying to connect to sqlserver using the weblogic connection pool from the
console.It throws me the following error inspite of adding the appropriate drivers
in the classpath.It works out really fine when connection to oracle database when
connecting to oracle it gives out :connection pool created, BUT WHEN TRYING TO
ACCESS THE SQLSERVER ..OOOhh.
anybody please immediate help is very much required and would be highly appreciated.
Thanks
Nov 1, 2001 9:18:40 AM EST> <Error> <JDBC> <Cannot startup connection pool "MessageLoggerDB"
weblogic.com
on.ResourceException:
ould not create pool connection. The DBMS driver exception was:
ava.sql.SQLException: I/O exception while talking to the server, java.io.EOFException:
TdsInputStream.rea
Fully - len 149 Unable to connect, please check your server's version and availability.
at weblogic.jdbc.mssqlserver4.TdsStatement.microsoftLogin(TdsStatement.java:2872)
at weblogic.jdbc.mssqlserver4.MicrosoftConnection.beginLogin(MicrosoftConnection.java:42)
at weblogic.jdbc.mssqlserver4.TdsConnection.login(TdsConnection.java:57)
at weblogic.jdbc.mssqlserver4.MicrosoftConnection.login(MicrosoftConnection.java:53)
at weblogic.jdbc.mssqlserver4.BaseConnection.prepareConnection(BaseConnection.java:187)
at weblogic.jdbc.mssqlserver4.Driver.newConnection(Driver.java:34)
at weblogic.jdbc.mssqlserver4.ConnectDriver.connect(ConnectDriver.java:151)
at weblogic.jdbc.common.internal.ConnectionEnvFactory.makeConnection(ConnectionEnvFactory.java:192

Similar Messages

  • [原创] 有关Weblogic Connection Pool 连接恢复的问题

    这是一个古老的问题,一直困扰我,这里既然碰到了,就看看能不能解决。
    环境描述:
    WEBLOGIC版本是8.1 SP2,数据库是SQL SERVER 2000,分别部署在两个服务器上。
    第一步:
    问题描述:
    数据库服务器重新启动,导致WEBLOGIC 的CONNECTION POOL中的连接中断,EJB无法获得连接,导致应用出错。
    解决方法:
    进入WEBLOGIC ADMIN CONSOLE,
    Services->JDBC->Connection Pools->Config->Connections, 点开Advanced Options.
    打开 Test Reserved Connections ,Test Created Connections,Test Released Connections这三个选项。
    将Test Table Name属性设置为:sysproperties(SQL Server系统表,即使自己的应用不存在,这个表也存在,而且默认的内部没有数据)
    根据如下解释:
    Connections that fail the test are closed and reopened to re-establish a valid physical database connection.
    (You must specify a Test Table Name below.)
    每次调用首先进行测试连接,如果测试失败连接将重新建立。
    测试结果:
    WEBLOGIC启动后,关闭数据库SQL SERVER,应用服务器前端调用此时失败。
    重新启动SQL SERVER后,WEBLOGIC端略做等待,前端应用恢复正常。
    第二步:
    问题描述:
    进一步测试,如果WEBLOGIC先启动,启动完成后再启动数据库。
    在WEBLOGIC CONSOLE得到如下输出:
    <2006-3-22 上午11时50分08秒 GMT+08:00> <Warning> <JDBC> <BEA-001129> <Received exception while creating connection for p
    ool "MyJDBC Connection Pool": [Microsoft][SQLServer 2000 Driver for JDBC]Error establishing socket.>
    <2006-3-22 上午11时50分10秒 GMT+08:00> <Error> <JDBC> <BEA-001150> <Connection Pool "MyJDBC Connection Pool" deployment
    failed with the following error: 0:Could not create pool connection. The DBMS driver exception was: [Microsoft][SQLServe
    r 2000 Driver for JDBC]Error establishing socket..>
    <2006-3-22 上午11时50分10秒 GMT+08:00> <Error> <JDBC> <BEA-001151> <Data Source "MyJDBC Data Source" deployment failed w
    ith the following error: DataSource(jdbc/OMSEIITxDS) can't be created with non-existent Pool (connection or multi) (MyJD
    BC Connection Pool).>
    Unable to deploy EJB: XXXXXXX from XXXXXXX.jar:
    [EJB:011028]The DataSource with the JNDI name: jdbc/XXXXXX could not be located. Please ensure that the DataSource h
    as been deployed successfully and that the JNDI name in your EJB Deployment descriptor is correct.
    1、在默认初始化打开的连接一一失败以后,连接池发现可用的连接为0,郁闷的宣布自己部署失败。
    2、接着数据源发现没有可用的连接池,自己也宣布部署失败。
    3、下面所有的EJB发现不了数据源的JNDI名,部署也全部失败。
    应用启动完成后,大部分EJB的状态为INACTIVE。前端应用无法使用,此时启动数据库,前端应用无法使用。
    手动重新部署 EJB失败,错误还是找不到JNDI,前端应用无法使用。
    手动重新部署 连接池,数据源后,部署EJB 依然失败。前端应用无法使用。
    解决方法:
    进入WEBLOGIC ADMIN CONSOLE,
    Services->JDBC->Connection Pools->Config->Connections, 点开Advanced Options.

    Connection Creation Retry Frequency 参数设置为 60。
    ConnectionCreationRetryFrequencySeconds含义:
    当创建数据库连接时,如果数据库不可用(如数据库没启动),隔多长时间试着重新创建该连接,
    WLS8.1会每隔ConnectionCreationRetryFrequencySeconds秒重试一次.直到JDBC POOL创建成功
    参考:http://dev2dev.bea.com.cn/techdoc/20030469.html,‘JDBC Connect Pool’部分。
    英文解释可以直接控制台上看到,或者edocs查。
    测试结果:
    将数据库关闭,WEBLOGIC重新启动。
    在WEBLOGIC CONSOLE得到如下输出:
    打开Connection Creation Retry Frequency 参数后,连接池在第一轮尝试失败以后,就成功部署了,数据源也成功部署。
    EJB部署会失败,但是提示也与先前的不同:
    Unable to deploy EJB: XXXXXXX from XXXXXXX.jar:
    weblogic.common.resourcepool.ResourceLimitException: No resources currently available in pool MyJDBC Connection Pool to
    allocate to applications, please increase the size of the pool and retry..
    每隔一段时间会看到,CONNECTION POOL不断的重新进行连接:
    <2006-3-22 下午12时17分56秒 GMT+08:00> <Warning> <JDBC> <BEA-001129> <Received exception while creating connection for p
    ool "MyJDBC Connection Pool": [Microsoft][SQLServer 2000 Driver for JDBC]Error establishing socket.>
    在WEBLOGIC启动完成后,所有EJB为INACTIVE状态。
    启动数据库服务器,稍后,手动重新部署所有的EJB,EJB可以部署成功,前端应用可以正常使用。
    此时,此问题已经基本解决,仍需要手动部署EJB。
    第三步:
    问题描述:
    解决方法:
    有关部署次序的问题,首先查阅WEBLOGIC文档,http://edocs.bea.com/wls/docs81/faq/deploy.html#744900,得到
    WebLogic Server deploys server-level resources (first JDBC and then JMS) before deploying applications.
    Applications are deployed in this order: connectors, then EJBs, then Web Applications.
    If the application is an EAR, the individual components are loaded in the order in which they are declared
    in the application.xml deployment descriptor.
    WEBLOGIC先部署服务器端资源,JDBC -> JMS....,然后部署我们的应用,EJB->WEB APPLICATION。
    实际从WEBLOGIC启动日志来看,即使打开了Connection Creation Retry Frequency,如果当时数据库不是可用的,CONNECTION POOL
    会不断的调度CONNECTION进行重新连接。但是此时,EJB的部署也同时在进行。个人猜测这应该是两个不同的线程(组)分别调度的任务。
    现在考虑的是能不能用StartupClass截住EJB的部署过程,粗略的说是如果DATASOURCE没有连接好,或者没有可用的连接池,
    就不往下进行EJB部署的过程。
    参考:http://edocs.bea.com/wls/docs81/config_xml/EJBComponent.html#DeploymentOrder
    DeploymentOrder:
    A priority that the server uses to determine when it deploys an item. The priority is relative to other deployable
    items of the same type. For example, the server prioritizes and deploys all EJBs before it prioritizes and
    deploys startup classes.Items with the lowest Deployment Order value are deployed first.
    There is no guarantee on the order of deployments with equal Deployment Order values.
    There is no guarantee of ordering across clusters. Default: 1000 Minimum: 0 Maximum: 2N31-1
    在部署同一类应用时,按照 DEPLOYMENT LOADER的数值决定,数值越小越先。(EJB的参数在ADMIN CONSOLE界面上叫做LOAD ORDER)
    而且上面看来服务器是先部署EJB,再部署STARTUP CLASS,遗憾了。
    好在STARTUP CLASS上有两个选项,
    Run Before Application Deployments
    Run Before Application Activations
    这两个选项分别可以设置StartupClass分别在系统资源部署之前,以及在系统资源部署和用户应用部署之间启动。
    选上Run Before Application Activations。
    现在可以了,我写了一个STARTUP CLASS,思路见下:
    主代码:
    private void testConnection(){
    while (!isTimeout() && !getConnection()){
    try{
    Thread.sleep(testInterval*1000);
    }catch(Exception ignor){}
    log("DBConnectHolder job finished with following status:");
    log("Timeout:"+isTimeout +",Connection OK:"+isConnected);
    测试结果:
    只要配置的等待时间足够长,应用服务器先行启动的情况下,等待数据库启动后才进行EJB等等的部署。
    (主要考虑如果数据库连接不OK,EJB启动了也没有太大用,还得手工重新部署。)算是比较完满的解决了问题。
    另外一个思路是是否可行? 通过MBean, 在CONNECTION 建立起来以后通知一把,进行EJB的重新部署。
    没来得及研究,请有经验的同学帮我补充完善。
    结论:
    其实也没什么结论,只是把自己遇到问题,解决问题的思路写了一下。短时间内阅读的文献有限,可能采用了一些苯方法
    ,或者走了弯路,也请大家拍砖。
    在WL8版本上,数据库连接进行恢复和重新连接的时候,上面提出的几个参数应该是比较重要的,我再次强调一下。
    Services->JDBC->Connection Pools->Config->Connections, 点开Advanced Options.
    Test Reserved Connections
    Test Created Connections
    Test Released Connections
    Test Table Name
    Connection Creation Retry Frequency

    在第一个情景中应该只需要打开Test Reserved Connections 就可以了。
    Test Created Connections表示创建连接后放到pool之前进行测试看连接是否可用
    Test Released Connections表示释放连接回到pool之前进行测试看连接是否可用
    I think so!

  • ClassCastException while asting ResultSet to OracleResultSet. Using weblogic connection pool

    Hi,
    I am using weblogic server 5.1 and connection pools for accessing Oracle database.
    We wanted to use BLOB in oracle and I coded the java class to insert data into BLOB
    field.
    When I code a sample calss without using weblogic pool, I do not have any problem.
    But when I use the weblogic connection pool, I get classcastException as described
    below:
    I am using
    "insert into shipmentCorrection (" + insfields + ") VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,empty_blob())"
    to insert a dummy record with empty_blob and then getting the BLOB locater by the
    following code:
    java.sql.ResultSet rset = stmt.executeQuery ("SELECT zipped_pdf FROM shipmentCorrection
    WHERE shipment_id ='"+ ShipmentId + "' and correction_num ="+ CorrectionNum +" and
    Bl_Type = '"+ blType +"'" );
    rset.next();
    BLOB blob = ((OracleResultSet)rset).getBLOB(1);
    java.io.OutputStream outstream = blob.getBinaryOutputStream();
    IN the above line of code where I cast the ResultSet to OracleResultSet, I get the
    classcastException as follows:
    I donno how to solve this problem. Could any one please help me on this ?
    java.lang.ClassCastException: weblogic.jdbc.pool.ResultSet
    at fmweb.SQL.PdfDataSQL.insertPdfData(PdfDataSQL.java:347)
    at fmweb.framework.ShipmentManagerImpl.insertPdfData(ShipmentManagerImpl
    .java:2471)
    at fmweb.framework.ShipmentManager_WLSkel.invoke(ShipmentManager_WLSkel.
    java:1316)
    at weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(BasicServerOb
    jectAdapter.java:347)
    at weblogic.rmi.extensions.BasicRequestHandler.handleRequest(BasicReques
    tHandler.java:69)
    at weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest
    .java:15)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:135)
    Thanks,
    Muralidaran Chakravarthy

    When using weblogic pool drivers it is not possible to cast to an Oracle
    JDBC driver, (or any other driver )
    pool driver hides the driver you have configured.
    "Muralidaran Chakravarthy" <[email protected]> wrote in message
    news:3ce16855$[email protected]..
    >
    Hi,
    I am using weblogic server 5.1 and connection pools for accessing Oracledatabase.
    We wanted to use BLOB in oracle and I coded the java class to insert datainto BLOB
    field.
    When I code a sample calss without using weblogic pool, I do not have anyproblem.
    But when I use the weblogic connection pool, I get classcastException asdescribed
    below:
    I am using
    "insert into shipmentCorrection (" + insfields + ") VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,empty_blob())"
    >
    to insert a dummy record with empty_blob and then getting the BLOB locaterby the
    following code:
    java.sql.ResultSet rset = stmt.executeQuery ("SELECT zipped_pdf FROMshipmentCorrection
    WHERE shipment_id ='"+ ShipmentId + "' and correction_num ="+CorrectionNum +" and
    Bl_Type = '"+ blType +"'" );
    rset.next();
    BLOB blob = ((OracleResultSet)rset).getBLOB(1);
    java.io.OutputStream outstream = blob.getBinaryOutputStream();
    IN the above line of code where I cast the ResultSet to OracleResultSet, Iget the
    classcastException as follows:
    I donno how to solve this problem. Could any one please help me on this ?
    java.lang.ClassCastException: weblogic.jdbc.pool.ResultSet
    at fmweb.SQL.PdfDataSQL.insertPdfData(PdfDataSQL.java:347)
    atfmweb.framework.ShipmentManagerImpl.insertPdfData(ShipmentManagerImpl
    java:2471)
    atfmweb.framework.ShipmentManager_WLSkel.invoke(ShipmentManager_WLSkel.
    java:1316)
    atweblogic.rmi.extensions.BasicServerObjectAdapter.invoke(BasicServerOb
    jectAdapter.java:347)
    atweblogic.rmi.extensions.BasicRequestHandler.handleRequest(BasicReques
    tHandler.java:69)
    atweblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest
    java:15)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:135)
    Thanks,
    Muralidaran Chakravarthy

  • Problem in retriving varray when using weblogic connection pool

    Hi,
         I had similar problem when we I am using the weblogic connection pool. I had similar setup i.e weblogic 5.1 servicepack9 and oracle 8.1.7.
    I cofigarud the weblogic connection pool using Oracle thin driver.
    But if I am using with oracle thin driver directly I am able to retrive.
    If any one know how to retrive varray from procedure using weblogic connection pool please send me it.
    Thanx.
    Bye,
    Satya

    http://docs.oracle.com/javase/6/docs/api/java/sql/Connection.html#setAutoCommit(boolean)

  • Weblogic Connection pool active even database listener down

    Just wanted to check if sometime noticed this.
    Today.. In production our Database listener was down and connection pools in weblogic were still working fine. But, when tried making a explicit call to DB it throws exception "The Network Adapter could not establish the connection"..
    Couple of days back our production database was restarted. Sill weblogic connection pool was active without restart.
    Any info. is appreciate..
    Thanks

    Hi Jung,
    There is no timeout current that you can set on the connection pool. It will
    be in a future release of WebLogic
    sree
    "Jung Yang" <[email protected]> wrote in message
    news:[email protected]..
    Thanks.
    Yes I know that part.
    However, I still would like to know how to get time out settings andchange
    if I can.
    Where can I do that?
    - jung
    "Sree Bodapati" <[email protected]> wrote in message
    news:[email protected]..
    set TestConnectionsOnReserve="true" in the pool and you should be all
    set.
    >>
    sree
    "Jung Yang" <[email protected]> wrote in message
    news:[email protected]..
    I am currently using WLS 6.0 SP2 RP2 with jdbc thin oracle driver.
    What is the timeout setting on weblogic connection pool?
    I would like to set max number of seconds waiting for reply to connect
    to
    a
    database so that it does not wait too long before realizing that it isdown.
    Also if there is a setting that can be configured, is it jdbc api
    implementation or weblogic specific?
    Thanks in advance.

  • Connection pool fail

    Hi, guys
    I use instant client 11.2.0.3.0 OCCI to create a connection pool, when create a connection from pool, it supposed using the existing connection, but the code created anohter new connection to database, any ideas? appreciate your help.
    client side is running on Windows 7 32 bit, Database server is 10.2.05 on Solaris 10, development tool is MS VS 2010
    here is the code:
    Environment *env;
    Connection *conn;
    Statement *stmt;
    string sqlStmt;
    env = Environment::createEnvironment (Environment::THREADED_MUTEXED);
    const string poolUserName = "scott";
    const string poolPassword = "1234";
    const string connectString = "192.168.0.70/orcl";
    const string username = "scott";
    const string passWord = "1234";
    unsigned int maxConn =5;
    unsigned int minConn = 2;
    unsigned int incrConn = 1;
    ConnectionPool *connPool = env->createConnectionPool(poolUserName, poolPassword, connectString, minConn, maxConn, incrConn);
    try{
    if (connPool)
    cout << "SUCCESS - createConnectionPool" << endl;
    else
    cout << "FAILURE - createConnectionPool" << endl;
    conn = connPool->createConnection (username, passWord); _// after this code, connection increase to 3 from 2._*
    if (conn)
    cout << "SUCCESS - createConnection" << endl;
    else
    cout << "FAILURE - createConnection" << endl;
    }catch(SQLException ex)
    cout<<"Exception thrown for createConnectionPool"<<endl;
    cout<<"Error number: "<< ex.getErrorCode() << endl;
    cout<<ex.getMessage() << endl;
    ......

    Hi Nicolas,
    Have you tried to turn on testOnReserve setting of the coneection pool?
    Regards,
    "Nicolas Devos" <[email protected]> wrote in message
    news:3c5fa916$[email protected]..
    >
    Hi,
    I am using weblogic 6.1 and oracle 8.1.6, and experiences
    problems with connections pools and database crash.
    When the database server crashes during an EJB transactions,
    the connection used by that transaction seems to be lost and
    is never rebuilt when the database server restarts, therefore
    the number of connections within the pool shrinks thoroughly
    if I have several connections used while the database crashes
    or is shutdown for maintenance.
    If this db crash takes time to recover, all connections
    are destroyed and the pool become unusable.
    As soon as all connections have been 'destroyed' I have
    the following exception:
    'connection pool - none available' when trying to get
    a connection.
    When I restart the database server, the pool does not rebuilt
    itself.
    (I am using a test table to test the presence of the database
    with a frequency set to 60s)
    I did the same operation without EJB transactions and the pool
    could rebuilt itself after the database has been restarted.
    I had that problem with weblogic 6.0 already and in the
    release notes of 6.0_sp2, 2 issues are fixed concerning
    the pool fail-over: 044223 and 041793.
    I would like to know if these issues are fixed in 6.1 as well,
    and if they are related to my problem (Their description is
    quite short).
    Thank you
    Nicolas

  • Dynamic Connection Pool fails in WLS 6.1

    Hi all,
    I am trying to create the connection pool dynamically but it fails saying " Error
    to load the Driver"
    Snippet Code --
    Hashtable env = new Hashtable();
    env.put(Context.INITIAL_CONTEXT_FACTORY,
    "weblogic.jndi.WLInitialContextFactory");
    // URL for the WebLogic Server
    env.put(Context.PROVIDER_URL, "t3://localhost:7001");
    env.put(Context.SECURITY_PRINCIPAL, "Fred");
    env.put(Context.SECURITY_CREDENTIALS, "secret");
    Context ctx = new InitialContext(env);
    // Look up weblogic.jdbc.JdbcServices
    weblogic.jdbc.common.JdbcServices jdbc =
    (weblogic.jdbc.common.JdbcServices)
    ctx.lookup("weblogic.jdbc.JdbcServices");
    String thePoolName = "eng2";
    Properties poolProps = null;
    Pool myPool = null;
    weblogic.jdbc.common.Pool pool = null
    poolProps = new Properties();
    // Set properties for the ConnectionPool.
    poolProps.put("poolName", thePoolName);
    poolProps.put("url", "jdbc:weblogic:demo");
    poolProps.put("driver", "COM.cloudscape.core.JDBCDriver");
    poolProps.put("props", "user=scott;password=tiger;server=demo");
    poolProps.put("initialCapacity", "1");
    poolProps.put("maxCapacity", "10");
    poolProps.put("capacityIncrement", "1");
    poolProps.put("aclName", "dynapool");
    poolProps.put("allowShrinking", "true");
    poolProps.put("shrinkPeriodMins", "5");
    poolProps.put("refreshPeriod", "10");
    poolProps.put("testConnOnReserve", "true");
    poolProps.put("testConnOnRelease", "false");
    poolProps.put("testTableName", "dual");
    poolProps.put("loginDelaySecs", "1");
    // create our pool
    try {
    myJdbc.createPool(poolProps);
    } catch (Exception e) {
    System.out.println(thePoolName
    + " can't be created ..");
    System.exit(666);
    Any Help will be appreciated in creating the dynamic connection pool in WLS 6.1 SP2
    Regards,
    Bala

    Bala wrote:
    Hi joe,
    Any how let me want to create the Connections Pool Dynamically in WLS 6.1 .Pls
    give some ideas / ways to proceeed further
    Thx
    BalaFirst I need the answer to my question:
    Hi. Can the same pool be created as a startup pool?
    (Ie: does it succeed?)
    Joelet me know...
    Joe
    >
    >>
    Bala wrote:
    Hi all,
    I am trying to create the connection pool dynamically but it fails saying" Error
    to load the Driver"
    Snippet Code --
    Hashtable env = new Hashtable();
    env.put(Context.INITIAL_CONTEXT_FACTORY,
    "weblogic.jndi.WLInitialContextFactory");
    // URL for the WebLogic Server
    env.put(Context.PROVIDER_URL, "t3://localhost:7001");
    env.put(Context.SECURITY_PRINCIPAL, "Fred");
    env.put(Context.SECURITY_CREDENTIALS, "secret");
    Context ctx = new InitialContext(env);
    // Look up weblogic.jdbc.JdbcServices
    weblogic.jdbc.common.JdbcServices jdbc =
    (weblogic.jdbc.common.JdbcServices)
    ctx.lookup("weblogic.jdbc.JdbcServices");
    String thePoolName = "eng2";
    Properties poolProps = null;
    Pool myPool = null;
    weblogic.jdbc.common.Pool pool = null
    poolProps = new Properties();
    // Set properties for the ConnectionPool.
    poolProps.put("poolName", thePoolName);
    poolProps.put("url", "jdbc:weblogic:demo");
    poolProps.put("driver", "COM.cloudscape.core.JDBCDriver");
    poolProps.put("props", "user=scott;password=tiger;server=demo");
    poolProps.put("initialCapacity", "1");
    poolProps.put("maxCapacity", "10");
    poolProps.put("capacityIncrement", "1");
    poolProps.put("aclName", "dynapool");
    poolProps.put("allowShrinking", "true");
    poolProps.put("shrinkPeriodMins", "5");
    poolProps.put("refreshPeriod", "10");
    poolProps.put("testConnOnReserve", "true");
    poolProps.put("testConnOnRelease", "false");
    poolProps.put("testTableName", "dual");
    poolProps.put("loginDelaySecs", "1");
    // create our pool
    try {
    myJdbc.createPool(poolProps);
    } catch (Exception e) {
    System.out.println(thePoolName
    + " can't be created ..");
    System.exit(666);
    Any Help will be appreciated in creating the dynamic connection pool inWLS 6.1 SP2
    Regards,
    Bala

  • Connect to WebLogic connection pool externally?

    Running Oracle 8i (thin driver) & WL 5.1
    I can connect directly to the db using
    public class TestDB
         String dbURL = "jdbc:oracle:thin:@p1900:1521:p1900";
         String dbDriver = "oracle.jdbc.driver.OracleDriver";
         public boolean connect()
         Class.forName(this.getDbDriver());
         System.err.println("Driver load ok");
         dbConn = DriverManager.getConnection(this.getDbURL());
         System.err.println("Connected ok");
    return true;
    but is it possible to connect to WL connection pool from a program
    thats not within the WL server (i.e no problem from a servlet)?
    This is from weblogic.properties -
    weblogic.jdbc.connectionPool.hazardouswaste=\
    url=jdbc:oracle:thin:@p1900:1521:p1900,\
    driver=oracle.jdbc.driver.OracleDriver,\
    initialCapacity=1,\
    maxCapacity=1,\
    capacityIncrement=1,\
    props=user=tact_dev;password=tact_dev,\
    allow=guest
    How can I get a conection from the hazardouswaste connection pool?
    I've tried this but it
    String dbURL = "jdbc:weblogic:pool:hazardouswaste";
    String dbDriver = "weblogic.jdbc.pool.Driver";
    I keep getting this -
    return getDbURL - jdbc:weblogic:pool:hazardouswaste
    java.sql.SQLException: Pool connect failed: null
    at weblogic.jdbcbase.pool.Driver.connect(Driver.java:184)
    at java.sql.DriverManager.getConnection(DriverManager.java:517)
    at java.sql.DriverManager.getConnection(DriverManager.java:199)
    at jsp_servlet.TestDB.connect(TestDB.java:62)
    at jsp_servlet.Test.main(Test.java:16)
    Any ideas
    harry

    [att1.html]

  • Issues with Weblogic connection pool creation

    Hi,
    I need to create a Connection pool in weblogic to access a mdb file(MS Access) .
    Iam not able to see any precoded drivers in weblogic for accessing MS Access.
    Let me know if anyone has details on this.
    Thanks.

    I tried this one and this seems to be a trial version.
    Are there any free apis available? In case there are any other way do let me know.
    Thanks.

  • Error While reading CLOB from Oracle using WebLogic Connection Pool, Works fine with out using pool

    PROBLEM DESCRIPTION :
         When I try to read a clob from Oracle, I receive "ORA-03120: two-task
    conversion routine: integer overflow" Error.
         This error occurs only for CLOB Type and only if I try to connect to
    Oracle using WebLogic JDriver/Oracle POOL.
         IMPORTANT NOTE: I can read CLOB or any other data using direct JDBC
    connection to ORacle with out any problem.
         Below Please find the JAVA CODE for Both Working and NON Working .
    Created a Connection Pool as:
    Name: MyJDBCConnectionPool
    URL : jdbc:weblogic:oracle
    DIRVER:weblogic.jdbc.oci.Driver
    NON WORKING JAVA CODE (USES WEBLOGIC JDBC CONNECTION POOL TO ORACLE):
    Driver myDriver =
    (Driver)Class.forName("weblogic.jdbc.pool.Driver").newInstance();
    Connection mconn =
    myDriver.connect("jdbc:weblogic:pool:MyJDBCConnectionPool",null);
    mconn.setAutoCommit (false);
    CallableStatement cs = mconn.prepareCall("{call
    P_XMLTEST2(?)}"); //This returns a CLOB
    cs.registerOutParameter(1,java.sql.Types.CLOB);
    cs.execute();
    Clob clob = null;
    clob = cs.getClob(1);
    String data =new String();
    data = clob.getSubString(1, (int)clob.length());
    System.out.println(data); //print the data
    data = null;
    clob=null;
    cs.close();
    WORKING JAVA CODE (USES DIRECT THIN JDBC CONNECTION TO ORACLE):
    Driver myDriver =
    (Driver)Class.forName("oracle.jdbc.driver.OracleDriver").newInstance();
    Connection mconn =
    myDriver.connect("jdbc:oracle:thin:@server:1521:DB",null);
    mconn.setAutoCommit (false);
    CallableStatement cs = mconn.prepareCall("{call
    P_XMLTEST2(?)}"); //This returns a CLOB
    cs.registerOutParameter(1,java.sql.Types.CLOB);
    cs.execute();
    Clob clob = null;
    clob = cs.getClob(1);
    String data =new String();
    data = clob.getSubString(1, (int)clob.length());
    System.out.println(data); //print the data
    data = null;
    clob=null;
    cs.close();
    ERROR MESSAGE:
         ORA-03120: two-task conversion routine: integer overflow
    I appreciate your help on this problem.

    PROBLEM DESCRIPTION :
         When I try to read a clob from Oracle, I receive "ORA-03120: two-task
    conversion routine: integer overflow" Error.
         This error occurs only for CLOB Type and only if I try to connect to
    Oracle using WebLogic JDriver/Oracle POOL.
         IMPORTANT NOTE: I can read CLOB or any other data using direct JDBC
    connection to ORacle with out any problem.
         Below Please find the JAVA CODE for Both Working and NON Working .
    Created a Connection Pool as:
    Name: MyJDBCConnectionPool
    URL : jdbc:weblogic:oracle
    DIRVER:weblogic.jdbc.oci.Driver
    NON WORKING JAVA CODE (USES WEBLOGIC JDBC CONNECTION POOL TO ORACLE):
    Driver myDriver =
    (Driver)Class.forName("weblogic.jdbc.pool.Driver").newInstance();
    Connection mconn =
    myDriver.connect("jdbc:weblogic:pool:MyJDBCConnectionPool",null);
    mconn.setAutoCommit (false);
    CallableStatement cs = mconn.prepareCall("{call
    P_XMLTEST2(?)}"); //This returns a CLOB
    cs.registerOutParameter(1,java.sql.Types.CLOB);
    cs.execute();
    Clob clob = null;
    clob = cs.getClob(1);
    String data =new String();
    data = clob.getSubString(1, (int)clob.length());
    System.out.println(data); //print the data
    data = null;
    clob=null;
    cs.close();
    WORKING JAVA CODE (USES DIRECT THIN JDBC CONNECTION TO ORACLE):
    Driver myDriver =
    (Driver)Class.forName("oracle.jdbc.driver.OracleDriver").newInstance();
    Connection mconn =
    myDriver.connect("jdbc:oracle:thin:@server:1521:DB",null);
    mconn.setAutoCommit (false);
    CallableStatement cs = mconn.prepareCall("{call
    P_XMLTEST2(?)}"); //This returns a CLOB
    cs.registerOutParameter(1,java.sql.Types.CLOB);
    cs.execute();
    Clob clob = null;
    clob = cs.getClob(1);
    String data =new String();
    data = clob.getSubString(1, (int)clob.length());
    System.out.println(data); //print the data
    data = null;
    clob=null;
    cs.close();
    ERROR MESSAGE:
         ORA-03120: two-task conversion routine: integer overflow
    I appreciate your help on this problem.

  • What about session memory when using BEA Weblogic connection pooling?

    Hi,
    consider a web application, allowing database connections via a BEA Weblogic 8.1 application server. The app-server is pooling the oracle connections. The oracle database is running in dedicated server mode.
    How are the database requests from the web app served by the connection pool from BEA?
    1) Does one oracle session serve more than one request simultanously?
    2) Does BEA serialize the requests, which means, that a session from the pool is always serving only one request at a time?
    If (1) is true, than what about the session memory of Oracle sessions? I understand, that things like package global variables are beeing stored in this session private memory. If (1) is true, the PL/SQL programmer has the same situation, as with programming an Oracle databas in "shared server" mode, that is, he should not use package global variables etc.
    Thankful for any ideas...
    Message was edited by:
    Xenofon

    Xenofon Grigoriadis wrote:
    Hi,
    consider a web application, using BEA between client and an Oracle Database (v9i). BEA is pooling the oracle connections. The oracle database is running in dedicated server mode.
    How are the database requests from the web app beeing served by the connection pool from BEA?
    1) Does one oracle session serve more than one request simultanously?no.
    2) Or does BEA serialize the requests, which means, that a session from the pool is always serving only one request at a time?
    Reading "Configuring and Using WebLogic JDBC" from weblogic8.1 documentation, I read:
    "... Your application "borrows" a connection from the pool, uses it, then returns it to the pool by closing it...."
    What do you mean by returning the connection by closing it? Tbe server will either return the connection to the pool or close it...When application code does typical jdbc code, it obtains
    a connection via a WebLogic DataSource, which reserves an
    unused pooled connection and passes it (transparently wrapped)
    to the application. The application uses it, and then closes
    it. WebLogic intercepts the close() call via the wrapper, and
    puts the DBMS connection back into the WebLogic pool.
    The reason, why I as an Oracle programmer ask this is, because every session (=connection)
    in Oracle has its own dedicate, private memory for things like global PL/SQL variables.
    Now I want to figure out, if you have to careful in programming your databases, when
    one Oracle session (=connection) is serving many weblogic requests.It is serving many requests, but always serially. Do note however, that we
    also transparently cache/pool prepared and callable statements with the
    connection so repeat uses of the connection will be able to get already-made
    statements when they call prepareStatement() and prepareCall(). These
    long-lived statements will each require a DBMS-side cursor.
    >
    Thankful for any ideas or practical experience...
    Message was edited by:
    mk637Joe

  • WebLogic 11g data source connection pooling failed with IO error:socket read timed out.

    Hi all,
    We encountered IO Error: Socket read timed out( <Received exception while creating connection for pool "DS_1": IO Error: Socket read timed out> ) during the creation of data sources in WebLogic 11g. Manual data source testing seems to indicate intermittent connection and the server seems to take a long time to start up with multiple IO errors. We increased the timeout at the database side but it does not seems to help. The database is 11g (11.2.0.3). The database services and listener are up which does not indicate that the database instance is down.

    This particular error means your database is down and socket is timedout. Or the query takes so long that the reader timedout -- unlikely.
    Also, the general weblogic socket write errors, which you might see sometimes means that the client got disconnected before the server wrote results back. This is harmless

  • Weblogic 9.2 - Problem with Connection Pool not releasing resources

    We have a third party application that is running Weblogic 9.2 and has a connection pool to a SQL 2005 db for queries within it's batch process. What I have noticed is that it does not seem to be releasing SQL cpu back after the batch and this is causing issues with processes for other dB's within the instance. Has anyone encountered this issue and if so what is the solution (short of isolating it within it's own instance). Can the connection be reset to release resources?

    Yes it is a weblogic connection pool. What I mean is that when a batch run I can see the CPU for the SQL process associated with the connection increase but when the batch is completed the CPU remains high when I would expect it to move back down to an 'idle' level as after that as all it would be doing is the occasional "select 1' ping to keep the connection active.
    What i do see is that the cpu in activity monitor shows high cpu and it never goes down unless the connection is killed and re-established. As this is a shared instance other apps are complaining of slow running procs.

  • What jar contains weblogic.jdbc.pool.Driver connection pool class?

    Hi all,
    I am trying to use the JDeveloper IDE to generate code that I'll deploy on WebLogic
    6.1.
    I want to add the necessary files to the JDeveloper classpath so that during development
    it can use my
    weblogic connection pool. I've looked all over and can't seem to find it. It's
    not in weblogic.jar. Anyone know
    what file contains weblogic.jdbc.pool.Driver?
    Thanks in advance,
    Norm

    Thanks. I don't know how I missed it in the first place.
    "Sree Bodapati" <[email protected]> wrote:
    weblogic.jar
    sree
    "Norm Heske" <[email protected]> wrote in message
    news:3ba246c2$[email protected]..
    Hi all,
    I am trying to use the JDeveloper IDE to generate code that I'll deployon
    WebLogic
    6.1.
    I want to add the necessary files to the JDeveloper classpath so thatduring development
    it can use my
    weblogic connection pool. I've looked all over and can't seem to findit.
    It's
    not in weblogic.jar. Anyone know
    what file contains weblogic.jdbc.pool.Driver?
    Thanks in advance,
    Norm

  • Configure Database Connection to Weblogic 8.1 Connection Pool

    Hi,
    I've got an ADF BC web application which is working find for an embedded JDBC Oracle Database connection. It's Jdeveloper 10.1.2 deployed to Weblogic 8.1.
    Now I'm trying to change the Database connection so it can point to a weblogic connection pool through its JNDI name. The goal is to make .ear file transportable through different weblogic domains and databases, without recompile application.
    I've been trying to configure an "OracleConnectionPoolDataSource" selecting "third party driver" in Database connection wizard, but Jdeveloper throws error: Java Cast Exception, and don't let continue. What else have to do?
    thanks.

    I did that, but WebLogic ignores whatever I configure in Services->JDB->Connection Pools and Data Sources. Even if I remove them the application keeps on running.
    Because the server only reads the connection defined from JDeveloper, which is configured in the connections.xml file placed inside the deployed .ear file.
    I need to change this behaviour, and configure connections.xml pointing to Weblogic Datasource.
    Thanks for your attention.

Maybe you are looking for

  • Why does Adobe Reader XI (11.0.4.63) keeps crashing in Win7?

    After a few seconds after opening a PDF document or launching the application, it crashes and provides the error below. I've already uninstallaed and reinstalled the application but the same thing happens. I also followed the step in the community di

  • How to disable printing and emailing from a specific pdf in iBooks?

    I need to prevent the iPad user to print or email a pdf published in iBooks. Thanks for your help!

  • I need the list of Topics in SAP XI

    Hi To All, I Need the list of topics in SAP XI will you please send the list of topics... Thanks & Regards Satish Patnaik

  • Rotate in Slideshow

    I'd like to be able to use an auto-advance slideshow for reviewing my photos. I've got one set up, and from it I can add star ratings to the images as I see them. However, the rotate keys don't work. Instead, they rotate the currently selected pictur

  • Upgrade to 3.1.1 broke drag and drop form items

    after upgrading to 3.1.1 when I click the drag and drop icon in items on a form i can then move the fields around and when I hit next the page shows no fields, if I then click apply and look at the form the fields have not moved..