Class RequestMultiplexer


  • public class RequestMultiplexer
    extends Object
    • Constructor Detail

      • RequestMultiplexer

        public RequestMultiplexer​(Connection cnx,
                                  RequestChannel channel,
                                  long heartBeat)
                           throws jakarta.jms.JMSException
        Throws:
        jakarta.jms.JMSException
    • Method Detail

      • buildJmsException

        public static jakarta.jms.JMSException buildJmsException​(MomExceptionReply excReply)
        Converts a MomExceptionReply to the corresponding JMSException.
        Parameters:
        excReply - the MOM reply to convert
        Returns:
        the corresponding Exception
      • checkDemultiplexerDaemon

        public boolean checkDemultiplexerDaemon()
      • checkCLSession

        public boolean checkCLSession​(Session session)
      • createTimer

        private static void createTimer()
      • cancelTimer

        private static void cancelTimer()
      • getTimer

        private static Timer getTimer()
      • setStatus

        private void setStatus​(int status)
      • isClosed

        public boolean isClosed()
      • closing

        public void closing()
      • setExceptionListener

        public void setExceptionListener​(jakarta.jms.ExceptionListener exceptionListener)
      • getExceptionListener

        public jakarta.jms.ExceptionListener getExceptionListener()
      • sendRequest

        public void sendRequest​(AbstractJmsRequest request)
                         throws jakarta.jms.JMSException
        Throws:
        jakarta.jms.JMSException
      • setMultiThreadSync

        public void setMultiThreadSync​(int delay,
                                       int threshold)
      • close

        public void close()
        Not synchronized because it would possibly deadlock with some reply listeners (actually requestors).
      • cleanup

        public void cleanup()
        Aborts all running requests. Used by: 1- close() 2- the connector layer (OutboundConnection.cleanup())
      • abortRequest

        public void abortRequest​(int requestId)
        Not synchronized because it would possibly deadlock with some reply listeners (actually requestors).
      • doAbortRequest

        private ReplyListener doAbortRequest​(int requestId)
      • route

        private void route​(AbstractJmsReply reply,
                           boolean isCompletionListener)
        Not synchronized because it may be called by the demultiplexer during a concurrent close. It would deadlock as the close waits for the demultiplexer to stop.
      • onException

        private void onException​(Exception exc)
      • schedule

        public void schedule​(TimerTask task,
                             long period)
      • setDemultiplexerDaemonName

        public void setDemultiplexerDaemonName​(String name)
      • getDemultiplexerDaemonName

        public String getDemultiplexerDaemonName()