From db53e6fa81440097f45d35cf6ec5fbc639346805 Mon Sep 17 00:00:00 2001 From: Luca Frosini Date: Mon, 22 Mar 2021 12:00:21 +0100 Subject: [PATCH] Changed method --- .../persistence/AccountingPersistenceBackendQuery.java | 3 ++- .../analytics/persistence/AccountingPersistenceQuery.java | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/main/java/org/gcube/accounting/analytics/persistence/AccountingPersistenceBackendQuery.java b/src/main/java/org/gcube/accounting/analytics/persistence/AccountingPersistenceBackendQuery.java index 19bc7e4..750cf20 100644 --- a/src/main/java/org/gcube/accounting/analytics/persistence/AccountingPersistenceBackendQuery.java +++ b/src/main/java/org/gcube/accounting/analytics/persistence/AccountingPersistenceBackendQuery.java @@ -18,6 +18,7 @@ import org.gcube.accounting.analytics.exception.KeyException; import org.gcube.accounting.analytics.exception.ValueException; import org.gcube.accounting.datamodel.BasicUsageRecord; import org.gcube.documentstore.records.AggregatedRecord; +import org.gcube.documentstore.records.Record; /** * @author Luca Frosini (ISTI - CNR) @@ -210,7 +211,7 @@ public interface AccountingPersistenceBackendQuery { TemporalConstraint temporalConstraint, List filters,List contexts) throws Exception; - public String getRecord(String recordId, String type) throws Exception; + public Record getRecord(String recordId, String type) throws Exception; public SortedSet getSpaceProvidersIds() throws Exception; diff --git a/src/main/java/org/gcube/accounting/analytics/persistence/AccountingPersistenceQuery.java b/src/main/java/org/gcube/accounting/analytics/persistence/AccountingPersistenceQuery.java index 5effa14..b4366a3 100644 --- a/src/main/java/org/gcube/accounting/analytics/persistence/AccountingPersistenceQuery.java +++ b/src/main/java/org/gcube/accounting/analytics/persistence/AccountingPersistenceQuery.java @@ -26,6 +26,7 @@ import org.gcube.accounting.analytics.exception.ValueException; import org.gcube.accounting.datamodel.aggregation.AggregatedStorageStatusRecord; import org.gcube.accounting.datamodel.aggregation.AggregatedStorageUsageRecord; import org.gcube.documentstore.records.AggregatedRecord; +import org.gcube.documentstore.records.Record; import org.json.JSONException; import org.json.JSONObject; @@ -286,8 +287,8 @@ public class AccountingPersistenceQuery implements AccountingPersistenceBackendQ } @Override - public String getRecord(String recordId, String type) throws Exception { - String record = AccountingPersistenceBackendQueryFactory.getInstance().getRecord(recordId, type); + public Record getRecord(String recordId, String type) throws Exception { + Record record = AccountingPersistenceBackendQueryFactory.getInstance().getRecord(recordId, type); return record; }