JonnyGar Member since 2009 91 posts
BNY Mellon
Posted: 5 years ago
Last activity: 5 years 6 months ago

Auth / Lock Timeouts

We've been looking to rationalize the timeouts for external authentication as well as locking.

One thing we've brought up in a few channels (see Continued support for Extending Locks? ) was that an under-documented feature of LockManager.lock() before lockCache was that you could extend the lock window for a current lock. Assuming you had a really narrow window for lock timeouts, this might be a good thing.

We've done this by replacing desktop_restartTimeoutWarningTimer -- our new one works in much the same way, with some variations. We have seen success of this on Dev, though mixed results on QA with times of an hour. If we can get this working solidly, we could bring down the extension times to 20m, and thus mitigate the exposure of leaving items unlocked (due to failure to close).

There are some gaps in this implementation. We're counting on a desktop timer to track when server hits are made. So this needs to run when Ajax calls are made.

This is where desktop_restartTimeoutWarningTimer is called, to reset the timer. We do see this called for Ajax requests. But we also see it running in some likely unforeseen places. For example, when using the standard event/action combo of Hover/Show smart tip, and the user does a mouseover here, the JS function stack will end up calling desktop_restartTimeoutWarningTimer. So this would effect our timeout warning for auth (and for locks).

Here's the generated HTML. It looks like showSmartTip could potentially call via Ajax, but in this case it reads it from somewhere in the DOM.

<span data-ctl='Text' data-hover='[["showSmartTip",[":event","","^~pyWorkPage.LeadForm.UserID~^"]]]' onmouseover = 'pega.c.cbe.processBehavior(event, "data-hover")' class='leftJustifyStyle' >

And the stacktrace -- from IE, I can't see how to copy the text, but I can copy the image here. As noted, we reassigned desktop_restartTimeoutWarningTimer to our own version here, where I put the breakpoint in.

The break happens when I hover over.


Added HTML & JS stacktrace.

[Updated by Jon Garfunkel on March 16th, to update the link to the related question/thread regarding lock extension]

***Updated by moderator: Marissa to close post***
This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.
Case Management
Moderation Team has archived post
Share this page LinkedIn