class DatabaseConnector {

  public void removeOutdatedVersionsFromBlacklistentry()
  {
    List<Long> blacklistversions = jdbcTemplate.queryForList("SELECT DISTINCT BLACKLISTVERSION FROM BLACKLISTENTRY",
                                                             Long.TYPE);
    if (blacklistversions.size() > 1)
    {
      Long currentBlacklistversion = Collections.max(blacklistversions);
      int rowsAffected = jdbcTemplate.update("DELETE FROM BLACKLISTENTRY WHERE BLACKLISTVERSION <> ?",
                                             currentBlacklistversion);
      log.info("Deleted {} entries with outdated Blacklist versions from Blacklistentry", rowsAffected);
    }
    else
    {
      log.info("No entries with outdated Blacklist versions found.");
    }
  }

  public  DatabaseConnector(JdbcTemplate jdbcTemplate);

}