Skip to Content
avatar image
Former Member

MDM ConnectionPool-design required between SAP NW App server & MDM server

Hello,

I have a deployable java proxy which implements the business logics using MDM Java API 5.5. to insert or modify the record in MDM repositorty, the data is send from ECC via PI 7.1.

The current design which i implemented is whenever the proxy is called a new connectionPool instance is fetched from ConnectionFactory and get the repository&user session and once the record is inserted in MDM repository i do the cleanup(i.e destroy sessions & close connection).

Since a new connection is obtained every time the performance issue occurs, i would like to whether an configuration is available to maintain/have a connectionPool in the SAP NW application server,so that only one connectionPool is obtained from that i can do the operation in MDM.This way i can reduce the performance issue.

Please pour your thoughts.

Regards

Sabarinathan

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Jul 13, 2009 at 02:15 PM

    Hi,

    You can time out the user session from MDM instead of NW WAS.

    Define - Session Timeout Minutes= parameter in MDS.ini and restart MDM.

    Regards,

    Shambhu.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi,

      Thanks for your comments, but the session handling part is already taken care in cleanup() method.

      Once the record is successfully insert or modified, i do a cleanup to destroy the session and release the connection.

      The issue is how to have only one connectionPool instance with maxconnection set and resuse for creating the user session/reposotory session.

      I am trying to have a stateful session bean with gets the connections and in my implementation class like creating the session i do a JNDI Lookup to bean to get the connectionPool instance, this way i reuse the connectionPool object.

      It works for me,,but some how only 7 connections are obtainied evethough i setmaxconnection to 10000. I dont know whether the defaultmaxconnection is getting overriden or not? Any idea why is this?

      @TransactionManagement(value = TransactionManagementType.CONTAINER)

      @Stateless(name="MasterDataReplicationBean")

      public class MasterDataReplicationBean implements MasterDataReplicationLocal {

      public ConnectionPool connectionPool=null;

      public void setConnection(){

      try{

      ConnectionPoolFactory.setMaxConnections(100000);

      this.connectionPool=ConnectionPoolFactory.getInstance("CH00SDD1",true);

      this.connectionPool.setMaxConnections(100000);

      }

      catch(Exception ex){

      //throw exception

      }

      }

      public ConnectionPool getConnection(){

      return this.connectionPool;

      }

      The below code does the JNDI lookup,

      hashtable<String, String> prop = new Hashtable<String, String>();

      prop.put(Context.INITIAL_CONTEXT_FACTORY,"com.sap.engine.services.jndi.InitialContextFactoryImpl");

      prop.put("force_remote", "true");

      prop.put(Context.PROVIDER_URL, "xxxxxdi1.au.acc.accnet:50014");

      If anyone has anyother approach/design your most welcome and i am interested in it.

      Thanks

      Sabarinathan