prototype of echo server + statistics module

performance improvements of IdRange