4 replies
by lo
Interesting
You could probably do one with minimal effort (easy for me to say, I am not coding). As you most likely know or can obtain the size of the transfer, you can put in a delay timer to simulate the speed of the line. An example (top ofmy head so may have some logic, etc. bugs).
1) user accesses page
2) program obtains data but holds in buffer with size calc for text, graphics, etc.
3) Setting (from somewhere), indicates 56kbit line at 33.6kbits actual
4) N bytes at 33.6 kbit/sec would take Y seconds to transfer ((bytes * 10) / 33.6)
5) set a timer (or whatever) and every N seconds, transfer and display an appropriate amount of data to simulate the transfer.
Same setup but with a 256kbyte. Same process, just more transferred in given interval. Transfer calc changes, instead of 2 bits or so per character, there is just packet overhead in addition to the data.
You could get fancy, put in some timers (random or predefined every N seconds, server peaks and runs with some known delay) to simulate the load of server (in addition to above, just wait for some period of time to simulate queue / traffic / collision / reroute / etc.)
by beichinger
by gijoe
by beichinger
This discussion is closed to new replies.
Trending Web Development posts
Sort by Trending