ref 8460:AccountingManager - Support Java 8 compatibility

https://support.d4science.org/issues/8460

Added support to Java 8 compatibility

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/admin/accounting-manager@148413 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Giancarlo Panichi 2017-05-09 15:35:45 +00:00
parent 4c4dcf6af8
commit 0ae1ed43db
224 changed files with 685 additions and 697 deletions

View File

@ -22,11 +22,6 @@
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
@ -45,5 +40,10 @@
</classpathentry>
<classpathentry kind="lib" path="/home/giancarlo/gwt/gwt-2.6.1/validation-api-1.0.0.GA.jar" sourcepath="/home/giancarlo/gwt/gwt-2.6.1/validation-api-1.0.0.GA-sources.jar"/>
<classpathentry kind="lib" path="/home/giancarlo/gwt/gwt-2.6.1/validation-api-1.0.0.GA-sources.jar"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7">
<attributes>
<attribute name="owner.project.facets" value="java"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="target/accounting-manager-1.7.0-SNAPSHOT/WEB-INF/classes"/>
</classpath>

View File

@ -1,10 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
<wb-module deploy-name="accounting-manager">
<wb-module deploy-name="accounting-manager-1.7.0-SNAPSHOT">
<wb-resource deploy-path="/" source-path="/target/m2e-wtp/web-resources"/>
<wb-resource deploy-path="/" source-path="/src/main/webapp" tag="defaultRootSource"/>
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/java"/>
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/resources"/>
<dependent-module archiveName="accounting-manager-theme-1.1.0-SNAPSHOT.jar" deploy-path="/WEB-INF/lib" handle="module:/resource/accounting-manager-theme/accounting-manager-theme">
<dependent-module archiveName="accounting-manager-theme-1.2.0-SNAPSHOT.jar" deploy-path="/WEB-INF/lib" handle="module:/resource/accounting-manager-theme/accounting-manager-theme">
<dependency-type>uses</dependency-type>
</dependent-module>
<property name="java-output-path" value="/accounting-manager/target/accounting-manager-1.3.0-SNAPSHOT/WEB-INF/classes"/>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<faceted-project>
<fixed facet="wst.jsdt.web"/>
<installed facet="java" version="1.7"/>
<installed facet="jst.web" version="3.0"/>
<installed facet="wst.jsdt.web" version="1.0"/>
<installed facet="java" version="1.7"/>
</faceted-project>

View File

@ -24,8 +24,7 @@ import com.sencha.gxt.widget.core.client.container.Viewport;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*/
public class AccountingManager implements EntryPoint {

View File

@ -54,8 +54,7 @@ import com.sencha.gxt.widget.core.client.container.BorderLayoutContainer;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*/
public class AccountingManagerController {

View File

@ -15,8 +15,7 @@ import com.sencha.gxt.widget.core.client.container.Viewport.ViewportAppearance;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*/
public class PortalViewport extends SimpleContainer {
@ -25,7 +24,6 @@ public class PortalViewport extends SimpleContainer {
protected boolean enableScroll;
/**
* Creates a viewport layout container with the default appearance.
*/
@ -52,8 +50,7 @@ public class PortalViewport extends SimpleContainer {
getFocusSupport().setIgnore(false);
resize();
} catch (Exception e) {
Log.error("PortalViewport: constructor error "
+ e.getLocalizedMessage());
Log.error("PortalViewport: constructor error " + e.getLocalizedMessage());
}
}
@ -109,14 +106,12 @@ public class PortalViewport extends SimpleContainer {
}
int viewHeight = calculateHeight();
Log.info("AM resize viewWidth: " + viewWidth + " viewHeight: "
+ viewHeight + " clientWidth: " + Window.getClientWidth()
+ " clientHeight: " + Window.getClientHeight());
Log.info("AM resize viewWidth: " + viewWidth + " viewHeight: " + viewHeight + " clientWidth: "
+ Window.getClientWidth() + " clientHeight: " + Window.getClientHeight());
try {
setPixelSize(viewWidth, viewHeight);
} catch (Exception e) {
Log.error("PortalViewport: error in resize() at setPixelSize "
+ e.getLocalizedMessage());
Log.error("PortalViewport: error in resize() at setPixelSize " + e.getLocalizedMessage());
}
}
@ -127,10 +122,8 @@ public class PortalViewport extends SimpleContainer {
protected void onWindowResize(int width, int height) {
int viewWidth = calculateWidth();
int viewHeight = calculateHeight();
Log.trace("AM onWindowResize viewWidth: " + viewWidth
+ " viewHeight: " + viewHeight + " clientWidth: "
+ Window.getClientWidth() + " clientHeight: "
+ Window.getClientHeight());
Log.trace("AM onWindowResize viewWidth: " + viewWidth + " viewHeight: " + viewHeight + " clientWidth: "
+ Window.getClientWidth() + " clientHeight: " + Window.getClientHeight());
setPixelSize(viewWidth, viewHeight);
}
@ -156,23 +149,29 @@ public class PortalViewport extends SimpleContainer {
* int rootWidth = Window.getClientWidth() - 2* leftBorder; //-
* rightScrollBar;
*
* System.out.println("New workspace dimension Height: "+rootHeight+" Width: "
* +rootWidth);
* System.out.println("New workspace dimension Height: "
* +rootHeight+" Width: " +rootWidth);
*
* this.setHeight(rootHeight); this.setWidth(rootWidth); }
*/
/**
*
* @return the with calculate
*/
protected int calculateWidth() {
int leftBorder = getAbsoluteLeft();
Log.info("AM width: "
+ String.valueOf(Window.getClientWidth() - 2 * leftBorder));
Log.info("AM width: " + String.valueOf(Window.getClientWidth() - 2 * leftBorder));
return Window.getClientWidth() - 2 * leftBorder;
}
/**
*
* @return the height calculate
*/
protected int calculateHeight() {
int topBorder = getAbsoluteTop();
Log.info("AM height: "
+ String.valueOf(Window.getClientHeight() - topBorder - 34));
Log.info("AM height: " + String.valueOf(Window.getClientHeight() - topBorder - 34));
return Window.getClientHeight() - topBorder - 34;
}

View File

@ -28,8 +28,8 @@ import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer.Verti
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class CarouselPanel extends FramedPanel {

View File

@ -12,10 +12,9 @@ import com.sencha.gxt.data.shared.Store.StoreSortInfo;
/**
*
* @author giancarlo
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
* @param <M>
* @param <M> type of axis
*/
public class FormatedTimeAxis<M> extends CategoryAxis<M, String> {
private Date startDate;
@ -27,6 +26,8 @@ public class FormatedTimeAxis<M> extends CategoryAxis<M, String> {
/**
* Creates a time axis.
*
* @param dateTimeFormat date time format
*/
public FormatedTimeAxis(DateTimeFormat dateTimeFormat) {
super();

View File

@ -9,8 +9,8 @@ import com.google.gwt.event.shared.HasHandlers;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingMenuEvent extends

View File

@ -10,8 +10,8 @@ import com.google.gwt.event.shared.HasHandlers;
/**
* Accounting Period Request Event
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingPeriodEvent extends

View File

@ -8,8 +8,8 @@ import com.google.gwt.event.shared.HasHandlers;
/**
* Accounting Period Request Event
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingPeriodRequestEvent

View File

@ -9,8 +9,8 @@ import com.google.gwt.event.shared.HasHandlers;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class EnableTabsEvent extends

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
/**
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ExportRequestEvent extends

View File

@ -10,8 +10,8 @@ import com.google.gwt.event.shared.HasHandlers;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class FiltersChangeEvent extends

View File

@ -10,8 +10,8 @@ import com.google.gwt.event.shared.HasHandlers;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class SessionExpiredEvent extends GwtEvent<SessionExpiredEvent.SessionExpiredEventHandler> {

View File

@ -10,8 +10,8 @@ import com.google.gwt.event.shared.HasHandlers;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class StateChangeEvent extends

View File

@ -10,8 +10,8 @@ import com.google.gwt.event.shared.HasHandlers;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class UIStateEvent extends GwtEvent<UIStateEvent.UIStateHandler> {

View File

@ -38,8 +38,8 @@ import com.sencha.gxt.widget.core.client.form.validator.EmptyValidator;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingPeriodPanel extends SimpleContainer {

View File

@ -95,8 +95,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ActiveFiltersPanel extends SimpleContainer {

View File

@ -24,8 +24,8 @@ import com.sencha.gxt.widget.core.client.event.SelectEvent.SelectHandler;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class FiltersPanel extends FramedPanel {

View File

@ -4,8 +4,8 @@ package org.gcube.portlets.admin.accountingmanager.client.graphics;
*
* Basic Vector 2D
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class Vector2D {

View File

@ -18,8 +18,8 @@ import com.sencha.gxt.widget.core.client.FramedPanel;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ChartViewerPanel extends FramedPanel {

View File

@ -13,8 +13,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
/**
* Accounting Chart 4 Job
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingChart4Job extends AccountingChartBuilder {

View File

@ -9,8 +9,8 @@ import com.google.gwt.event.shared.EventBus;
/**
* Accounting Chart 4 Portlet
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingChart4Portlet extends AccountingChartBuilder {

View File

@ -13,8 +13,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
/**
* Accounting Chart 4 Service
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingChart4Service extends AccountingChartBuilder {

View File

@ -11,8 +11,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
/**
* Accounting Chart 4 Space
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingChart4Space extends AccountingChartBuilder {

View File

@ -13,8 +13,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
/**
* Accounting Chart 4 Storage
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingChart4Storage extends AccountingChartBuilder {

View File

@ -9,8 +9,8 @@ import com.google.gwt.event.shared.EventBus;
/**
* Accounting Chart 4 Task
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingChart4Task extends AccountingChartBuilder {

View File

@ -5,7 +5,7 @@ import org.gcube.portlets.admin.accountingmanager.shared.exception.ChartDrawExce
/**
* Abstract class for build Accounting Chart
*
* @author "Giancarlo Panichi"
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*/

View File

@ -6,7 +6,7 @@ import org.gcube.portlets.admin.accountingmanager.shared.exception.ChartDrawExce
/**
* Accounting Chart Director
*
* @author "Giancarlo Panichi"
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*/

View File

@ -4,8 +4,8 @@ import com.sencha.gxt.widget.core.client.container.Container;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingChartPanel {

View File

@ -4,8 +4,8 @@ package org.gcube.portlets.admin.accountingmanager.client.maindata.charts;
/**
* Accounting Chart Specification
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingChartSpec {

View File

@ -50,8 +50,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class JobChartBasicPanel extends SimpleContainer {

View File

@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class JobChartContextPanel extends SimpleContainer {

View File

@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class JobChartTopPanel extends SimpleContainer {

View File

@ -50,8 +50,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ServiceChartBasicPanel extends SimpleContainer {

View File

@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ServiceChartContextPanel extends SimpleContainer {

View File

@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ServiceChartTopPanel extends SimpleContainer {

View File

@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class SpaceChartSpacesPanel extends SimpleContainer {

View File

@ -47,8 +47,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class StorageChartBasicPanel extends SimpleContainer {

View File

@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class StorageChartContextPanel extends SimpleContainer {

View File

@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class StorageChartTopPanel extends SimpleContainer {

View File

@ -4,8 +4,8 @@ package org.gcube.portlets.admin.accountingmanager.client.maindata.charts.utils;
* Note Storage Data are in kB
*
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ByteUnitMeasure {
@ -53,8 +53,4 @@ public class ByteUnitMeasure {
}
}

View File

@ -5,8 +5,8 @@ import java.util.Date;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ChartDateTimeData implements Serializable {
@ -21,8 +21,8 @@ public class ChartDateTimeData implements Serializable {
/**
*
* @param date
* @param value
* @param date date
* @param value value
*/
public ChartDateTimeData(Date date, Long value) {
super();

View File

@ -9,8 +9,7 @@ import com.google.gwt.i18n.client.DateTimeFormat;
/**
*
* @author giancarlo
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*/
public class ChartTimeMeasure {

View File

@ -3,7 +3,6 @@ package org.gcube.portlets.admin.accountingmanager.client.maindata.charts.utils;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*/
public class DownloadConstants {

View File

@ -7,8 +7,8 @@ import java.util.List;
* Job Chart Measure
*
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
@ -17,7 +17,6 @@ public enum JobChartMeasure {
Duration("Duration"), MaxInvocationTime("Max Invocation Time"), MinInvocationTime(
"Min Invocation Time"), OperationCount("Operation Count");
/**
*
* @param id
@ -43,8 +42,8 @@ public enum JobChartMeasure {
/**
*
* @param id
* @return
* @param id the id
* @return job chart measure
*/
public static JobChartMeasure getFromId(String id) {
if (id == null || id.isEmpty())

View File

@ -7,8 +7,8 @@ import java.util.List;
* Service Chart Measure
*
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
@ -42,8 +42,8 @@ public enum ServiceChartMeasure {
/**
*
* @param id
* @return
* @param id the id
* @return service chart measure
*/
public static ServiceChartMeasure getFromId(String id) {
if (id == null || id.isEmpty())

View File

@ -7,8 +7,8 @@ import java.util.List;
* Service Chart Measure
*
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
@ -42,7 +42,8 @@ public enum SpaceChartMeasure {
/**
*
* @param id
* @return
* the id
* @return space chart measure
*/
public static SpaceChartMeasure getFromId(String id) {
if (id == null || id.isEmpty())

View File

@ -7,8 +7,8 @@ import java.util.List;
* Storage Chart Measure
*
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
@ -41,8 +41,8 @@ public enum StorageChartMeasure {
/**
*
* @param id
* @return
* @param id the id
* @return storage chart measure
*/
public static StorageChartMeasure getFromId(String id) {
if (id == null || id.isEmpty())

View File

@ -4,8 +4,8 @@ package org.gcube.portlets.admin.accountingmanager.client.maindata.charts.utils;
* Time Unit
*
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class TimeUnitMeasure {

View File

@ -18,8 +18,8 @@ import com.sencha.gxt.widget.core.client.TabPanel;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingManagerMenu extends TabPanel {

View File

@ -5,8 +5,8 @@ import com.sencha.gxt.widget.core.client.box.AutoProgressMessageBox;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingMonitor extends AutoProgressMessageBox {

View File

@ -10,8 +10,8 @@ import com.google.gwt.user.client.rpc.AsyncCallback;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class MonitorRequest {

View File

@ -8,8 +8,8 @@ import com.google.gwt.event.shared.HasHandlers;
/**
* Accounting Period Request Event
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class MonitorRequestEvent extends

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.admin.accountingmanager.client.monitor;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum MonitorRequestType {

View File

@ -9,8 +9,8 @@ import com.sencha.gxt.data.shared.PropertyAccess;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public interface GenresDataProperties extends PropertyAccess<GenresData> {

View File

@ -7,8 +7,8 @@ import com.google.gwt.resources.client.CssResource;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public interface AccountingManagerCSS extends CssResource {

View File

@ -9,8 +9,8 @@ import com.google.gwt.resources.client.ImageResource;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public interface AccountingManagerResources extends ClientBundle {

View File

@ -20,8 +20,8 @@ import com.google.gwt.user.client.rpc.RemoteServiceRelativePath;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
@RemoteServiceRelativePath("ams")
@ -29,15 +29,17 @@ public interface AccountingManagerService extends RemoteService {
/**
* Get informations on the current user
*
* @return
* @return user info
* @throws ServiceException
* service exception
*/
public UserInfo hello() throws ServiceException;
/**
*
* @return
* @return timeout
* @throws ServiceException
* service exception
*/
public Long getClientMonitorTimeout() throws ServiceException;
@ -48,11 +50,12 @@ public interface AccountingManagerService extends RemoteService {
* the resource on which to accounting
* @param seriesRequest
* filters and constraints descriptions
* @return
* @return series
* @throws ServiceException
* service exception
*/
public SeriesResponse getSeriesInCache(AccountingType accountingType,
SeriesRequest seriesRequest) throws ServiceException;
public SeriesResponse getSeriesInCache(AccountingType accountingType, SeriesRequest seriesRequest)
throws ServiceException;
/**
* Retrieve Accounting Series
@ -61,21 +64,21 @@ public interface AccountingManagerService extends RemoteService {
* the resource on which to accounting
* @param seriesRequest
* filters and constraints descriptions
* @return
* @return series
* @throws ServiceException
* series exception
*/
public String getSeries(AccountingType accountingType,
SeriesRequest seriesRequest) throws ServiceException;
public String getSeries(AccountingType accountingType, SeriesRequest seriesRequest) throws ServiceException;
/**
* Accounting Request Monitor
*
* @param operationId
* @return
* @param operationId operation id
* @return series
* @throws ServiceException
* service exception
*/
public SeriesResponse operationMonitor(String operationId)
throws ServiceException;
public SeriesResponse operationMonitor(String operationId) throws ServiceException;
/**
*
@ -83,34 +86,36 @@ public interface AccountingManagerService extends RemoteService {
* type of accounting
* @return list of filter keys
* @throws ServiceException
* service exception
*/
public ArrayList<FilterKey> getFilterKeys(AccountingType accountingType)
throws ServiceException;
public ArrayList<FilterKey> getFilterKeys(AccountingType accountingType) throws ServiceException;
/**
*
*
* @param filterValuesRequest
* request values available
* @return
* @return filter values
* @throws ServiceException
* service exception
*/
public FilterValuesResponse getFilterValues(
FilterValuesRequest filterValuesRequest) throws ServiceException;
public FilterValuesResponse getFilterValues(FilterValuesRequest filterValuesRequest) throws ServiceException;
/**
* Retrieve Context available
*
* @return
* @return context
* @throws ServiceException
* service exception
*/
public Context getContext() throws ServiceException;
/**
* Retrieve spaces available
*
* @return
* @return spaces
* @throws ServiceException
* service exception
*/
public Spaces getSpaces() throws ServiceException;
@ -118,33 +123,36 @@ public interface AccountingManagerService extends RemoteService {
*
* @param itemDescription
* item description
* @return
* @return public link
* @throws ServiceException
* service exception
*/
public String getPublicLink(ItemDescription itemDescription)
throws ServiceException;
public String getPublicLink(ItemDescription itemDescription) throws ServiceException;
/**
*
* @param accountingStateData
* @return
* @param accountingType
* accounting type
* @return item description
* @throws ServiceException
* service exception
*/
public ItemDescription saveCSVOnWorkspace(AccountingType accountingType)
throws ServiceException;
public ItemDescription saveCSVOnWorkspace(AccountingType accountingType) throws ServiceException;
/**
*
* @return
* @return enable tabs
* @throws ServiceException
* service exception
*/
public EnableTabs getEnableTabs() throws ServiceException;
/**
* Check if the user is in root scope
*
* @return
* @return true if is root scope
* @throws ServiceException
* service exception
*/
public Boolean isRootScope() throws ServiceException;

View File

@ -22,8 +22,8 @@ import com.google.gwt.user.client.rpc.AsyncCallback;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public interface AccountingManagerServiceAsync {
@ -34,6 +34,7 @@ public interface AccountingManagerServiceAsync {
/**
*
* @param callback
* user info callback
*/
void hello(AsyncCallback<UserInfo> callback);
@ -41,6 +42,7 @@ public interface AccountingManagerServiceAsync {
* Retrieve client monitor timeout
*
* @param callback
* client monitor timeout callback
*/
void getClientMonitorTimeout(AsyncCallback<Long> callback);
@ -52,9 +54,10 @@ public interface AccountingManagerServiceAsync {
* @param seriesRequest
* filters and constraints descriptions
* @param callback
* series response callback
*/
void getSeriesInCache(AccountingType accountingType,
SeriesRequest seriesRequest, AsyncCallback<SeriesResponse> callback);
void getSeriesInCache(AccountingType accountingType, SeriesRequest seriesRequest,
AsyncCallback<SeriesResponse> callback);
/**
* Retrieve Accounting Series
@ -64,40 +67,49 @@ public interface AccountingManagerServiceAsync {
* @param seriesRequest
* filters and constraints descriptions
* @param callback
* series callback
*/
void getSeries(AccountingType accountingType, SeriesRequest seriesRequest,
AsyncCallback<String> callback);
void getSeries(AccountingType accountingType, SeriesRequest seriesRequest, AsyncCallback<String> callback);
/**
* Accounting Request Monitor
*
* @param operationId
* operation Id
* @param callback
* series response callback
*/
void operationMonitor(String operationId,
AsyncCallback<SeriesResponse> callback);
void operationMonitor(String operationId, AsyncCallback<SeriesResponse> callback);
/**
*
* @param accountingType
* accounting type
* @param callback
* array list of filter key callback
*/
void getFilterKeys(AccountingType accountingType,
AsyncCallback<ArrayList<FilterKey>> callback);
void getFilterKeys(AccountingType accountingType, AsyncCallback<ArrayList<FilterKey>> callback);
void getFilterValues(FilterValuesRequest filterValuesRequest,
AsyncCallback<FilterValuesResponse> callback);
/**
*
* @param filterValuesRequest
* filter value request
* @param callback
* filter value response callback
*/
void getFilterValues(FilterValuesRequest filterValuesRequest, AsyncCallback<FilterValuesResponse> callback);
/**
*
* @param callback
* context callback
*/
void getContext(AsyncCallback<Context> callback);
/**
*
* @param callback
* spaces callback
*/
void getSpaces(AsyncCallback<Spaces> callback);
@ -106,22 +118,23 @@ public interface AccountingManagerServiceAsync {
* @param itemDescription
* item description
* @param callback
* public link callback
*/
void getPublicLink(ItemDescription itemDescription,
AsyncCallback<String> callback);
void getPublicLink(ItemDescription itemDescription, AsyncCallback<String> callback);
/**
*
* @param accountingStateData
* @param accountingType
* accounting type
* @param callback
* item description callback
*/
void saveCSVOnWorkspace(AccountingType accountingType,
AsyncCallback<ItemDescription> callback);
void saveCSVOnWorkspace(AccountingType accountingType, AsyncCallback<ItemDescription> callback);
/**
*
* @param callback
* return the list of enabled tabs
* the callback that return the list of enabled tabs
*/
void getEnableTabs(AsyncCallback<EnableTabs> callback);
@ -129,6 +142,7 @@ public interface AccountingManagerServiceAsync {
* Check if the user is in root scope
*
* @param callback
* the callback that return true if is root scope
*/
void isRootScope(AsyncCallback<Boolean> callback);

View File

@ -7,8 +7,8 @@ import org.gcube.portlets.admin.accountingmanager.shared.data.AccountingType;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingClientState implements Serializable {

View File

@ -12,8 +12,8 @@ import org.gcube.portlets.admin.accountingmanager.shared.data.response.SeriesRes
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingClientStateData implements Serializable {
@ -34,10 +34,11 @@ public class AccountingClientStateData implements Serializable {
/**
*
* @param accountingType
* accounting type
* @param rootScope
* root scope
*/
public AccountingClientStateData(AccountingType accountingType,
Boolean rootScope) {
public AccountingClientStateData(AccountingType accountingType, Boolean rootScope) {
super();
this.accountingType = accountingType;
this.seriesRequest = null;
@ -51,15 +52,22 @@ public class AccountingClientStateData implements Serializable {
/**
*
* @param accountingType
* accounting type
* @param seriesRequest
* series request
* @param seriesResponse
* series response
* @param availableFilterKeys
* available filter keys
* @param availableContext
* available context
* @param availableSpaces
* available spaces
* @param rootScope
* root scope
*/
public AccountingClientStateData(AccountingType accountingType,
SeriesRequest seriesRequest, SeriesResponse seriesResponse,
ArrayList<FilterKey> availableFilterKeys, Context availableContext,
public AccountingClientStateData(AccountingType accountingType, SeriesRequest seriesRequest,
SeriesResponse seriesResponse, ArrayList<FilterKey> availableFilterKeys, Context availableContext,
Spaces availableSpaces, Boolean rootScope) {
super();
this.accountingType = accountingType;
@ -129,12 +137,10 @@ public class AccountingClientStateData implements Serializable {
@Override
public String toString() {
return "AccountingClientStateData [accountingType=" + accountingType
+ ", seriesRequest=" + seriesRequest + ", seriesResponse="
+ seriesResponse + ", availableFilterKeys="
+ availableFilterKeys + ", availableContext="
+ availableContext + ", availableSpaces=" + availableSpaces
+ ", rootScope=" + rootScope + "]";
return "AccountingClientStateData [accountingType=" + accountingType + ", seriesRequest=" + seriesRequest
+ ", seriesResponse=" + seriesResponse + ", availableFilterKeys=" + availableFilterKeys
+ ", availableContext=" + availableContext + ", availableSpaces=" + availableSpaces + ", rootScope="
+ rootScope + "]";
}
}

View File

@ -5,8 +5,8 @@ package org.gcube.portlets.admin.accountingmanager.client.type;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum FiltersChangeType {

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.admin.accountingmanager.client.type;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum SessionExpiredType {

View File

@ -5,8 +5,8 @@ package org.gcube.portlets.admin.accountingmanager.client.type;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum StateChangeType {

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.admin.accountingmanager.client.type;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum UIStateType {

View File

@ -5,8 +5,8 @@ package org.gcube.portlets.admin.accountingmanager.client.util;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class Format {

View File

@ -4,8 +4,8 @@ import com.sencha.gxt.widget.core.client.box.MessageBox;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class InfoMessageBox extends MessageBox {

View File

@ -11,8 +11,8 @@ import com.sencha.gxt.widget.core.client.event.HideEvent.HideHandler;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class UtilsGXT3 {

View File

@ -21,6 +21,11 @@ import org.gcube.portlets.admin.accountingmanager.shared.exception.ServiceExcept
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi
*
*/
public class AccountingClientCallable implements Callable<TaskStatus> {
private static Logger logger = LoggerFactory

View File

@ -28,8 +28,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingClientDaemon implements Runnable {

View File

@ -12,8 +12,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
@WebListener

View File

@ -45,8 +45,8 @@ import com.google.gwt.user.server.rpc.RemoteServiceServlet;
*
* Support service request
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
@SuppressWarnings("serial")

View File

@ -26,8 +26,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
* Export Servlet
*

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.admin.accountingmanager.server;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class SessionConstants {

View File

@ -11,10 +11,10 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
* @param <T>
*
* @param <T> tpye
*/
public class SessionOp<T> {

View File

@ -28,8 +28,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class SessionUtil {
@ -257,11 +257,12 @@ public class SessionUtil {
}
/**
*
* @param httpRequest
* @param serviceCredentials
* @return
* @param httpSession http session
* @param serviceCredentials service credentials
* @return hash map of tasks
*/
public static HashMap<String, TaskWrapper> getTaskWrapperMap(
HttpSession httpSession,
@ -274,9 +275,9 @@ public class SessionUtil {
/**
*
* @param httpRequest
* @param serviceCredentials
* @param taskWrapperMap
* @param httpSession session
* @param serviceCredentials service credentials
* @param taskWrapperMap task wrapper map
*/
public static void setTaskWrapperMap(HttpSession httpSession,
ServiceCredentials serviceCredentials,

View File

@ -35,8 +35,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingCaller implements AccountingCallerInterface {

View File

@ -13,8 +13,8 @@ import org.gcube.portlets.admin.accountingmanager.shared.exception.ServiceExcept
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public interface AccountingCallerInterface {

View File

@ -55,8 +55,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingCallerTester implements AccountingCallerInterface {

View File

@ -22,15 +22,14 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingCache implements Serializable {
private static final long serialVersionUID = -4352823042594405108L;
private static Logger logger = LoggerFactory
.getLogger(AccountingCache.class);
private static Logger logger = LoggerFactory.getLogger(AccountingCache.class);
private static final String ACCOUNTING_SERIES_CACHE = "AccountingSeriesCache";
private static final String ACCOUNTING_FILTER_VALUES_CACHE = "AccountingFilterValuesCache";
@ -49,20 +48,15 @@ public class AccountingCache implements Serializable {
cacheManager = cachingProvider.getCacheManager();
logger.info("AccountingCache URI: " + cacheManager.getURI());
ResourcePoolsBuilder builderSeries = ResourcePoolsBuilder
.newResourcePoolsBuilder().heap(60L, MemoryUnit.MB)
ResourcePoolsBuilder builderSeries = ResourcePoolsBuilder.newResourcePoolsBuilder().heap(60L, MemoryUnit.MB)
.offheap(240L, MemoryUnit.MB);
// .disk(500L, MemoryUnit.KB)
// .withSizeOfMaxObjectSize(1L, MemoryUnit.KB)
cacheSeriesConfiguration = CacheConfigurationBuilder
.newCacheConfigurationBuilder(String.class,
SeriesResponse.class, builderSeries)
.withExpiry(
Expirations
.timeToLiveExpiration(org.ehcache.expiry.Duration
.of(30L, TimeUnit.MINUTES)))
.newCacheConfigurationBuilder(String.class, SeriesResponse.class, builderSeries)
.withExpiry(Expirations.timeToLiveExpiration(org.ehcache.expiry.Duration.of(30L, TimeUnit.MINUTES)))
.withSizeOfMaxObjectSize(50L, MemoryUnit.MB).build();
// mBeanServer = ManagementFactory.getPlatformMBeanServer();
@ -74,20 +68,15 @@ public class AccountingCache implements Serializable {
* .build(true);
*/
ResourcePoolsBuilder builderFilterValues = ResourcePoolsBuilder
.newResourcePoolsBuilder().heap(10L, MemoryUnit.MB)
.offheap(30L, MemoryUnit.MB);
ResourcePoolsBuilder builderFilterValues = ResourcePoolsBuilder.newResourcePoolsBuilder()
.heap(10L, MemoryUnit.MB).offheap(30L, MemoryUnit.MB);
// .disk(500L, MemoryUnit.KB)
// .withSizeOfMaxObjectSize(1L, MemoryUnit.KB)
cacheFilterValuesConfiguration = CacheConfigurationBuilder
.newCacheConfigurationBuilder(String.class,
FilterValuesResponse.class, builderFilterValues)
.withExpiry(
Expirations
.timeToLiveExpiration(org.ehcache.expiry.Duration
.of(30L, TimeUnit.MINUTES)))
.newCacheConfigurationBuilder(String.class, FilterValuesResponse.class, builderFilterValues)
.withExpiry(Expirations.timeToLiveExpiration(org.ehcache.expiry.Duration.of(30L, TimeUnit.MINUTES)))
.withSizeOfMaxObjectSize(4L, MemoryUnit.MB).build();
} catch (Throwable e) {
@ -97,14 +86,13 @@ public class AccountingCache implements Serializable {
}
}
private Cache<String, SeriesResponse> initCacheSeries()
throws ServiceException {
private Cache<String, SeriesResponse> initCacheSeries() throws ServiceException {
try {
String cacheSeriesName = ACCOUNTING_SERIES_CACHE;
// create the cache
Cache<String, SeriesResponse> cacheSeries = cacheManager.getCache(
cacheSeriesName, String.class, SeriesResponse.class);
Cache<String, SeriesResponse> cacheSeries = cacheManager.getCache(cacheSeriesName, String.class,
SeriesResponse.class);
if (cacheSeries == null) {
/*
@ -118,11 +106,8 @@ public class AccountingCache implements Serializable {
* cache = cacheManager.createCache(cacheName, config);
*/
cacheSeries = cacheManager
.createCache(
cacheSeriesName,
Eh107Configuration
.fromEhcacheCacheConfiguration(cacheSeriesConfiguration));
cacheSeries = cacheManager.createCache(cacheSeriesName,
Eh107Configuration.fromEhcacheCacheConfiguration(cacheSeriesConfiguration));
cacheManager.enableManagement(cacheSeriesName, true);
cacheManager.enableStatistics(cacheSeriesName, true);
@ -148,25 +133,18 @@ public class AccountingCache implements Serializable {
}
private Cache<String, FilterValuesResponse> initCacheFilterValues()
throws ServiceException {
private Cache<String, FilterValuesResponse> initCacheFilterValues() throws ServiceException {
try {
String cacheFilterValuesName = ACCOUNTING_FILTER_VALUES_CACHE;
// create the cache
Cache<String, FilterValuesResponse> cacheFilterValues = cacheManager
.getCache(cacheFilterValuesName, String.class,
FilterValuesResponse.class);
Cache<String, FilterValuesResponse> cacheFilterValues = cacheManager.getCache(cacheFilterValuesName,
String.class, FilterValuesResponse.class);
if (cacheFilterValues == null) {
cacheFilterValues = cacheManager
.createCache(
cacheFilterValuesName,
Eh107Configuration
.fromEhcacheCacheConfiguration(cacheFilterValuesConfiguration));
cacheFilterValues = cacheManager.createCache(cacheFilterValuesName,
Eh107Configuration.fromEhcacheCacheConfiguration(cacheFilterValuesConfiguration));
cacheManager.enableManagement(cacheFilterValuesName, true);
cacheManager.enableStatistics(cacheFilterValuesName, true);
@ -182,8 +160,7 @@ public class AccountingCache implements Serializable {
}
public void putSeries(String key, SeriesResponse value)
throws ServiceException {
public void putSeries(String key, SeriesResponse value) throws ServiceException {
logger.debug("Cache put: [" + key + ", " + value + "]");
Cache<String, SeriesResponse> cacheSeries = initCacheSeries();
cacheSeries.put(key, value);
@ -194,8 +171,10 @@ public class AccountingCache implements Serializable {
/**
*
* @param key
* @return
* key
* @return series response
* @throws ServiceException
* service exception
*/
public SeriesResponse getSeries(String key) throws ServiceException {
logger.debug("Cache get: [" + key + "]");
@ -205,15 +184,16 @@ public class AccountingCache implements Serializable {
return value;
}
/**
*
* @param key
* key
* @param value
* value
* @throws ServiceException
* service exception
*/
public void putFilterValues(String key, FilterValuesResponse value)
throws ServiceException {
public void putFilterValues(String key, FilterValuesResponse value) throws ServiceException {
logger.debug("Cache put: [" + key + ", " + value + "]");
Cache<String, FilterValuesResponse> cacheFilterValues = initCacheFilterValues();
cacheFilterValues.put(key, value);
@ -224,8 +204,10 @@ public class AccountingCache implements Serializable {
/**
*
* @param key
* @return
* key
* @return filter values
* @throws ServiceException
* service exception
*/
public FilterValuesResponse getFilterValues(String key) throws ServiceException {
logger.debug("Cache get: [" + key + "]");
@ -244,17 +226,13 @@ public class AccountingCache implements Serializable {
cacheManager.destroyCache(cacheName);
}
} catch (Throwable e) {
logger.error(
"Error destroying the AccountingCache: "
+ e.getLocalizedMessage(), e);
logger.error("Error destroying the AccountingCache: " + e.getLocalizedMessage(), e);
}
try {
cacheManager.close();
} catch (Throwable e) {
logger.error(
"Error closing AccountingCache manager: "
+ e.getLocalizedMessage(), e);
logger.error("Error closing AccountingCache manager: " + e.getLocalizedMessage(), e);
}
}
super.finalize();

View File

@ -24,8 +24,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingCommandBasic implements

View File

@ -24,8 +24,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingCommandContext implements AccountingCommand<SeriesResponse> {

View File

@ -16,8 +16,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingCommandGetFilterKeys implements

View File

@ -27,8 +27,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingCommandGetFilterValues implements

View File

@ -12,8 +12,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingCommandGetSpaces implements

View File

@ -19,8 +19,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingCommandSpaces implements

View File

@ -23,8 +23,8 @@ import org.slf4j.LoggerFactory;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingCommandTop implements AccountingCommand<SeriesResponse> {

View File

@ -4,8 +4,8 @@ import org.gcube.portlets.admin.accountingmanager.shared.data.ChartType;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingQuery {

View File

@ -21,8 +21,8 @@ import org.slf4j.LoggerFactory;
/**
* Accounting Query 4 Job
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingQuery4Job extends AccountingQueryBuilder {

View File

@ -21,8 +21,8 @@ import org.slf4j.LoggerFactory;
/**
* Accounting Query 4 Portlet
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingQuery4Portlet extends AccountingQueryBuilder {

View File

@ -21,8 +21,8 @@ import org.slf4j.LoggerFactory;
/**
* Accounting Query 4 Service
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingQuery4Service extends AccountingQueryBuilder {

View File

@ -19,8 +19,8 @@ import org.slf4j.LoggerFactory;
/**
* Accounting Query 4 Space
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingQuery4Space extends AccountingQueryBuilder {

View File

@ -21,8 +21,8 @@ import org.slf4j.LoggerFactory;
/**
* Accounting Query 4 Storage
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingQuery4Storage extends AccountingQueryBuilder {

View File

@ -21,8 +21,8 @@ import org.slf4j.LoggerFactory;
/**
* Accounting Query 4 Task
*
* @author "Giancarlo Panichi" email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingQuery4Task extends AccountingQueryBuilder {

View File

@ -9,8 +9,8 @@ import org.gcube.portlets.admin.accountingmanager.shared.data.ChartType;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingQueryBasic extends AccountingQuery {

View File

@ -7,7 +7,7 @@ import org.gcube.portlets.admin.accountingmanager.shared.exception.ServiceExcept
/**
* Abstract class for build Accounting Query
*
* @author "Giancarlo Panichi"
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*/

View File

@ -10,8 +10,8 @@ import org.gcube.portlets.admin.accountingmanager.shared.data.Context;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class AccountingQueryContext extends AccountingQuery {

View File

@ -8,7 +8,7 @@ import org.gcube.portlets.admin.accountingmanager.shared.exception.ServiceExcept
/**
* Accounting Query Director
*
* @author "Giancarlo Panichi"
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*/

Some files were not shown because too many files have changed in this diff Show More