14 Replies Latest reply: Feb 19, 2018 4:54 AM by Yakir Manor RSS

    Qliksense inactivity session timeout

    maria francesca pisu

      Hi,

      can anyone tell me how to set session limit timeout in qmc?

      I need to set limit to 10 minutes.

       

      Thanks a lot

      Fra

        • Re: Qliksense inactivity session timeout
          Mohit Dahiya

          In the QMC, you will find a setting when working with Virtual Proxies called "Session inactivity timeout (minutes)".  This is where you can change this.

           

          Be aware that it may affect consumption of login tokens.  Perhaps someone else can address this if you have questions.  There is also some good information (as far as I can tell) at User Session - Time Out?.

           

          Mohit

          • Re: Qliksense inactivity session timeout
            rohit kumar

            Hi Maria,

             

            In the QMC, you will find a setting when working with Virtual Proxies called "Session inactivity timeout (minutes)".  This is where you can change this.


            Please mark the appropriate replies as CORRECT / HELPFUL so our team and other members know that your question(s) has been answered to your satisfaction.

             

             

            Rohit Kumar

            • Re: Qliksense inactivity session timeout
              Mohit Dahiya

              A good explanation is in the help of the QMC, upper right corner. Shortcut:http://localhost:4780/QMCHelp/default_Left.htm#CSHID=QMC_System_Setup_QlikViewServers_Performance.htm|StartTopic=Content…

              . Yes, it can be done. The QVS should say within the working set limits, so it should be fine. Usually you can set those values to 0 and it should be fine. There are also some more timeouts, in the QVWS and if you are using IIS, it has some too.

               

              QVS, DSC and QVWS additional timeouts (apart from the ones you mentioned):

              QVS

                  Document Timeout    Found at: C:\ProgramData\QlikTech\QlikViewServer\settings.ini    Default value: 3600(seconds)   

                                 

              DSC

                  Cache expiration    Found at: QEMC > System> Setup > DSC@ > Active Directory > General > Edit icon    Default value: 60(minutes)   

                   Service timeout     Found at: QEMC > System> Setup > DSC@ > Active Directory > General > Edit icon    Default value: 30(seconds)   

                                 

              Webserver             

                   QVS Timeout    Found at: C:\ProgramData\QlikTech\WebServer\config.xml    Default value: 120(seconds), Time webserver will wait on response from QVS

                   Sessioncookietimeout    Found at: C:\ProgramData\QlikTech\WebServer\config.xml    Default value: 30(minutes)

              • Re: Qliksense inactivity session timeout
                Yakir Manor

                this is indeed a bit annoying and the answers here did not help,

                we're using the mashup option and it keeps disconnecting after 60 seconds of inactivity (not selecting anything in the model),

                this is what we get:

                "

                An error occurred

                Connection lost. Make sure that Qlik Sense is running properly. If your session has timed out due to inactivity, refresh to continue working.

                "

                luckily everything has a work around and a good one (:

                 

                so the deal is that as long as you provoke the web socket the connection will stay open, so just provoke it,

                this is how its done:

                create a variable in your model (Data Load Editor or in the bottom left of the sheet after pressing edit),

                now create a KPI and put the variable in the kpi

                last thing, put the qlik object on the top page and create a set interval

                 

                var qlikapp = null;
                require( ["js/qlik"], function ( qlik ) {
                qlik.setOnError( function ( error ) {
                  $( '#popupText' ).append( error.message + "<br>" );
                  $( '#popup' ).fadeIn( 1000 );
                } );
                $( "#closePopup" ).click( function () {
                  $( '#popup' ).hide();
                } );
                
                
                //callbacks -- inserted here --
                //open apps -- inserted here --
                qlikapp = qlik.openApp('4287ca1c-9b53-45dc-afe2-55f8e69af7f2', config);
                //get objects -- inserted here --
                qlikapp.getObject('QV01','fkAQBG');
                qlikapp.getObject('CurrentSelections','CurrentSelections');
                //create cubes and lists -- inserted here --
                } );
                
                
                setInterval('KeepSessionAlive()', 5000);
                function KeepSessionAlive() {
                if (qlikapp) {
                  //alert(getTime());
                  qlikapp.variable.setStringValue('Current Time', getTime());
                }
                return false;
                }
                
                
                
                
                
                
                

                 

                but do you really want to keep the socket open all the time?

                this is an optimization question, if all the users use a named license then sure! but what if you convert some of them to Login Access Tokens? (you get 10 hours per month for each license)

                this could be a waste of license time, so show some creativity, to my opinion 5 minuets of inactivity counted from the last mouse move on the page for login access user, and unlimited keep alive (until the window is closed for User access) is the best way to go.

                 

                this is a basic code for mouse move (i used it in qlikview i frame to keep the login alive):

                var keepSessionAliveBool = false;
                SetupSessionUpdater();
                function SetupSessionUpdater() {
                //...set the event that makes the keep alive
                var container = $("#QvBody");
                container.mousemove(function() {
                  keepSessionAliveBool = true;
                });
                container.keydown(function() {
                  keepSessionAliveBool = true;
                });
                CheckToKeepSessionAlive();
                return true;
                }
                
                
                function CheckToKeepSessionAlive() {
                setTimeout("KeepSessionAlive()", 30000); // // 1000 is every second
                return true;
                }
                
                
                function KeepSessionAlive() {
                CheckToKeepSessionAlive();
                if (keepSessionAliveBool) {
                  window.parent.postMessage("KeepSessionAlive", "*");
                  keepSessionAliveBool = false;
                  return true;
                }
                return false;
                }
                
                
                
                
                
                
                • Re: Qliksense inactivity session timeout
                  Yakir Manor

                  the root cause for this issue might also be load balancer (we use aws) and not qlik sense,

                  see:

                  Elastic Load Balancing Connection Timeout Management | AWS News Blog

                   

                  console_elb_conn_settings_2.png