Refactor/jdbc api

Refactor JDBC API to implement connection pooling mechanism.