Moved connection pool code.