Re: [pgAdmin][RM5000] Logout the inactive session
Dave Page <[email protected]> Wed, 15 Jan 2020 07:57:20 +0000
| Newsgroups | gmane.comp.db.postgresql.pgadmin.devel |
|---|---|
| Message-ID | <CA+OCxozR_Kv3djDXr4fdeHU+RmPa2wdqVupTdge1t1jqHRwgaw@mail.gmail.com> |
--0000000000009231aa059c290fbd Content-Type: text/plain; charset="UTF-8" Hi On Mon, Jan 13, 2020 at 7:04 PM Aditya Toshniwal < [email protected]> wrote: > Hi Hackers, > > Attached is the patch for the feature where inactive session will be > logged out. Note that, here inactive session means no user activity of > mouse move, click or keypress. > I've introduced two config params: > 1. USER_INACTIVITY_TIMEOUT - Interval in seconds for the timeout. Default > is 0-Zero which means disabled. > 2. OVERRIDE_USER_INACTIVITY_TIMEOUT - If set to true, tools like query > tool or debugger will override USER_INACTIVITY_TIMEOUT and will not allow > the application to timeout if a query is running for a long time. > > The patch also speeds up running jasmine test cases. With webpack 4, the > default mode is changed to production instead of development unlike > previous versions. Mode is set to development explicitly to improve the > speed. > Per our discussion in the office, here's the suggested wording for the config option descriptions: +# USER_INACTIVITY_TIMEOUT is interval in Seconds. If the pgAdmin screen is left +# unattended for <USER_INACTIVITY_TIMEOUT> seconds then the user will +# be logged out. When set to 0, the timeout will be disabled. *# If pgAdmin doesn't detect any activity in the time specified (in seconds), the user will +# be forcibly logged out from pgAdmin. Set to zero to disable the timeout. +USER_INACTIVITY_TIMEOUT = 0 + +# OVERRIDE_USER_INACTIVITY_TIMEOUT when set to True will override +# USER_INACTIVITY_TIMEOUT when long running queries in the Query Tool +# or Debugger are running. When the queries complete, the inactivity timer +# will restart in this case. If set to False, user inactivity may cause transactions +# or in-process debugging sessions to be aborted. +OVERRIDE_USER_INACTIVITY_TIMEOUT = True -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company --0000000000009231aa059c290fbd Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div>Hi</div><br><div class=3D"gmail_quote"><div dir=3D"lt= r" class=3D"gmail_attr">On Mon, Jan 13, 2020 at 7:04 PM Aditya Toshniwal &l= t;<a href=3D"mailto:[email protected]">aditya.toshniwal@ent= erprisedb.com</a>> wrote:<br></div><blockquote class=3D"gmail_quote" sty= le=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);paddi= ng-left:1ex"><div dir=3D"ltr"><div style=3D"font-family:verdana,sans-serif"= >Hi Hackers,</div><div style=3D"font-family:verdana,sans-serif"><br></div><= div style=3D"font-family:verdana,sans-serif">Attached is the=C2=A0patch=C2= =A0for the feature where inactive session will be logged out. Note that, he= re inactive session means no user activity of mouse move, click or keypress= .</div><div style=3D"font-family:verdana,sans-serif">I've introduced=C2= =A0two config params:</div>1. USER_INACTIVITY_TIMEOUT<span class=3D"gmail_d= efault" style=3D"font-family:verdana,sans-serif"> - Interval in seconds for= the timeout. Default is 0-Zero which means disabled.</span><br>2.<span cla= ss=3D"gmail_default" style=3D"font-family:verdana,sans-serif"> </span>OVERR= IDE_USER_INACTIVITY_TIMEOUT<span class=3D"gmail_default" style=3D"font-fami= ly:verdana,sans-serif"> - If set to true, tools like query tool or debugger= will override USER_INACTIVITY_TIMEOUT and will not allow the application t= o timeout if a query is running for a long time.</span><div><font face=3D"v= erdana, sans-serif"><br></font></div><div><font face=3D"verdana, sans-serif= "><span class=3D"gmail_default" style=3D"font-family:verdana,sans-serif">Th= e patch also speeds up running jasmine test cases. With webpack 4, the defa= ult mode is changed to production instead of development unlike previous ve= rsions. Mode is set to development explicitly to improve the speed.</span><= /font></div></div></blockquote><div><br></div><div>Per our discussion in th= e office, here's the suggested wording for the config option descriptio= ns:</div><div><br></div><div>+# USER_INACTIVITY_TIMEOUT is interval in Seco= nds. If the pgAdmin screen is left<br>+# unattended for <USER_INACTIVITY= _TIMEOUT> seconds then the user will<br>+# be logged out. When set to 0,= the timeout will be disabled.</div><div>*# If pgAdmin doesn't detect a= ny activity in the time specified (in seconds), the user will</div><div>+# = be forcibly logged out from pgAdmin. Set to zero to disable the timeout.<br= >+USER_INACTIVITY_TIMEOUT =3D 0<br>+<br>+# OVERRIDE_USER_INACTIVITY_TIMEOUT= when set to True will override</div><div>+#=C2=A0USER_INACTIVITY_TIMEOUT w= hen long running queries in the=C2=A0Query Tool</div><div>+# or Debugger ar= e running. When the queries complete, the inactivity=C2=A0timer</div><div>+= # will restart in this case. If set to False, user inactivity may cause tr= ansactions</div><div>+# or in-process debugging sessions to be aborted.<br>= +OVERRIDE_USER_INACTIVITY_TIMEOUT =3D True<br></div><div>=C2=A0</div></div>= -- <br><div dir=3D"ltr" class=3D"gmail_signature">Dave Page<br>Blog: <a hre= f=3D"http://pgsnake.blogspot.com" target=3D"_blank">http://pgsnake.blogspot= .com</a><br>Twitter: @pgsnake<br><br>EnterpriseDB UK: <a href=3D"http://www= .enterprisedb.com" target=3D"_blank">http://www.enterprisedb.com</a><br>The= Enterprise PostgreSQL Company<br></div></div> --0000000000009231aa059c290fbd--