https://susam.net/maze/wall/comfort-of-bloated-web.html Comfort of Bloated Web By Susam Pal on 12 Mar 2022 There is a tiny comment form application on this website to accept comments from visitors and save them on the file system of the web server for me to review later and publish. This form is one of the only two things on this website that is dynamic in nature. The other dynamic part is the subscription form. Everything on this website other than these two things are static in nature. Mysterious Copies Most of this website is made of handcrafted HTML. The blog posts and other content files are handcrafted HTML pages. A Common Lisp program adds common headers and footers to these pages and generates the HTML pages that are served as static files via Nginx. The comment form, however, is a dynamic web application served via another Common Lisp program that makes use of the Hunchentoot web server to serve the form, accept the input submitted by the user, and then process it. This comment form is a very simple application that fulfills the modest requirements of this modest website pretty well. However, often I see multiple copies of the same comment being saved on my web server. In the initial days of encountering this issue, I felt quite confused. I could rule out a bug in my program by carefully reviewing and testing it. Further, the web server logs clearly showed multiple POST requests being received by it from the same client usually with a few seconds of intervals between the consecutive requests. The comments seemed to have legitimate content. Since the duplicate copies would all have the same comment, I would arbitrarily pick one and publish it on my website. But I often wondered why on earth well meaning visitors would sometimes submit the same comment multiple times. For good measure? Perhaps! But still quite odd! So What's the Problem? The mystery of duplicate comment submission remained a puzzle for several months. Then one day, one of the visitors to my website contacted me via Twitter messages to tell me that my comment form was broken and it was not working for him. The conversation began like this: "Hey! The comment form on your website seems to be broken. It says it has accepted my comment but I don't think it is doing that." I responded, "Hi! Thank you for contacting me about this issue. What do you mean it does not accept your comment? Do you see an error?" "There is no error. In fact, after submitting, I get a success message that says, 'Comment was submitted successfully. It may be published after review.'" "That sounds about right. So what's the problem?" In the meantime, I performed some testing at my end to find that the comment form appeared to be working fine with no apparent issues. Further, I found that there were multiple copies of his comment saved neatly on the server for me to review later and publish. Before I could share my findings, he continued, "Well, that success message appears almost instantly. It couldn't be storing my comment successfully that fast, could it?" That is when the mystery unfolded for me! The issue was that the comment form accepts the user's comment and returns with a success message too soon for the user to believe that it could have possibly saved the comment. I have had a couple of other very similar conversations since then when a visitor contacted me via email or another means to double-check if my comment form was really working fine. In all of these cases, they were skeptical about the success message because it appeared much sooner than they expected. Bloated Expectations To be honest, I found this experience to be quite bizarre. The comment form on this website takes anywhere between fifty milliseconds to a few hundred milliseconds to accept the user's comment, save it successfully, and then display a success message to the user. But apparently, a few hundred millseconds is too fast for many people to be able to trust that the comment application is actually doing its job. I presume that they have become so used to waiting for at least a second or more for dynamic pages to load that a web application that finishes its job in a few milliseconds appears to be fishy. I had one visitor to my website even say, "I really was expecting a spinning wheel on the browser tab or some sort of progress indicator to be assured that it is saving my comment. The instant success message took me by surprise!" He felt nervous that his comment was not saved and resubmitted the comment again. As a result of these conversations, I have sometimes even wondered whether I should add some artificial delay in the comment application before responding with a success message to satisfy the expectations of people who are so used to the bloated web. Of course, I am not going to do that. That would be silly. I am going to keep the comment form in its current shape, as uncomfortable as its quickness might be to some users. However, I cannot help but remark that the users of the web today have become so comfortable with the bloated web that a simple web application that is fast and responsive makes them nervous! Comments --------------------------------------------------------------------- Home Wall Feed Subscribe About GitHub Twitter (c) 2001-2022 Susam Pal