5 Replies Latest reply on Oct 1, 2008 9:24 AM by marklittle

    TransactionManager ports

      The TM is opening a few ports that need to be closed.

      This looks to be related to distributed recovery processing which isn't relevant
      for the web-profile which has no distributed transactions (except those it initiates).

        • 1. Re: TransactionManager ports
          jhalliday

          Nice timing, I happen to up to my neck in JBossTS port allocation code right now, as I'm integrating it with ServiceBindingManager.

          For the JTA, there are three ports: TransactionStatusManager, RecoveryManager and SocketProcessId. If the recovery manager runs in-process with the app server and does not need to talk to any other transaction manager, named pipes are a feasible alternative for the first two. see http://www.jboss.com/index.html?module=bb&op=viewtopic&t=139875

          The SocketProcessId is basically a kludge to get a uniq number (the port number) for use in Uids, in place of the ability to get the process id, which you can't do from Java. There are alternative strategies, such as using a file lock instead. It's pluggable - just substitute in one more to your taste.

          BTW, why do the ports need to be closed?

          • 2. Re: TransactionManager ports

             

            "jhalliday" wrote:

            BTW, why do the ports need to be closed?


            It's just a webserver. There's no need for remote access except over the standard
            protocols http, ssl, ajp so there's less management but more importantly less
            security risk.

            3 ports is what I was seeing, two looked to be "random".

            • 3. Re: TransactionManager ports

               

              "jhalliday" wrote:

              The SocketProcessId is basically a kludge to get a uniq number (the port number) for use in Uids, in place of the ability to get the process id, which you can't do from Java. There are alternative strategies, such as using a file lock instead. It's pluggable - just substitute in one more to your taste.


              Can't you just use?
              http://java.sun.com/j2se/1.4.2/docs/api/java/rmi/server/UID.html

              Or if you want more control of the format and just want a unique 'process id"
              http://java.sun.com/j2se/1.4.2/docs/api/java/rmi/dgc/VMID.html

              • 4. Re: TransactionManager ports
                jhalliday

                No and maybe (depending how good the hashCode is). But like I say, we have an alternative to the socket id already, so I'm not inclined to give much priority to adding another option.

                • 5. Re: TransactionManager ports
                  marklittle

                  Sun's UID implementation was not unique enough for our needs in the past. It may have improved, but Uid is used throughout the code for a lot of different things. Changing it would not be a simply fix.