public static boolean isDbAvailable() {
        final ConnectionConfig connectionConfig = createConnectionConfig(new CommonDbConfig());
        final ConnectionConfig rootConnectionConfig = createRootConnectionConfig(connectionConfig);

        // Create new db.
        final Properties connectionProps = new Properties();
        connectionProps.put("user", rootConnectionConfig.getUser());
        connectionProps.put("password", rootConnectionConfig.getPassword());

        try (final Connection connection = DriverManager.getConnection(rootConnectionConfig.getUrl(),
                connectionProps)) {
            return connection.isValid(5);
        } catch (final SQLException e) {
            return false;
        }
    }
Verify there is a connection to the database on the root account.
stroom-test-common/src/main/java/stroom/test/common/util/db/DbTestUtil.java