From 63c4e12b57c84de1d82cd17acc4de1ab33b92f75 Mon Sep 17 00:00:00 2001 From: Alessandro Pieve Date: Thu, 23 Feb 2017 10:41:08 +0000 Subject: [PATCH] git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/accounting/accounting-aggregator-se-plugin@144179 82a268e6-3cf1-43bd-a215-b396298e98cf --- .../madeaggregation/Aggregation.java | 3 ++- .../plugin/AccountingAggregatorPlugin.java | 20 +++++++++++++++---- 2 files changed, 18 insertions(+), 5 deletions(-) diff --git a/src/main/java/org/gcube/accounting/aggregator/madeaggregation/Aggregation.java b/src/main/java/org/gcube/accounting/aggregator/madeaggregation/Aggregation.java index f2b944e..c6e1bb9 100644 --- a/src/main/java/org/gcube/accounting/aggregator/madeaggregation/Aggregation.java +++ b/src/main/java/org/gcube/accounting/aggregator/madeaggregation/Aggregation.java @@ -113,8 +113,9 @@ public class Aggregation { //logger.debug("else -- add getAggregatedRecord"); records.add(getAggregatedRecord(record)); } catch (Exception e) { - //logger.debug("else -- add Exception"); + records.add(record); + logger.debug("Exception but records Add e:{}",e); } totalBufferedRecords++; this.bufferedRecords.put(recordType, records); diff --git a/src/main/java/org/gcube/accounting/aggregator/plugin/AccountingAggregatorPlugin.java b/src/main/java/org/gcube/accounting/aggregator/plugin/AccountingAggregatorPlugin.java index baebd32..1241166 100644 --- a/src/main/java/org/gcube/accounting/aggregator/plugin/AccountingAggregatorPlugin.java +++ b/src/main/java/org/gcube/accounting/aggregator/plugin/AccountingAggregatorPlugin.java @@ -24,6 +24,7 @@ import org.gcube.common.scope.api.ScopeProvider; import org.gcube.documentstore.exception.InvalidValueException; import org.gcube.documentstore.persistence.PersistenceCouchBase; import org.gcube.documentstore.records.AggregatedRecord; +import org.gcube.documentstore.records.Record; import org.gcube.documentstore.records.RecordUtility; import org.gcube.vremanagement.executor.plugin.Plugin; import org.slf4j.Logger; @@ -351,7 +352,8 @@ public class AccountingAggregatorPlugin extends Plugin documentElaborate) throws Exception{ - int i=0; + int i=0; + JsonDocument documentJson = null; try { //patch for field of long type String document=row.value().toString().replace("\":", "=").replace("\"", ""); @@ -361,7 +363,7 @@ public class AccountingAggregatorPlugin extends Plugin