add bandwidth counter and fix review comments