RE: RE: remember me and session.auto.extend will cause submit form not working

Václav Suchánek, modified 1 Year ago. Junior Member Posts: 26 Join Date: 8/15/18 Recent Posts

Hello,

There is some scenario that troubles our customers. A lot of people are writing long blog posts, wiki pages, comments etc. When blog posts are pretty long then it takes longer (hours) than it is expected. They will return to their content and publish it -> and the content is lost. I will give you some steps as to why it is happening.

Env:
session.timeout.auto.extend=true
session.timeout=1
allow "rememberme" as a part of your login page

Steps to reproduce:
1) Login to portal with "rememberme" checked
2) Go to wiki module and "Add child page"
3) wait 1 minute
4) Submit your content with "Submit for publication"
5) You are redirected to Wiki Display
6) See there is no content added

Affected modules:
Message Boards, Knowledge Base, Blogs, Comments etc.

Conclusion:
After some testing we thought there was a problem with the session timeout. But the real problem seems to be in "rememberme" functionality. Where combination session.auto.extend=true and "rememberme" will cause the submit button won't submit the content.

What to do:
The best way how to handle this is to disable "rememberme" for us. But there are a lot of users using it I guess. On the other hand it is facing like Liferay bug so that is why I'm sharing this with you. I would expect to throw some warning (session is expired) at least before the content is lost.
 

thumbnail
Olaf Kock, modified 1 Year ago. Liferay Legend Posts: 6441 Join Date: 9/23/08 Recent Posts

I couldn't reproduce this with blogs in the current version (which changes the timeout-settings to now be in InstanceSettings instead of portal-ext.properties).

Please notice that "Submit for publication" is a sign that the content is subject to Workflow - so it might not be lost, but just require approval. Can you check this?

Václav Suchánek, modified 1 Year ago. Junior Member Posts: 26 Join Date: 8/15/18 Recent Posts

Hello Olaf,

Yes I agree with you - there is some configuration on our side + our instance is not the latest (7.4.3.59).

But I can feel there is something wrong, so I made a new investigation with a fresh instance and I can see there are some issues (not with blogs but other modules are affected).

Steps to reproduce:
1) Download 7.4.3.112 from https://github.com/liferay/liferay-portal/releases/download/7.4.3.112-ga112/liferay-ce-portal-tomcat-7.4.3.112-ga112-20240226061339195.tar.gz
2) Modify web.xml -> <session-timeout>1</session-timeout>
3) Start tomcat
4) Setup your first start configuration
5) Instance Settings -> Infrastructure -> Session Timeout -> Auto Extend Offset: 10, Auto Extend: check -> Save
6) Setup Wiki Display module (test if you can add a child page)
7) Sign out -> Sign In with "remember me" checked
8) Go to Wiki Display -> Add Child Page -> fill title and body -> move your cursor to Publish button
9) wait 1 minute
10) Click on Publish button
11) See there is no content added

Note: content is added OK if "remember me" is unchecked

Tested modules:
Wiki -> positive
Message Boards -> positive
Blogs -> negative
comments -> positive (add a comment to Wiki page)

thumbnail
Jamie Sammons, modified 1 Year ago. Expert Posts: 367 Join Date: 9/5/14 Recent Posts

Would this be a feature request or more of a bug?

Václav Suchánek, modified 1 Year ago. Junior Member Posts: 26 Join Date: 8/15/18 Recent Posts

It definitely looks like a bug.