java.lang.Object
org.gcube.accounting.aggregator.aggregation.Aggregator

public class Aggregator extends Object
Author:
Luca Frosini (ISTI - CNR)
  • Field Details

    • aggregationStatus

      protected final AggregationStatus aggregationStatus
    • originalRecordsbackupFile

      protected final File originalRecordsbackupFile
    • aggregateRecordsBackupFile

      protected final File aggregateRecordsBackupFile
    • malformedRecordsFile

      protected final File malformedRecordsFile
    • estimatedRecordsNumber

      protected int estimatedRecordsNumber
    • originalRecordsNumber

      protected int originalRecordsNumber
    • malformedRecordNumber

      protected int malformedRecordNumber
    • objectMapper

      protected org.gcube.com.fasterxml.jackson.databind.ObjectMapper objectMapper
    • startTime

      protected Calendar startTime
    • skipAggregation

      protected boolean skipAggregation
  • Constructor Details

    • Aggregator

      public Aggregator(AggregationStatus aggregationStatus, File originalRecordsbackupFile, File aggregateRecordsBackupFile)
  • Method Details

    • setSkipAggregation

      public void setSkipAggregation(boolean skipAggregation)
    • aggregate

      public void aggregate() throws Exception
      Throws:
      Exception
    • elaborateRow

      protected void elaborateRow(org.gcube.com.fasterxml.jackson.databind.node.ObjectNode content, AggregatorBuffer aggregatorBuffer) throws Exception
      Throws:
      Exception
    • addProperty

      protected void addProperty(org.gcube.com.fasterxml.jackson.databind.node.ObjectNode objectNode, String key, Object value)
    • getCalendar

      protected Calendar getCalendar(OffsetDateTime offsetDateTime)
    • retrieveAndAggregate

      protected void retrieveAndAggregate(ResultSet resultSet) throws Exception
      Throws:
      Exception
    • aggregateRow

      protected void aggregateRow(AggregatorBuffer aggregatorBuffer, String json) throws Exception
      Throws:
      Exception