improved pool and added enums