1 Reply Latest reply on Mar 6, 2003 8:34 AM by David Jencks

    Best way to do jca connections to different servers?

    Alwyn Schoeman Newbie

      Hi,

      I'm (trying) to write a jca adapter that uses a socket to send and receive data over multiple connections to a server.

      If you want to do this to multiple servers at the same time, will you need to deploy multiple adapters with different configuration?
      Or can you write an single adapter that can do this in a smart way?

        • 1. Re: Best way to do jca connections to different servers?
          David Jencks Master

          Several people have written adapters that connect to different servers depending on info in the Subject or ConnectionRequestInfo. This is specifically recommended against by the spec, but doesn't seem to cause any problems.

          I'd recommend doing this only if the server to connect to can be determined from only the users identity. Then you can write a login module that adds extra destination info to the Subject and your app won't have to worry about where it is connecting to. If you have to determine the destination in app code I'd just deploy lots of datasources/connectionfactories and keep the adapter simple. Figuring out the destination info isn't going to be any easier than figuring out a jndi name to look up. I would not try to make one connection/mc connect to multiple server instances.