0 Replies Latest reply on Nov 5, 2009 4:56 AM by groovie

    HOWTO: Pool connection management of my managed connection

    groovie

      (HINT: copied form the JCA-user forum since it is more dev related)

      Dear sirs,

      i have a question according to the proper
      coding of the ressource/connection
      management in JCA using the mbean
      org.jboss.resource.connectionmanager.JBossManagedConnectionPool.

      My application is using an old legacy application
      (expert system). This application has been modified
      and is running now as a classical forking-UNIX server,
      that spawns automatically a new client worker,
      if somebody tries to connect. This piece of software
      is now acting as a EIS.
      The forking model was choosen, cause to a possible
      situation, when the working is getting a SEGV-interrupt,
      the JBoss-JCA container cold establish a new connection
      with a new working.

      The connector, that has been implemented so far,
      establishes a pool of connections using the
      JBossManagedConnectionPool. The question is now,
      how to tell inside my ManagedConnection (or
      somewhere else) the controller of the
      JBossManagedConnectionPool, that the connection
      was gone and he shall create a new one.

      I think, this is the issue of the ConnectionPool-Manager,
      who will disables or remove the connection from the pool
      and try to establish a new one (using my ManagedConnection).

      Do you have some code, how to interact with the Pool ?

      The technical connection-failure is detected in my
      connection-impplementation, while reading the result of
      a previously sent request message over the TCP-connection.
      So throwing an exception is ok, but who will catch it to
      generate a message for the pool-Manager in
      org.jboss.resource.connectionmanager.JBossManagedConnectionPool
      Please-note: For RPC-request the initiating instance is a session
      bean and not the Pool-Managers!

      Thank you
      Groovie