Got basic idea working, but only handles 1 connection at a time.