mysql encapsulation and a db connection pool