Another databases

If we analyze the class diagram that's part of the documentation set, we can see that there is a dotted line that divides two sections of the diagram. The bigger one is the database independent code, and the smaller (down left) one is the Postgres one. You have to take in consideration that this second part doesn't depend on Postgres libraries, because the small protocol handling parts are directly implemented in the code.

So, what would be needed to implement support for another database? Well, there a virtual C++ class, called DBPooledConnection. We have implemented it with two subclasses DBPostgresPooledConnection and DBPostgresWriterConnection, that are used to serve read-only and write connection requests. Another database support could be done by implementing again this virtual class, giving an alternate resolution to the, Postgres specific, opening and closing of client and backend connections. Then it would be necessary to implement the actual choice of databases, that's not still in place ;-).