IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  Java service to create db connection pool

    Posted Fri May 06, 2005 11:44 PM

    wMusers,

    My client is using the following java code in a custom service to open a single connection to their oracle db (which then calls a proc and inserts a clob):

         getConnection123(dbServer , dbUserId, dbPasswd ,dbPort,dbName);  
    clob=getCLOB(it_xnldata);  
    CallableStatement cs = null;  
    String sql="begin  "+proName+"(?,?); end;" ;  
    cs = (CallableStatement)conn.prepareCall( sql);  
    cs.setObject(1,POG_ID);  
    cs.setObject(2,clob);  
    cs.execute();  
    conn.close();  
    

    It works fine for the most part, but occasionally, they get a trigger (set to serial) deadlock:

        Thread Dump:  
    FOUND A JAVA LEVEL DEADLOCK:  
    ----------------------------  
    "ABIomsTAT.trigger:callSAPI7":  
    waiting to lock monitor 0x2ed20d0 (object 0x4e3d07d0, a  
    

    oracle.jdbc.driver.OracleConnection),
    which is locked by “HTTP Handler 167.116.201.59”
    “HTTP Handler 167.116.201.59”:
    waiting to lock monitor 0x2ed2050 (object 0x4e3d09c8, a
    oracle.jdbc.ttc7.TTC7Protocol),
    which is locked by “ABIomsTAT.trigger:callSAPI7”

    causing them to have to restart their production IS. Because of other
    reasons, they can’t use the standard IS JDBC adapter connection.

    1- What causes could cause the deadlock here?
    2- Do you have any sample java services to create a db connection pool? We think that creating a pool will remedy the deadlock issue.

    Thank you.


    #Adapters-and-E-Standards
    #Integration-Server-and-ESB
    #webMethods


  • 2.  RE: Java service to create db connection pool

    Posted Sat May 07, 2005 12:23 AM

    John,

    Here with uploading a custom JS code,for inserting Blobs(large xml files)to oracle DB using WmDB Alias and ConnectionManager.

    Also you should place the code in the Shared tab,which there is an indication in the code SHARED.

    So check the code and customize it accordingly, if at all helps.

    insertBlob_JS
    insertBlob_JS.txt (26.4 k)

    HTH,
    RMG.


    #Integration-Server-and-ESB
    #Adapters-and-E-Standards
    #webMethods


  • 3.  RE: Java service to create db connection pool

    Posted Mon March 27, 2006 11:45 AM

    RMG,
    I have a similar problem but not able to open the attachment. Pls post that again.

    Thanks in advance


    #webMethods
    #Integration-Server-and-ESB
    #Adapters-and-E-Standards


  • 4.  RE: Java service to create db connection pool

    Posted Wed November 14, 2007 06:09 PM

    RMG ,
    Does this approach work for getting JDBC connections in webMethods.
    is there any restrictions in wbmethods jdbc connection poll access from Java.


    #Adapters-and-E-Standards
    #webMethods
    #Integration-Server-and-ESB