If you talk about Ajax requests you could solve that by using AjaxChannel.ACTIVE setting. The JavaScript logic will ignore any Ajax request in the same channel if there is an active request at the moment.
I guess you could reuse it for non-Ajax links by intercepting their click event. On Mon, 24 Nov 2025 at 10:55, Martijn Dashorst <[email protected]> wrote: > In our application sometimes a user clicks double when a request takes > long, or they are using windows clicking behavior (double click). > > This is unfortunate as the server is processing the request twice, and one > of them is discarded in the bit-void due to no browser listening for the > response... > > I know it is a bad idea to link request threads together, but... with the > current pagelock mechanism we already do that in a sort of way. > > What if we were to keep a map of in progress (non-multipart for now) > requests parameters and the threads that are processing them, and when a > duplicate comes in for the same session, we subscribe to a future of the > original response, and respond with that to the browser? > > Martijn >
