5 Replies Latest reply: Nov 11, 2009 1:27 PM by user753546 RSS

    SipApplicationSession expiry

    654136
      What happens to the SipApplicationSession if I don't invalidate it in application & max-application-session-lifetime is not specified in sipserver.xml file OR session-timeout in sip.xml?

      Does it eventually get invalidated ?

      Regards,
      KeDar
        • 1. Re: SipApplicationSession expiry
          user753546
          Yes, SipApplicationSession gets invalidated after default timeout if application doesn't invalidate it programatically.
          Default session-timeout for occas/wlss3.x and before is 30 minutes, while for OCCAS4.0 and onwards is 3 minutes.


          Also session-timeout is dictated by session-timeout in sip.xml where as max-application-session-lifetime is a configuration setting at container level (in sipserver.xml ) which essentially limits the maximum value a deployer can put for session-timeout in sip.xml .This essentially helps in resource management where in deployer is bound to set timeout value withing specified boundaries. Not specifying anything in max-application-session-lifetime means deployer can set any value in sip.xml.

          Hope it helps.

          Anurag Bahl

          Edited by: user753546 on Nov 9, 2009 3:16 PM
          • 2. Re: SipApplicationSession expiry
            654136
            Thanks Anurag !!

            Lets say if I specify 2 mins as max-application-session-lifetime.Will containter invalidate the application sessions 2 minutes after they are created ?

            Our application is doing call controlling for audio calls..As such we can't specify value for session timeout in configuration as we don't know how long calls will go.

            I had posted [similar query |http://forums.oracle.com/forums/message.jspa?messageID=3511832#3511832] on the same lines.
            If I invalidate session programatically on receiving response greater 3xx for INVITE, container complains on receiving ACK as there is no associated session..whats the better way here ?
            • 3. Re: SipApplicationSession expiry
              user753546
              Though I've not checked it , but IMO if you don't specify session-timeout in sip.xml then it defaults to 3 minutes on OCCAS4.0 and if you specify 2 mins as max-application-session-lifetime in sipserver.xml, then container should throw IllegalArgumentException saying that session-timeout cannot be higher than max-application-session-lifetime. Setting max-application-session-lifetime to -1 essentially means infinite .

              So if you session-timeout value configured in 2 or less than two minutes then container will invalidate in that time .
              Now your question
              --------------------------
              Our application is doing call controlling for audio calls..As such we can't specify value for session timeout in configuration as we don't know how long calls will go.
              In those cases it makes sense to keep max-application-session-lifetime to -1 and set session-timeout to fairly large value (may be double than what you expect average call duration to be or more ), but definitely some value, because otherwise if you don't have timeout specified , the session and hence callstate will keep lurking (unless programatically invalidated ) resulting in heap memory issues.

              Hope it answers your query . Which version of sipserver are you on btw.


              Anurag Bahl

              Edited by: user753546 on Nov 10, 2009 2:29 PM
              • 4. Re: SipApplicationSession expiry
                654136
                We are using WLSS 3.1- MP1.

                Btw, how reliable are the counters on the admin console's "SIP Server -> Monitoring" page ?
                They look fishy sometimes..I get negative Active Sessions count as well.

                -KeDar
                • 5. Re: SipApplicationSession expiry
                  user753546
                  ActiveSessionCount parameter is something deprecated because in a replicated environment where one engine can process timers created by other engine even though that engine did not create that application session can cause issues domain wide as it decrements active session even if it never created it . So to take care of this situation DestroyedServerAppSessionCount and DestroyedServerSipSessionCount were introduced.

                  So ideal way to get the actual active session count (system wide..i mean across all engine nodes in case of replicated setup) is to use following counts

                  DestroyedServerAppSessionCount;
                  ServerAppSessionCount;

                  So active app session count at any time is (ServerAppSessionCount - DestroyedServerAppSessionCount)

                  DestroyedServerSipSessionCount;
                  ServerSipSessionCount

                  So active sip session count at any time is (ServerSipSessionCount - DestroyedServerSipSessionCount)


                  I believe this should never report negative values. I hope it answers your query. If yes, please mark the answer as correct/

                  PS: In general it is good if different topics are dealt in different forum message as that way we have content specific to that issue in forums and it helps users.

                  Anurag Bahl

                  Edited by: user753546 on Nov 11, 2009 11:27 AM