Simple bandwidth / latency test to estimate a users experience

断了今生、忘了曾经 提交于 2020-01-01 12:03:08

问题


I write web based applications. Performance is obviously a key factor. Whilst database load and page rendering time are things I have control of, the users internet connection is not.

What I'm looking for is a way to indicate what sort of a connection a user has. Something along the lines of a traffic light in the corner of a website that shows the user what sort of a connection they have to the site and therefore indicating what sort of perceived performance they should expect. e.g. Maybe the app just seems slow because everyone else in your company is browsing facebook on their lunch hour.

My initial thoughts are that this could be achieved by some javascript that runs on each page load.

Ideally the code is very "dropable" and does not require major code or infrastructure changes to implement.


回答1:


This seems like something you could use. You could also time an AJAX request; how long is the round trip? You'll probably have to establish some benchmarks on your own.



来源:https://stackoverflow.com/questions/465314/simple-bandwidth-latency-test-to-estimate-a-users-experience

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!