DriverManagerXAConnection is not getting closed.Toplink 9.0.4.5 OC4J 10.1.2

DriverManagerXAConnection is not getting closed.
Toplink is acquiring connections from two pools OracleConnectionPooledDataSource
and XAConnectionpool. The connection of PooledDatasource is getting released
but the DriverManagerXAConnection is not getting released.
The oc4j output shows.
[java] null: Releasing connection com.evermind.sql.DriverManagerXAConnection@d042d7 to pool (Pool size: 1)
[java] null: Releasing connection com.evermind.sql.DriverManagerXAConnection@702936 to pool (Pool size: 2)
[java] null: Releasing connection com.evermind.sql.DriverManagerXAConnection@1c0db6a to pool (Pool size: 3)
I saw a thread in oc4j forum
Get and close connections many times in an EJB transaction drains pool
which says that this issue is resolved, but I am using toplink 9045 and oc4j 1012
and the problem still persist, also I cannot find the bug 3330123 which is
mentioned in that link on metalink.
Does toplink uses two different connection pools for reading and writing respectively
when used with External Transaction Controller ?
If yes then how this two different pools be configured.
Any help is appreciated.

Hello,
In the forum posting you mentioned, bug: 3330123 I think was a red herring as it was an internal bug that was never able to be verified.
The post though mentions that a Tar:3793784.996 was opened. This tar was linked to bug:3674906 which was created to deal with the issue that calling ds.getConnection() max-connections*10 times, OC4J throws SQLException (timeout).
The problem was that each getConnection call was returning a new logical connection, even though they would share the same physical connection if in the same transaction context. This was changed so that there is no limit on the number of logical connections.
The release logging messages you are seeing are a left over that doesn't seem to have been looked at as a probelm in the bug. I believe they can be ignored - the logical connections are held on to by the container transaction and will only released when this transaction is commited/rolledback.
As for pooling configuration, I suggest looking at the sessionbean demos that use OC4J as examples of how it should be configured. TopLink will use separate pools for reading/writing if configured.
Best Regards,
Chris Delahunt

Similar Messages

  • Import of photos is not working. Moreover 'photos' app is not getting closed, it says 'closing all libraries'. Even it is stopping shutdown/restart of my mac.

    Import of photos is not working. Moreover 'photos' app is not getting closed, it says 'closing all libraries'. Even it is stopping shutdown/restart of my mac.

    Next time you open the photos application hold down both of the keys suggested and then launch the application in the usual way. If you do this you will be presented with the opportunity to repair your library.

  • TCP Socket connection in CLOSE_WAIT status and not getting closed

    I am facing an issue with the TCP socket connections not getting closed and they are in CLOSE_WAIT status for ever.
    As a part of batch process in our application, emails are sent with 4 embedded images. These images are downloaded from 3rd party site with IP say "UUU.XXX.YYY.ZZZ"
    The images are embedded to email as follows
    1. An URL object is created with the site url.
    URL urlPhoto = new
    URL("http://UUU.XXX.YYY.ZZZ/email/photos.jpg");
    2.     The image cid is created with the URL object and the image name
    HtmlEmail htmlEmail = new HtmlEmail();
    String cid1 = htmlEmail.embed(urlPhoto,
    "photo.jpg");
    3.     The image cid is added to the email template by replacing the ${cid1} and the email is sent.
    <td valign="top">
                   <img src="cid:${cid1}" width="279" height="274">
              </td>
    When a mail is sent, 4 new TCP connections are opened and are put in CLOSE_WAIT status for ever. For every mail sent 4 new connections are opened. In UNIX there is an upper limit on the number of open file handles (defaults to 1024) at any point of time. The open TCP connection has the underlying socket in CLOSE_WAIT status and is not getting closed at all. When the upper limit (1024) is reached the batch process is throwing the following exception and terminates.
    Caused by: com.inet.tds.ap: java.net.SocketExceptionjava.net.SocketException: Too many open files
    at com.inet.tds.am.a(Unknown Source)
    at com.inet.tds.TdsDriver.a(Unknown Source)
    at com.inet.tds.TdsDriver.connect(Unknown Source)
    at java.sql.DriverManager.getConnection(DriverManager.java:525)
    at java.sql.DriverManager.getConnection(DriverManager.java:171)
    at com.hcomemea.batchprocess.dataaccess.database.BaseJdbcDao.openConnection(BaseJdbcDao.java:106)
    ... 12 more
    When I run the command lsof in UNIX which list the open file handles in the system
    $ /usr/sbin/lsof -p 22933 -i | grep CLOSE_WAIT
    java 22933 build_master 297u IPv6 129841943 TCP integration.com:47929->UUU.XXX.YYY.ZZZ:http (CLOSE_WAIT)
    java 22933 build_master 298u IPv6 129841947 TCP integration.com:47933->UUU.XXX.YYY.ZZZ:http (CLOSE_WAIT)
    java 22933 build_master 299u IPv6 129841950 TCP integration.com:47936->UUU.XXX.YYY.ZZZ:http (CLOSE_WAIT)
    java 22933 build_master 300u IPv6 129841970 TCP integration.com:47952->UUU.XXX.YYY.ZZZ:http (CLOSE_WAIT)
    ���list of 935 connections similarly�
    I tried 2 solutions
    1. Got the HttpURLConnection from the URL object and invoked disconnect method on the same. But it doesn�t work.
    2. Ran the batch process java program with the parameter �Dhttp.keepAlive=false to close the underlying connection but didn�t help.
    I need the underlying sockets to be closed and not put in CLOSE_WAIT status after sending the mail.
    Is it the problem with the embed method of HtmlEmail object not closing the underlying socket connection.
    If anyone has faced this issue before, kindly let me know the possible solutions for the same ASAP.
    Thank you,
    Ramesh G

    This sounds more like a problem due to connection pooling at middle tier/application server.
    If that has been ruled out, then you might to enable DCD or set expiry time on the server.

  • Custom screen window not getting closed !

    I have designed a screen and calling that using call screen XXXX starting at 15 5. Sreen does load up. Upon clicking close button(X mark) on the top right side, window is not getting closed.
    I have two more buttons OK and CANCEL in screen, which I designed, on clicking them screen does behave properly,
    I searched in SDN but couldnt get much help.
    Any idea what am missing ??
    Thanks & Regards
    Himayat.

    Hi Gautham,
    I already have this code in place,
    CLEAR v_ok_code.
      v_ok_code = sy-ucomm.
      CASE v_ok_code.
        WHEN 'CNCL'.
          REFRESH it_input.
          LEAVE TO SCREEN 0.
          WHEN 'TSAVE'.
          PERFORM update_table.
        WHEN OTHERS.
      ENDCASE.
    The thing is that generally for closing(X mark button on top), we dont do any explicit coding. I see some strange behaviour.

  • Sales order not getting closed

    Hi,
    I am creating delivery document through SDK based on existing sales orders. it creates it with perfect quantity, tax , amount and doctotal values but the original sales order does not get closed contradictory to SAP's standard flow.it does shwo all the row-status as closed. but the document status remains open.
    what could be wrong? do i have to close it through SDK?
    Thanks,
    Binita

    Binta,
    As Petr said, i have added a SO in normal SAP UI without any addon, and copied it to Delivery and changed the Freight and added the delivery, in this case, the SO remains open.
    So I guess u can summarize that if any changes occur the SO would remain open?
    Hope it helps,
    Vasu Natari.

  • Why SO Header not get closed automatically after all SO lines get closed?

    Hi all :
    Do you know the reason, why some SO Header still as Booked Status, even All the SO lines are already closed ?
    If I see the Workflow status the SO Header is in Status = Deferred and Activity = Wait
    And I can close it manually if I rewind the Activity in the Workflow, but I want to know why the SOs not get closed automatically.
    Thank you in advance
    Edited by: Daniel on Jan 18, 2011 8:41 AM

    Have you scheduled the concurrent request to use Workflow Background Processor to Process OEOH ? What is the frequency? Has it run after the lines got closed?
    Also, check the value of the WAIT attribute in the OEOH workflow? By default, it is set to close headers at the end of month.
    For more detail please see Note:141919.1 on Metalink.
    Also refer to metalink document # 397364.1 which details how to change the WAIT attributes.
    Hope this helps,
    Sandeep Gandhi

  • Delivery Document not getting closed

    Hi Experts,
    I am using 2007 B PL 08. I want to close the delivery document through SDK against which no Invoice or return is booked. it gives me error 'Internal error -5002 occured' when I try to close this document with following code.
    Dim fd As SAPbobsCOM.Documents
      fd = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oDeliveryNotes)
             If fd.GetByKey(93) = True Then
                    DelClose = fd.Close
                    If DelClose <> 0 Then
                        oCompany.GetLastError(FErrCode, FErrMsg)
                        MsgBox(FErrMsg)
                    End If
              End If
    i even try following code to loop through the lines collection and close lines instead of closing header.
    it gives me "you can not close rows in this type of document" error:
    Dim fd As SAPbobsCOM.Documents
                fd = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oDeliveryNotes)
                If fd.GetByKey(93) = True Then
                    For i = 0 To fd.Lines.Count - 1
                        fd.Lines.SetCurrentLine(i)
                        If fd.Lines.LineStatus <> SAPbobsCOM.BoStatus.bost_Close Then
                            fd.Lines.LineStatus = SAPbobsCOM.BoStatus.bost_Close
                        End If
                    Next
                    DelClose = fd.Update
                    If DelClose <> 0 Then
                        oCompany.GetLastError(FErrCode, FErrMsg)
                        MsgBox(FErrMsg)
                    End If
                End If
    this used to work with 2005 B. Am I doing anything wrong?
    Thanks in advance,
    Binita

    Hi Binita,
    Closing the delivery at the header level works in the DI API in SBO 2007A (though it's not good practice as the correct method, as you know, would be to add a return linked to the delivery to return the goods to stock and update the GL). I can also do this via the SBO client (it warns me that there is no target document but I can choose to continue).
    If you can close the delivery via the SBO client in 2007B then it sounds like a bug in the DI API.
    Kind Regards,
    Owen

  • R12: AP Tax Code window not getting closed

    Hi,
    When ever I open tax code window in AP(Payables>Setup>Tax>Tax Code) I cant able to close the tax code window, window gets hang, I didnt find any other way to close the window except closing the entire application.
    We have recently migrated to 12.0.6 from 11.5.10.2
    Please suggest to resolve this issue
    Regards
    Naga

    Have you applied the latest CPCs ? See MOS Doc 557869.1 (EBS: R12 Oracle Financials Critical Patches) - these patches are mandatory. If you have, pl open an SR so Support can troubleshoot. Did this ever work correctly - if so what changes have been made recently ?
    HTH
    Srini

  • Process Orders are not getting closed-- Unsettled Variances; Balances exist

    Hello Gurus,
    We have a problem when we are trying to close process orders in Release 4.6C; We are unable to close those orders and the error messages would be variances are not settled and balances still exist.
    When we try to modify the periodic settlement in process order settlement rule it gets grayed out and wont let us do any modifications. Some body suggested that we have to make the settlement rule to FUL and then try to close but it never works. It's a problem for quite sometime, any help would be worth more than an appreciation.
    Thanks,
    Ramana

    Hi Ramana
    You need to more specific on the errors and the description of the process where you are finding the problem
    Eloborate your problem like what is the settlement type now,  whether you have done the variance calculation, what is the status of the order now (TECO, DLV etc.,)
    Make the process order in TECO or DLV, calculate the variance calculation and settle the order.
    Regards,
    Suraj

  • Project not getting closed

    Dear Gurus,
    The WIP calculation is performed and settled every week for all projects. one particular project is having Negative balance and when we try to close it says its balance is not zero and WIP in Financial Accounting is still to be cleared.
    We have tried to Reverse all the Settlement   and done RA and try to Settle the Project again but the Balance of the Project 8588.72- has not changed and we were not able to close the project.
    Can you please provide your opinion on the same.
    Thank you

    Hi,
    Try reversing all settlements. There might be settlements relevant for a particular period which are settled in some different period.
    Trust this helps much.
    Cheers!!

  • ME22N: change of PO details in backend not getting replicated with SRM 7.0

    Hi All,
    We have created Purchase order using shopping cart in SRM 7.0 extended classic scenario. The PO created in SRM 7.0 is replicated into backend in ME21N using a Custom BDC program.
    But when the Purchase order is changed in SRM 7.0 the data is not getting replicated. We are not allowed to change the PO details in backend using ME22N (No change in SRM Backend is allowed ), So we are not able to write a Custom BDC program for that. Hence the PO is not getting closed and throwing error.
    Please suggest me an alternative.
    Regards,
    Lakshmi Narayana

    Hi,
    Being in Extended Classic Scenario, PO cannot be in change mode in R/3.
    This is due to check done on PO status (fied STATUS from EKKO table).
    When PO is created by SRM replication, its status is 'K' (Purchase Order from BBP). What you could do is to substitute this status with value 'I' (Purchase Order from BAPI) using BAdI BBP_ECS_PO_OUT_BADI.
    In this way, R/3 PO can be modified in R/3.
    Nevertheless, by doing this, you won't have your SRM PO output after modification(s) (as it is done in standard) because  changes are in R/3.
    To be able to get an R/3 PO output with ECS, see following note:
    883693 - ECS: PO output determination in R/3.
    Regards.
    Laurent.

  • ADD ONS WINDOW AND OPTIONS WINDOW DOESNOT GET CLOSED

    AFTER WORKING OR ON COMPLETION OF WORK WITH ADD-ON OR OPTIONS, WINDOWS ARE NOT GETTING CLOSED ON CLICKING ON OK BUTTONS

    Start Firefox in [[Safe Mode]] to check if one of your add-ons is causing your problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).
    See [[Troubleshooting extensions and themes]] and [[Troubleshooting plugins]]

  • Open Sale Order Value (FD33) not getting diminished even after closing SO?

    Hi,
    Upon Executing FD33 and clicking the status view for a Customer say XYZ , and then choosing EXTRAS-Open Sale Order . Say the value of open sale orders being shown is 75000. Even after closing the open sale orders (By Selecting VA05 and Putting reason for Rejection), and then also the Open Sales Order value is not getting diminished.
    What could be the reason ?
    Pls help.
    Regrds,
    Binayak

    Hi Binayak,
    As mentioned by you, running of Credit re-org program 'RVKRED77' is the only solution for this problem and it is known problem in SAP.
    Some precautions
    1. Always run the program in background by scheduling a job.
    2. The idle time is around midnight when no user is working on SAP.
    3. Some time the job fails as some other program may be updating same tables as this program. In such cases re-schedule the job at different time.
    4. You may run the program 'RVKRED88' which will simulate without actual updation of credit values.
    Hope this clarifies..
    Regards,
    Madhu.

  • Not closing ResultSet, but not getting ORA-01000

    I have an application that is generating the familiar ORA-01000 error.
    Whilst investigating the problem, I wrote a small test program. In the test program I tried to get the ORA-01000, but I don't get it (has anyone ever complained about not getting ORA-01000 before?!)
    connection = DriverManager.getConnection("<connection string>");
    String sql = "SELECT c1 FROM pdtab2 WHERE Id>=? AND Id<=?";
    PreparedStatement ps = connection.prepareStatement(sql);
    for (int i = 1; i <= 30000; ++i)
        ps.setInt(1, i-1);
        ps.setInt(2, i+1);
        if (i % 100 == 0)
            System.out.println("i=" +i);
            System.out.println("getCurrentOpenCursors(connection)="
                               +getCurrentOpenCursors(connection));
        try
            rs = ps.executeQuery();
            while (rs.next())
                result = rs.getInt(1);
        catch (SQLException e2)
            e2.printStackTrace();
        finally
            // Do nothing! Do not close the result set
    }getCurrentOpenCursors does:
    select count(*) AS COUNT from v$open_cursor where user_name like 'me'
    I have reduced OPEN_CURSORS down from 300 to 100, but getCurrentOpenCursors always returns less that what it is set to. Suggesting that OPEN_CUSRORS is not a limit, but rather a pool size?
    The result set returns more than one record, I never close the result set, yet I do not get an ORA-01000 error. I have tried auto-commit true and false on the connection. Is the prepared statement closing its previous result set on each new iteration of the loop, hence stopping me getting a problem?
    I am using Oracle version 10.2.0.1, the corresponding ojdbc14.jar, and Java 1.4.
    Thanks,
    Paul

    Here is a program that does that for you.
    To fix the program, un-comment the line 24 of the code and run again.
    C:\> type TestCursors.java
    import java.lang.* ;
    import java.util.* ;
    import java.sql.* ;
    import oracle.jdbc.* ;
    public class TestCursors
        public static void main(String[] args) throws SQLException, ClassNotFoundException
            Class.forName("oracle.jdbc.driver.OracleDriver");
            Connection connection = DriverManager.getConnection("jdbc:oracle:oci:@localhost:1521:ORCL");
            ResultSet rs ;
            PreparedStatement ps ;
            for (int i = 1; i <= 30000; ++i)
                String sql = "SELECT 20 FROM scott.emp WHERE deptno = ?";
                ps = connection.prepareStatement(sql);
                ps.setInt(1, 10);
                try
                    rs = ps.executeQuery();
                    rs.close() ;
                    //ps.close() ;
                catch (SQLException e2)
                    System.out.println("The value if i is " + i) ;
                    throw e2 ;
    C:\> javac TestCursors.java
    C:\> java TestCursors
    The value if i is 301
    Exception in thread "main" java.sql.SQLException: ORA-01000: maximum open cursors exceeded
            at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:111)
            at oracle.jdbc.driver.T2CConnection.checkError(T2CConnection.java:671)
            at oracle.jdbc.driver.T2CConnection.checkError(T2CConnection.java:597)
            at oracle.jdbc.driver.T2CPreparedStatement.executeForDescribe(T2CPreparedStatement.java:570)
            at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(OracleStatement.java:1030)
            at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1123)
            at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3284)
            at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:3328)
            at TestCursors.main(TestCursors.java:22)
    C:\>

  • Cisco ISE 1.2, Clients not getting IP address in closed mode

    Hello, I am running closed mode on my switchports. I have an issue where some clients come in in the morning, try to login, and will not get network access. I see that this is because they do not get an IP address. I am using MAB for authentication currently. They appear to MAB correctly and get Authorized in ISE, but they do not get an IP. Therefore, they also do not get the DACL of permit ANY. It's like the port gets de-authenticated during the night. Usually when the machine is rebooted it will come up with an IP address. Here is my switchport config...
     switchport access vlan 32
     switchport mode access
     switchport voice vlan 64
     logging event link-status
     authentication event fail action next-method
     authentication event server dead action authorize vlan 32
     authentication event server dead action authorize voice
     authentication event server alive action reinitialize 
     authentication host-mode multi-auth
     authentication order mab dot1x
     authentication priority dot1x mab
     authentication port-control auto
     authentication periodic
     authentication timer restart 600
     authentication timer reauthenticate 7200
     authentication violation restrict
     mab
     dot1x pae authenticator
     dot1x timeout quiet-period 300
     dot1x timeout tx-period 10
     dot1x timeout ratelimit-period 300
     dot1x timeout held-period 300
     service-policy input QoS-Input-Policy
     service-policy output QoS-Host-Port-Output-Policy
    end

    Thanks, here is the requested output of an Unauthorized client. I had to configure authentication open so they could still get access...
    SJ5051IDF1#show authen sess int g2/20 d
                Interface:  GigabitEthernet2/20
              MAC Address:  d4be.d94f.ab92
             IPv6 Address:  Unknown
             IPv4 Address:  10.42.32.109
                User-Name:  D4-BE-D9-4F-AB-92
                   Status:  Unauthorized
                   Domain:  DATA
           Oper host mode:  multi-auth
         Oper control dir:  both
          Session timeout:  N/A
        Common Session ID:  0A2A000B000034E367D4B998
          Acct Session ID:  Unknown
                   Handle:  0x21000508
           Current Policy:  POLICY_Gi2/20
    Local Policies:
    Template: DEFAULT_LINKSEC_POLICY_SHOULD_SECURE (priority 150)
          Security Policy:  Should Secure
          Security Status:  Link Unsecure
    Method status list:
           Method           State
           mab              Authc Success
    SJ5051IDF1#
    SJ5051IDF1#
    SJ5051IDF1#show ip access int g2/20
    SJ5051IDF1#
    SJ5051IDF1#
    SJ5051IDF1#show access-list int g2/20
                                    ^
    % Invalid input detected at '^' marker.
    SJ5051IDF1#show access-list ?        
      <1-2799>    ACL number
      WORD        ACL name
      ipc         Show access-list config download info
      rate-limit  Show rate-limit access lists
      |           Output modifiers
      <cr>
    SJ5051IDF1#show access-list g2/20
    SJ5051IDF1#
    SJ5051IDF1#
    SJ5051IDF1#

Maybe you are looking for

  • Downloaded latest version of safari and it wont open properly only the top of the page open???

    i was running safari on my ibook and all of a sudden it stoped working it wouldnt load the page only the top of the page would load. so i went to firefox but when i stream videos of firefox they always seem to be jumpy. so i have recently downloaded

  • HT1758 How do I connect a 2nd (Dell) Monitor to my iMac 21in?

    Trying to (want to) have a Dell Monitor hooked up to my iMac 21in...Do not have a Thunderbolt!

  • Display audio in Safari

    When I am using a chat client in Safari the input audio in my display is not recognized. The microphone works in other programs, I can record and be heard, etc., but never when I use it in Safari. Any help would be much appreciated!

  • Operating System Size

    Hi, I have a 48 hour old Macbook with the 80gb hard drive. I have loaded nothing on it and it shows 57gb of available space. Can this be right? the OS and misceallaneous other programs take up 23 gb? I went as far as to try a new install from the dis

  • Export  error oracle 9.2.0.1

    hi, i want to get an export file for a table from Oracle 8.1.6.0 (on sun server 5500) using 9.2.0.1 server ( on another server machine) exp command like that : exp username/pass@string file=myexp.dmp tables=tablename when i give this command it gives