extract pool initialization to methods
remove early pool initialization