fixed counters gracefull shutdown issue