DB connections from oc4j app

Hi!
I'd like to verify if our app (configured by other company) is configured properly.
We should handle 2000-4000 of users, and I was told that each user uses db connection.
In oc4j data-sources.xml I have:
<data-source name="WebAppDataSource" location="jdbc/core/WebAppDataSource" class="com.evermind.sql.DriverManagerDataSource" ejb-location="jdbc/WebAppDataSource" xa-location="jdbc/xa/WebAppDataSource" pooled-location="jdbc/pool/WebAppDataSource" connection-driver="oracle.jdbc.driver.OracleDriver" username="app_portal" url="jdbc:oracle:thin:@10.10.10.4:1521:mydb" min-connections="50" max-connections="500" password="portal_03" inactivity-timeout="60" wait-timeout="10"/></data-sources>
So - at startup (currently 20 processes of oc4j) i got 1000 db connections (and 1000 db processes), but on heavy load (>1000 clients on the same time) it raises to more than 100 conns. per process. A lot of...
In addition our app was configured to use connection pooling (to reduce db coonections amount), and in oc4j.properties we have:
oracle.home=/u01/oas10g
jbo.ampool.initpoolsize=100
jbo.ampool.maxpoolsize=300
jbo.recyclethreshold=250
jbo.ampool.maxavailablesize=250
jbo.ampool.minavailablesize=250
jbo.ampool.maxinactiveage=1500
jbo.dofailover=true
jbo.maxpoolsize=300
jbo.doconnectionpooling=true
Could someone tell me whether using such config files makes any sense?
Regards
Rafal

In my experience I think you would want to have a managed data source setup to allow the application server to manage the pool. Based on the data-source.xml you provided, this doesn't look like it is configured for that.
also the driver class to use for a pooled data source should be: oracle.jdbc.pool.OracleDataSource
I would think it should be structured like:
<?xml version = '1.0' encoding = 'UTF-8'?>
<data-sources>
<managed-data-source connection-pool-name="Pool_WebAppDataSource" jndi-name="WebAppDataSource" name="WebAppDataSource"/>
<managed-data-source connection-pool-name="Pool_WebAppDataSource" jndi-name="jdbc/core/WebAppDataSource" name="jdbc/core/WebAppDataSource" />
<managed-data-source connection-pool-name="Pool_WebAppDataSource" jndi-name="jdbc/WebAppDataSource" name="jdbc/WebAppDataSource" />
<managed-data-source connection-pool-name="Pool_WebAppDataSource" jndi-name="jdbc/xa/WebAppDataSource" name="jdbc/xa/WebAppDataSource" />
<connection-pool name="Pool_WebAppDataSource" connection-retry-interval="0" inactivity-timeout="60" wait-timeout="10" min-connections="50" max-connections="500" property-check-interval="30" validate-connection="true" validate-connection-statement="select 1 from dual">
<connection-factory factory-class="oracle.jdbc.pool.OracleDataSource" username="app_portal" password="portal_03" url="jdbc:oracle:thin:@10.10.10.4:1521:mydb" />
</connection-pool>
</data-sources>

Similar Messages

  • How to configure database connectivity in OC4J App server.

    Hi,
    I am working on Oracle ESB flows. I have the flow inserting rows into database table using database connection that I have defined. I havent set up connection settings in OC4J EM console.
    I dont wonder when JDeveloper is inserting rows into tables, as connection is explicitely defined in JDeveloper.
    Now I login to EM enviroment and click on Home, click on Web Services tab, and when I use this flow as a Web Service end point and feed values through the form that it provided, it also works. But since I havent defined any connection properties in App Server explicitely, I wonder where is it getting connection properties(JNDI name) from.
    I want to configure some settings in Testing Environment and am kind of stuck at this point.
    Thanks,

    Hi.
    When you don't have JNDI configured, OC4J uses the design time connection defined in the Adapter's WSDL. Look for the following description in your Adapter WSDL:
    <!-- Your runtime connection is declared in
    J2EE_HOME/application-deployments/default/DbAdapter/oc4j-ra.xml
    These 'mcf' properties here are from your design time connection and
    save you from having to edit that file and restart the application server
    if your JNDI is missing.
    These 'mcf' properties are safe to remove.
    -->
    Now, for JNDI configuration, you can use the SOA Suite tutorial as a reference:
    http://download.oracle.com/docs/cd/B31017_01/core.1013/b28937/setting_up.htm#CIHBHEFC
    There you can find the steps to create a connection pool, data source, etc.
    Denis

  • Connect from VB APP to Oracle 9i

    We had VB app that was connected to Oracle 8i.
    We had Our Forms C/S app running on the users machine.
    I downloded ODBC drivers for Oracle and was able to connect the VB APP to Oracle 8i.
    Now we have forms 10g and so there is no SQL NET installed on the users machine.
    How do I make the VB APP talk to the databse.
    I tried installing only SQL NET from Forms 10g CD and it had no custom install. Either its all or none.
    Any input will be greatly appreciated.

    Forms 6i is the last release that has client/server runtime suopport. Oatch 16 is certified against an Oracle 10g database.
    Frank

  • Problem to get Connection from JBoss AS

    PLEASE HELP ME....
    I GOT ERROR WHILE I TRYED TO GET A CONNECTION FROM JBOSS APP. SERVER.
    THE CODE IS
    package com.beo.atlas.common;
    public final class ServiceLocator     {
         private static final String JBOSS_INITIAL_CONTEXT_FACTORY = "org.jnp.interfaces.NamingContextFactory";
         private static final String JBOSS_PROVIDER_URL = "localhost:8080";
         private static final String JBOSS_URL_PKG_PREFIXES = "org.jboss.naming:org.jnp.interfaces";
         public static final String ATLAS_DATASOURCE = "java://myatlasdbpool";
         private static java.util.Hashtable dataSourceCache = null;
         private static ServiceLocator locator = null;
         static     {
              System.out.println("Locator Initializing");
              dataSourceCache = new java.util.Hashtable();
              locator = new ServiceLocator();
         private ServiceLocator()     {     }
         public static ServiceLocator newInstance()     {
              System.out.println("Returning the Locator Object");
              return locator;
         public java.sql.Connection getDBConnection() throws java.sql.SQLException,javax.naming.NamingException     {
              System.out.println("Getting Data base Connection....");
              if(dataSourceCache.containsKey(ATLAS_DATASOURCE))     {
                   System.out.println("Trying to get Connection from CACHE...");
                   System.out.println("Returning Connection Object from cache.");
                   return (java.sql.Connection)dataSourceCache.get(ATLAS_DATASOURCE);
              System.out.println("FAILED to get Connection from CACHE");
              System.out.println("Trying to create new Connection...");
              java.util.Properties props = new java.util.Properties();
              props.put(javax.naming.Context.INITIAL_CONTEXT_FACTORY,JBOSS_INITIAL_CONTEXT_FACTORY);
              props.put(javax.naming.Context.PROVIDER_URL,JBOSS_PROVIDER_URL);
              props.put(javax.naming.Context.URL_PKG_PREFIXES, JBOSS_URL_PKG_PREFIXES );
              javax.naming.InitialContext context = new javax.naming.InitialContext(props);
              Object o = context.lookup(ATLAS_DATASOURCE);
              System.out.println("Object Created...");
              javax.sql.DataSource dataSource = null;
              try     {
              dataSource = (javax.sql.DataSource)javax.rmi.PortableRemoteObject.narrow(o,javax.sql.DataSource.class);
              }catch(Exception e)     {     
              java.sql.Connection con = dataSource.getConnection();
              dataSourceCache.put(ATLAS_DATASOURCE,con);
              System.out.println("Returning new Connection Object.");
              return con;          
    ERROR
    Locator Initializing
    Returning the Locator Object
    Getting Data base Connection....
    FAILED to get Connection from CACHE
    Trying to create new Connection...
    Object Created...
    java.lang.ClassCastException
    at com.sun.corba.se.impl.javax.rmi.PortableRemoteObject.narrow(Unknown S
    ource)
    at javax.rmi.PortableRemoteObject.narrow(Unknown Source)
    at com.beo.atlas.common.ServiceLocator.getDBConnection(ServiceLocator.ja
    va:56)
    at AtlasClient.printData(AtlasClient.java:16)
    at AtlasClient.main(AtlasClient.java:8)
    Caused by: java.lang.ClassCastException: org.jnp.interfaces.NamingContext
    ... 5 more

    I've got the same problem. Working with JBoss 4.0.3 and Tomcat 5.5. The lookup goes fine and returns an object of type remote home, however when I perform the narrow() I get ClassCastException. I'm sure the client and the server have got the same file version as I built from the same source.
    [error]
    Caused by: java.lang.ClassCastException
         at com.sun.corba.se.impl.javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:229)
         at javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:137)
    [error]

  • My iPad3 can't connect from app store to I tunes when downloading apps any help?

    When I have tried to download an app through app store on my ipad3 it brought up a blue dialogue box saying it cannot connect to ITunes store. I have checked my Internet/wifi connection and this is ok and I have switched the iPad off and on again but it is still not allowing the download of any apps from the app store.
    Has anyone experienced this and hodi you resolve it?
    Thanks

    You'll have to contact iTunes support, as they are the only one's who can solve your problem:
    http://www.apple.com/support/itunes/contact.html

  • As i turned on my iphone 4s on and connected to a wireless internet a page opened from the app firewall ip and i usually choose all connections. so it got stuck i held the standy by button but it won't turn off. so i held the standyby and home buttons.

    As i turned on my iphone 4s on and connected to a wireless internet a page opened from the app firewall ip and i usually choose all connections. so it got stuck i held the standy by button but it won't turn off. so i held the standyby and home buttons. when it opened all apps music and pics where not there. why? then i enterted photos and the loading logo appeared then the standyby appeared and i entered my password and everything in my iphone was there but thing were scattered and apps wheren't in folders everything was messed up but no photos or music AND IT SAYS UP IN THE MIDDLE OF THE SCREEN EXIT SAFE MODE. so i restarted it again and it opened and nothing was there and again i entered photos and the samething happen again. why did this happen? and can i get my data back? and in the usage it says that these thing are there but not showing.

    stevejobsfan0123 wrote:
    The Find my iPhone service option is given to you when you first set up the device. If you just reset it, you may have been given that option. So, in other words, the service may have been enabled even if you didn't realize it. You can then go to www.icloud.com and click on Find my iPhone, and have it play a sound. Or, you can use the Find my iPhone app on your mom's iPhone, but the service would still need to be turned on on your iPod.
    Unlike Compukid said, Apple will not assist in locating a lost device without the Find my iPhone service.
    I found that out 2 years ago, it's just that I thought Apple might have changed that.

  • I have my new HD in a USB enclosure connected to my MacBook Pro and I want to put a fresh copy of Mountain Lion on it. But I do not have an install DVD as I got ML as a download from the App Store. What do I do?

    I have my new HD in a USB enclosure connected to my MacBook Pro and I want to put a fresh copy of Mountain Lion on it. I'm told that I need to boot from the Installation Disk to start. But I do not have an install DVD as I got ML as a download from the App Store. Can I download ML from the App Store again, but this time directly to my new HD?

    Create a data recovery/undelete external boot drive
    You can also use Carbon Copy Cloner to clone your present setup to it and boot from it.
    Most commonly used backup methods
    However, SOME external enclosures are not bootable, you will soon find out.

  • I have purchased an app from the app store and cannot seem to download it.  I have tried restarting, and checked my connection but this seems to have no effect.  I have also downloaded other (free) applications since then and some of these download

    I have purchased an app from the app store and cannot seem to download it, the download statrs and then rapidly cuts out, it will not complete and seems to repeatedly go over the same few Mb.  I have previously downloaded large files and not had a problem with them.
    I have tried restarting, checked my hard disk (and repaired a sector of the disk) and checked my connection but this seems to have no effect.  I have also disabled virus protection and my firewall to see if this has an effect.  I have also downloaded other (free) applications to test it since then and some of these download but not the larger ones.  Has anybody else encountered this?  Does anyone know how to solve it?

    Can you download large files from other places apart from the App store, wondering if it is the App store or your internet connection.
    If it just the app store check this url http://www.apple.com/support/mac/app-store/contact/

  • Rel 12 - How to create a new APPS connection from custom Java/Shell Script

    Hi,
    I am looking to write a custom JAVA code / Shell Script which needs to establish a connection to execute a PL/SQL API on Rel 12 db.
    The challenge is to be able to connect without specifying APPS Password anywhere (just like Oracle Apps does it).
    This Shell script / Java code is not called from within Apps hence I need to establish a brand new connection along the lines of using ....
    WebAppsContext ctx = new WebAppsContext(System.getProperty("JTFDBCFILE"));
    OracleConnection conn = (OracleConnection)ctx.getJDBCConnection();
    like in 11i world or possibly using APPLSYSPUB username
    I need help / direction in how to do this in a Rel 12 env. I understnad there are lot of architecture changes and if someone can provide a generic code snipped it will be great.
    I need to keep this as closely aligned to Rel 12 coding and security standards as possible.
    This code will reside in $XXCUSTOM_TOP/bin file or under XXCUSTOM.oracle.apps.java....... if its Java.
    Pls help.
    Cheers
    -- VK.

    Hi,
    Have you looked at Oracle produced dbc file and its contents? That might help. It is under $FND_TOP/secure. It uses GWYUID=APPLSYSPUB/PUB. I am hoping that the APPS_JDBC_URL would help too.
    Regards,

  • How to connect to mysql from java app

    hi
    please say the procedure for connecting to mysql database from java app.
    .) what should i give in environmental variables
    .)where can i find the driver class for the mysql
    .) syntax of the url
    eg:- DM.getConnection("jdbc:mysql:..............what comes here..............");

    You can also get connections from a DataSource. Simple example:
                MysqlDataSource msds = new MysqlDataSource();
                msds.setUrl("jdbc:mysql://127.0.0.1:3306/dbdame");
                msds.setUser("user");
                msds.setPassword("pass");
                Connection c = msds.getConnection();Explore your options and be sure to consider connection pooling.

  • Sometimes when I'm trying to download an app from the app store when it is trying to load I get the error message cannot connect to iTunes store.   I am on the internet.  Any ideas?

    Sometimes when I'm trying to download an app from the app store when it is trying to load I get the error message cannot connect to iTunes store.   I am on the internet.  Any ideas?

    I have the same issue.  How did you solve it?

  • Connect from SAP gateway to RFC server failed - Java StandAlone app X SAP RAC System

    Dears,
    I'm developing a Java application (RFC SERVER) with JCo3 and I need to connect to SAP RAC system.
    I have configured the TCP/IP connection via transaction SM59, but when I try to start my server I face the error below (dev_jco_rfc.trc):
    ==========================================================================================
    **** Error file opened at 20140714 112024 Brasilia Time Rel 3.0.10 (2013-08-08) [720.440]
    Error:  >Mon Jul 14 11:20:24,636<    RfcException: [null]
        message: Connect from SAP gateway to RFC server failed
    Connection parameters: TYPE=A DEST=VSPAGUE ASHOST=cpe1601 SYSNR=01 SAPROUTER=/H/155.56.49.28 PCS=1
    LOCATION    SAP-Gateway on host ld7624.dmzwdf.sap.corp / sapgw01
    ERROR       hostname 'cpe1601' unknown
    TIME        Mon Jul 14 16:20:25 2014
    RELEASE     740
    COMPONENT   NI (network interface)
    VERSION     40
    RC          -2
    MODULE      /bas/740_REL/src/base/ni/nixxhl.cpp
    LINE        193
    DETAIL      NiHLGetNodeAddr: hostname cached as unknown
    COUNTER     3
        Return code: RFC_FAILURE(1)
        error group: 102
        key: RFC_ERROR_COMMUNICATION
    ==========================================================================================
    This problem happens when my app executes the line:
    JCoServer myServer = JCoServerFactory.getServer(myServerName);
    My system properties:
    jco.client.lang=EN
    jco.destination.peak_limit=10
    jco.client.client=800
    jco.client.passwd=********
    jco.client.user=********
    jco.client.sysnr=01
    jco.destination.pool_capacity=3
    jco.client.ashost=/H/155.56.49.28/H/cpe1601
    jco.server.connection_count=3
    jco.server.gwhost=/H/155.56.49.28/H/cpe1601
    jco.server.progid=VSPAGUE
    jco.server.gwserv=sapgw01
    jco.server.repository_destination=VSPAGUE
    Using SAP Logon i can connect to server cpe1601 system E16 without problems.
    Please, I really need some help, because my knowledge on SAP platform is minimum.

    Hi Markus,
    Changing ASHOST=ld7624.dmzwdf.sap.corp as you have suggested, I got the error message: Connect to SAP gateway failed ...
    As you could see, the host I'm connecting is from SAP RAC Service.
    Here in our company we have only SAP Logon and my RFC Application, and I can connect to SAP remote system via SAP Logon with this settings:
    System Connection Parameters
    Description: SAP ECC 6.0
    Application Server: cpe1601
    Instance Number: 01
    System ID: E16
    SAProuter String: /H/155.56.49.28/H/
    Below the connection information I received from SAP RAC SUPPORT for testing purposes:
        E16 System:
        SID: E16
        Client: 800
        System Number: 01
        Server: cpe1601
        Component Version: SAP ERP Central Component 6.0 Enhancement Pack 6 Suite on HANA
        User: ********
       Password: ********
       SAProuter String:
       If you don't plan to use SAPRouter at your end,
       /H/155.56.49.28/H/    

  • How come when I go to download an app from the App Store it won't connect to the iTunes Store???

    I went to download an app from the App Store &amp; it told me cannot connect to iTunes Store. What do I do to fix this problem???

    The Complete Guide to Using the iTunes Store
    http://www.ilounge.com/index.php/articles/comments/the-complete-guide-to-using-t he-itunes-store/
    Can't connect to the iTunes Store
    http://support.apple.com/kb/TS1368
    iTunes: Advanced iTunes Store troubleshooting
    http://support.apple.com/kb/TS3297
    Best Fixes for ‘Cannot Connect to iTunes Store’ Errors
    http://ipadinsight.com/ipad-tips-tricks/best-fixes-for-cannot-connect-to-itunes- store-errors/
    Try this first - Reset the iPad by holding down on the sleep and home buttons at the same time for about 10-15 seconds until the Apple Logo appears - ignore the red slider - let go of the buttons.
    This works for some users. Not sure why.
    Go to Settings>General>Date and Time> Set Automatically>Off. Set the date ahead by about a year.Then see if you can connect to the store.
     Cheers, Tom

  • HT4759 I can not install app's from the app store on my phone,and when i try, i get a message tells me (cannot connect to itunes store) that happened after i updated it to "IOS6" . it's a "IPhone4 S"

    I can not install app's from the app store on my phone,and when i try, i get a message tells me (cannot connect to itunes store) that happened after i updated it to "IOS6" . it's a "IPhone4 S"

    Remember, any purchased item from the itunes store is forever associated with the Apple ID used to buy it.  So when you get prompted for an ID/password and it doesn't accept it, then you are using the wrong ID.
    Go to Settings>iTunes and App Stores, be sure it's logged into the ID you have set on the iphone (since that one seems to be connecting with the right ID).  If you've done this, then you might wait a bit to see if the "cannot connect to .. store" message has to do with internet connections.

  • When I try and download an app (iphone 4s) , from the app store a message pops up saying "Not connected to the intunes store

    When I try and download an app , from the app store a message pops up saying "Not connected to the intunes store".

    Try resetting network settings... settings>general>reset>reset network settings

Maybe you are looking for