Part 2 of 2-part commit for fixing LOG4J2-407, LOG4J2-438, LOG4J2-442, LOG4J2-457, and LOG4J2-489: Changed database appenders to connect (borrow from pool) on every flush or every non-buffered writeInternal.

git-svn-id: https://svn.apache.org/repos/asf/logging/log4j/log4j2/trunk@1565878 13f79535-47bb-0310-9956-ffa450edef68