Need to forcefully log off operator's active session, if more than 10 hours
We have a requirement to logout user active session which is more than 10 hours. Please note it's different from idel session time out at access group level which Pega provides. We need to forcefully log off operator's active session after 10 hours.
We need help on how to achieve it.
As of now we have tried following ways:
1. We treid to put somethig on UI level on click of existing button or some control we will run our activity and trigger pega's log off action in OOTB when the hours is more than 10. This will be placed in such a place where we are sure user will click or hover every now and then. This apparoach is not recommended as e are unsure which UI user will use more and most feequently. This approach worked though.
2. Apprach 3 we tried to edit user work from and written a script to click a button which will be invisible on UI. On click of that button our time checking activity fires and then log off triggers if time is more than 10 hours. This worked too Now we have a situation, we are unsure where are the places on UI we may put this button.As we are platform team, we have many clients who will extend our platfrom and build their own application, so UI or portal will not be consistent in that case and change from time to time.
Something seems odd about this requirement. So after working grulling 9 hour and 59 minute day, your active user is going to be abruptly logged off? I'm confused. This would, by definition, loose in flight data entry.
These are real world requirements. Please send them to your product team to handle eventualities or bizarre events that clients want us to implement, that will make end users lose access to flight data entry. Instead of making fun of the requirements, you should come and explain to the clients the technical reasons why we should not implement something and then see if they buy your explanations or answers.
One suggestion I have is instead of the user actually clicking any where on the UI for your activity to trigger, write an agent activity which triggers a (smart) pop up and alerts the user that he is about to be logged off (like many banking applications which inform the user for their session ending) .
Basically the trigger point is not the UI click but the count down timer itself, which is activated at the (time of) login session of the user. This will separate the platform dependence from the UI as each user will have to login, irrespective of the portal they have been assigned to.
I have added a comment on your question in below link. Please see if that is helpful. If that is working, we just have to change call back mentioned in step #2 in that to do log off instead of calling a local action.
Killing a requestor session abruptly is not a hard thing to do. But, i hope you have reached out to your clients with a proper reasoning of not doing this. As already mentioned in some of the replies, if a user session is active and it's 9 hrs already, just present a pop-up for the requestor to continue working or log off. This makes more sense than killing the requestor.