use class decorator to make singleton, todo