working gen server but still synchronous.