Here's the scenario (sorry, but this will be a theoretical question).
I am developing a web application for e-commerce web applications that typically handles 5,000-6,000 users , but there are several cases where the number of users can exceed 600 thousand .
I have a web form consisting of more than 25 fields. I have several fields for uploading images and documents, when on the server a heavy form of loading takes more than 5 minutes to get an answer .
Therefore, here the problem that I encounter during the processing of the request, considers that several users are impatient and can press the submit button again and again . In this case, I unnecessarily increase the load. I want to block all other duplicate requests.
So how do I solve this situation?
I heard about interceptor token and tokenSession
<interceptor-ref name="token"></interceptor-ref>
<interceptor-ref name="tokenSession"></interceptor-ref>
But I assume that these interceptors only handle re-sending and re-sending. in fact, I tried the implementation mentioned in the link below.
http://www.journaldev.com/2281/struts2-token-interceptor-to-handle-double-form-submission-problem
[Change]:
Forms after user login should have a token value, which should change for each page refresh, and should be checked on the server side whether its server-side valid token should be set for that particular user or not or the proper implementation of the interceptor. This is to avoid sending our form from external websites. I hope you understand.