created buffer class and threads