Live data from Hacker News

Gridlock vs. Bottlenecks: A visual explanation

setosa.io

1–10 of 18 posts

Re: Gridlock vs. Bottlenecks: A visual explanation

#2
Also a great way of visualizing some basic problem with concurrency.

Gridlock is excellent demonstrated as above, if you are putting things in a queue for a thread that is taking forever to run, the producer thread will eventually (hopefully) be blocked due to memory issues, thus passing the slow down further up the chain. Much like a road, and exactly like the visual effect seen here.

Re: Gridlock vs. Bottlenecks: A visual explanation

#3
I like how dynamics of complex systems are getting so captivating and easy to understand by visually simplified simulations rather than mathematical expressions.

The human mind somehow grasps these dynamic, subconsciously creates an in-brain simulation and you can predict what will happen when you play with the parameters on the computer simulation. It just feels so natural.

Re: Gridlock vs. Bottlenecks: A visual explanation

#4
post #3

I like how dynamics of complex systems are getting so captivating and easy to understand by visually simplified simulations rather than mathematical expressions. The human mind somehow grasps these dynamic, subconsciously creates an in-brain simulation and you can predict what will happen when you play with the parameters on the computer simulation. It just feels so natural.

Its too bad there is only one lane of traffic in the simulators. There are interesting insights to be had when simulating multiple lanes and adding "incentive" lanes. One of the first Java applets was a multi-lane simulator which showed the impact of people getting on to a 4 lane freeway, merging all the way across to the HOV lane on the left, then merging all the way across again to get off. Versus having the HOV lane on the right, vs having no HOV lanes.

The fun stuff is that queuing theory applies to all sorts of things like packets and getting seats on an airline. Lots of fun to play with.

Re: Gridlock vs. Bottlenecks: A visual explanation

#7
This is just an excellent visualization to explain a concept that is hard to imagine.

Lots of difficult concepts are actually very simple once you boil them down to the fundamentals and visualize them.

This has big implications for education. Many concepts like derivatives in finance, algorithmns in computer science are suprisingly simple.

I remember a visualization for Paxos (a distributed consensus algorithmn) which basically have an actor to represent each node in the network. That was the moment I finally "got it".

It is a shame that educators are still so backwards at how they communicate concepts to students. and how ineffective that is. I think it comes down to the fact that professors in universities have to play dual role of being a researcher + to teach. And since they are recognized for publishing papers and not so much for making helpful visualzations to explain concepts to first year students. Education part is neglected.

Re: Gridlock vs. Bottlenecks: A visual explanation

#9

Has anyone had an experience of "gridlock" in a distributed system? Where bottlenecks cascade due to failover, etc?

"Deadlock" is the term used in concurrent processing. It can happen if the resources are distributed. I actually had the privilege of troubleshooting such an issue not too long ago: http://dba.stackexchange.com/q/73833
Post reply on HN