Class StatisticsImporter

java.lang.Object
org.dspace.statistics.util.StatisticsImporter

public class StatisticsImporter extends Object
Class to load intermediate statistics files (produced from log files by ClassicDSpaceLogConverter) into Solr.
Author:
Stuart Lewis
See Also:
  • Field Details

  • Constructor Details

    • StatisticsImporter

      public StatisticsImporter(boolean local)
      Constructor. Optionally loads local data to replace foreign data if using someone else's log files
      Parameters:
      local - Whether to use local data
  • Method Details

    • load

      protected void load(String filename, Context context, boolean verbose)
      Read lines from the statistics file and load their data into solr.
      Parameters:
      filename - The filename of the file to load
      context - The DSpace Context
      verbose - Whether to display verbose output
    • main

      public static void main(String[] args) throws Exception
      Main method to run the statistics importer.
      Parameters:
      args - the command line arguments given
      Throws:
      Exception - If something goes wrong