3 ms·
I was once tasked with upgrading a small desktop application used by warehouse workers to fetch imprint data for an apparel printer. The data was stored in a r
by resonious 5y ago
I was once tasked with upgrading a small desktop application used by warehouse workers to fetch imprint data for an apparel printer.
The data was stored in a really inefficient way and so the operation took a stupidly long time. I decided to add a progress bar so that people don't think the app is busted (which they occasionally did). Turned out, much of the time spent was on the server's end, so I couldn't track the majority of the "progress".
I had already put effort into the bar, so I replaced the "real" progress tracking with a script that randomly incremented the progress. I tweaked some heuristics until it roughly matched the amount of time the server tended to take but was random enough to not be super obvious.
After the progress bar launched, someone from the warehouse actually walked up and thanked me for the progress bar.
Of course, that's all fun and games. Weird psychological manipulation in e-commerce is horrible.
- onion2k 5y agoThe fact there isn't a straightforward back-pressure mechanism in browsers to get live updates on how much time is left for an upload or a download is why loading spinners are used everywhere instead of progress bars. You can implement it yourself using websockets and a ton of complexity, but then you need the entire socket tooling and security to be in place. It's one of few the things browsers are really missing in my opinion.
- maccolgan 5y agoYou don't need websockets to simply listen to the ProgressEvent, you should know that. https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/progress_event https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequ...
- onion2k 5y agoThat tells you something is happening, and how much has been done, but not how much work there is left to do, or how much back pressure (load) there is on the server side. Consequently you can't work out how far along the progress is or how long is left. If you assume that there'll be a consistent amount of progress you can guess, but for a large upload (eg gigabytes) you'll usually be wrong. If the server could send data back to update the progress event it would be really nice. Right now though, that can't be done (as far as I know.. maybe there's a way now.. I haven't looked for years.)
- throwawayffffas 5y agoI think that virtually describes almost all progress bars. A better solution is a spinning wheel, because you don't need to figure out how long it would take. You just have to make sure the spinning wheel ocassionally stops and starts again to give users a sense that it's connected to something.
- lelandfe 5y agoIndeterminate loading indicators are only appropriate for short load times. Anything longer and you definitely want to have something to inform the user of a timeline. Even if it’s a bit of a fib.