Added metrics library for statistics tracking