container_ptr resfactoring