[DS-3832] Upgrade to GeoIP2.

This commit is contained in:
Mark H. Wood
2018-03-21 15:49:38 -04:00
parent c3d567c31e
commit 074337f167
7 changed files with 194 additions and 83 deletions

View File

@@ -7,6 +7,9 @@
*/
package org.dspace.statistics;
import java.io.File;
import com.maxmind.geoip2.DatabaseReader;
import org.dspace.services.ConfigurationService;
import org.springframework.beans.factory.InitializingBean;
import org.springframework.beans.factory.annotation.Autowired;
@@ -21,9 +24,9 @@ public class MockSolrLoggerServiceImpl extends SolrLoggerServiceImpl implements
@Override
public void afterPropertiesSet() throws Exception {
//We don' use SOLR in the tests of this module
//We don't use SOLR in the tests of this module
solr = null;
locationService = new MockLookupService();
locationService = new DatabaseReader.Builder(new File(".")).build();
useProxies = configurationService.getBooleanProperty("useProxies");
}