geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ecr...@apache.org
Subject svn commit: r602191 - in /geronimo/sandbox/monitoring/client/client-war/src/main: java/org/apache/geronimo/plugins/monitoring/client/ webapp/WEB-INF/view/
Date Fri, 07 Dec 2007 19:33:40 GMT
Author: ecraig
Date: Fri Dec  7 11:33:39 2007
New Revision: 602191

URL: http://svn.apache.org/viewvc?rev=602191&view=rev
Log:
GERONIMO-3554
monitoring plugin: client should use an ArrayList instead of a Vector

Patch by Viet Nguyen


Modified:
    geronimo/sandbox/monitoring/client/client-war/src/main/java/org/apache/geronimo/plugins/monitoring/client/GraphsBuilder.java
    geronimo/sandbox/monitoring/client/client-war/src/main/java/org/apache/geronimo/plugins/monitoring/client/StatsGraph.java
    geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddGraph.jsp
    geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddServer.jsp
    geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddView.jsp
    geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditGraph.jsp
    geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditServer.jsp
    geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditView.jsp
    geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringPage.jsp

Modified: geronimo/sandbox/monitoring/client/client-war/src/main/java/org/apache/geronimo/plugins/monitoring/client/GraphsBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/monitoring/client/client-war/src/main/java/org/apache/geronimo/plugins/monitoring/client/GraphsBuilder.java?rev=602191&r1=602190&r2=602191&view=diff
==============================================================================
--- geronimo/sandbox/monitoring/client/client-war/src/main/java/org/apache/geronimo/plugins/monitoring/client/GraphsBuilder.java
(original)
+++ geronimo/sandbox/monitoring/client/client-war/src/main/java/org/apache/geronimo/plugins/monitoring/client/GraphsBuilder.java
Fri Dec  7 11:33:39 2007
@@ -23,11 +23,11 @@
 import java.text.DecimalFormat;
 import java.text.Format;
 import java.text.SimpleDateFormat;
+import java.util.ArrayList;
 import java.util.Date;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.TreeMap;
-import java.util.Vector;
 
 import org.apache.geronimo.plugins.monitoring.client.util.DBManager;
 
@@ -90,13 +90,13 @@
                 snapCount = timeFrame
                         / java.lang.Integer
                                 .valueOf(java.lang.Long.toString((mrc.getSnapshotDuration()
/ new Long(60000))));
-                HashMap<String, Vector<Object>> DataList = new HashMap<String,
Vector<Object>>();
+                HashMap<String, ArrayList<Object>> DataList = new HashMap<String,
ArrayList<Object>>();
 
-                DataList.put(graphName1, new Vector<Object>());
+                DataList.put(graphName1, new ArrayList<Object>());
                 if (!dataName2.equals("time") && (dataName2 != null)
                         && !dataName2.equals("null") && !dataName2.equals(""))
                 {
-                    DataList.put(graphName2, new Vector<Object>());
+                    DataList.put(graphName2, new ArrayList<Object>());
                 }
                 if ((timeFrame / 1440 >= 30))
                     snapCount = 17;
@@ -109,9 +109,9 @@
                     }
                 }
 
-                Vector<Object> snapshot_time = new Vector<Object>();
+                ArrayList<Object> snapshot_time = new ArrayList<Object>();
 
-                Vector<Object> PrettyTime = new Vector<Object>();
+                ArrayList<Object> PrettyTime = new ArrayList<Object>();
 
                 String prettyTimeFrame = new String();
                 DecimalFormat fmt = new DecimalFormat("0.##");
@@ -150,14 +150,14 @@
                 for (Iterator<Long> it = snapshotList.keySet().iterator(); it.hasNext();
) {
                     Long current = it.next();
                     snapshot_time.add(current);
-                    Vector<Object> vectorTemp = DataList.get(graphName1);
-                    vectorTemp.add(snapshotList.get(current));
-                    DataList.put(graphName1, vectorTemp);
+                    ArrayList<Object> ArrayListTemp = DataList.get(graphName1);
+                    ArrayListTemp.add(snapshotList.get(current));
+                    DataList.put(graphName1, ArrayListTemp);
                     if (!dataName2.equals("time") && (dataName2 != null)
                             && !dataName2.equals("null") && !dataName2.equals(""))
{
-                        Vector<Object> vectorTemp2 = DataList.get(graphName2);
-                        vectorTemp2.add(snapshotList.get(current));
-                        DataList.put(graphName2, vectorTemp2);
+                        ArrayList<Object> ArrayListTemp2 = DataList.get(graphName2);
+                        ArrayListTemp2.add(snapshotList.get(current));
+                        DataList.put(graphName2, ArrayListTemp2);
                     }
                     PrettyTime.add((Long) current / 1000);
                 }

Modified: geronimo/sandbox/monitoring/client/client-war/src/main/java/org/apache/geronimo/plugins/monitoring/client/StatsGraph.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/monitoring/client/client-war/src/main/java/org/apache/geronimo/plugins/monitoring/client/StatsGraph.java?rev=602191&r1=602190&r2=602191&view=diff
==============================================================================
--- geronimo/sandbox/monitoring/client/client-war/src/main/java/org/apache/geronimo/plugins/monitoring/client/StatsGraph.java
(original)
+++ geronimo/sandbox/monitoring/client/client-war/src/main/java/org/apache/geronimo/plugins/monitoring/client/StatsGraph.java
Fri Dec  7 11:33:39 2007
@@ -18,8 +18,8 @@
 
 import java.text.Format;
 import java.text.SimpleDateFormat;
+import java.util.ArrayList;
 import java.util.Date;
-import java.util.Vector;
 
 public class StatsGraph
 {
@@ -38,8 +38,8 @@
 
     public StatsGraph(Integer graph_id, String graphName, String description,
             String xAxisLabel, String yAxisLabel, char data1operation,
-            Vector<Object> dataSet1, String operation, char data2operation,
-            Vector<Object> dataSet2, Vector<Object> snapshotTimes,
+            ArrayList<Object> dataSet1, String operation, char data2operation,
+            ArrayList<Object> dataSet2, ArrayList<Object> snapshotTimes,
             int snapshotDuration, int timeFrame, String hexColor,
             float warninglevel1, float warninglevel2)
     {
@@ -266,8 +266,8 @@
 
     public StatsGraph(Integer graph_id, String graphName, String description,
             String xAxisLabel, String yAxisLabel, char data1operation,
-            Vector<Object> dataSet1, String operation,
-            Vector<Object> snapshotTimes, int snapshotDuration, int timeFrame,
+            ArrayList<Object> dataSet1, String operation,
+            ArrayList<Object> snapshotTimes, int snapshotDuration, int timeFrame,
             String hexColor, float warninglevel1, float warninglevel2)
     {
 

Modified: geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddGraph.jsp
URL: http://svn.apache.org/viewvc/geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddGraph.jsp?rev=602191&r1=602190&r2=602191&view=diff
==============================================================================
--- geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddGraph.jsp
(original)
+++ geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddGraph.jsp
Fri Dec  7 11:33:39 2007
@@ -18,7 +18,6 @@
 <%@ taglib uri="http://java.sun.com/portlet" prefix="portlet"%>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.StatsGraph" %>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.GraphsBuilder" %>
-<%@ page import="java.util.Vector" %>
 <%@ page import="java.util.Set" %>
 <%@ page import="java.util.Iterator" %>
 <%@ page import="java.util.HashMap" %>

Modified: geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddServer.jsp
URL: http://svn.apache.org/viewvc/geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddServer.jsp?rev=602191&r1=602190&r2=602191&view=diff
==============================================================================
--- geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddServer.jsp
(original)
+++ geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddServer.jsp
Fri Dec  7 11:33:39 2007
@@ -18,7 +18,6 @@
 <%@ taglib uri="http://java.sun.com/portlet" prefix="portlet"%>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.StatsGraph" %>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.GraphsBuilder" %>
-<%@ page import="java.util.Vector" %>
 <%@ page import="java.util.Set" %>
 <%@ page import="java.util.Iterator" %>
 <%@ page import="java.util.HashMap" %>

Modified: geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddView.jsp
URL: http://svn.apache.org/viewvc/geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddView.jsp?rev=602191&r1=602190&r2=602191&view=diff
==============================================================================
--- geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddView.jsp
(original)
+++ geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringAddView.jsp
Fri Dec  7 11:33:39 2007
@@ -18,7 +18,6 @@
 <%@ taglib uri="http://java.sun.com/portlet" prefix="portlet"%>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.StatsGraph" %>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.GraphsBuilder" %>
-<%@ page import="java.util.Vector" %>
 <%@ page import="java.util.Set" %>
 <%@ page import="java.util.Iterator" %>
 <%@ page import="java.util.HashMap" %>

Modified: geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditGraph.jsp
URL: http://svn.apache.org/viewvc/geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditGraph.jsp?rev=602191&r1=602190&r2=602191&view=diff
==============================================================================
--- geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditGraph.jsp
(original)
+++ geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditGraph.jsp
Fri Dec  7 11:33:39 2007
@@ -18,7 +18,6 @@
 <%@ taglib uri="http://java.sun.com/portlet" prefix="portlet"%>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.StatsGraph" %>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.GraphsBuilder" %>
-<%@ page import="java.util.Vector" %>
 <%@ page import="java.util.Set" %>
 <%@ page import="java.util.Iterator" %>
 <%@ page import="java.util.HashMap" %>

Modified: geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditServer.jsp
URL: http://svn.apache.org/viewvc/geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditServer.jsp?rev=602191&r1=602190&r2=602191&view=diff
==============================================================================
--- geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditServer.jsp
(original)
+++ geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditServer.jsp
Fri Dec  7 11:33:39 2007
@@ -20,7 +20,6 @@
 <%@ taglib uri="http://java.sun.com/portlet" prefix="portlet"%>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.StatsGraph" %>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.GraphsBuilder" %>
-<%@ page import="java.util.Vector" %>
 <%@ page import="java.util.Set" %>
 <%@ page import="java.util.Iterator" %>
 <%@ page import="java.util.HashMap" %>

Modified: geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditView.jsp
URL: http://svn.apache.org/viewvc/geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditView.jsp?rev=602191&r1=602190&r2=602191&view=diff
==============================================================================
--- geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditView.jsp
(original)
+++ geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringEditView.jsp
Fri Dec  7 11:33:39 2007
@@ -18,7 +18,6 @@
 <%@ taglib uri="http://java.sun.com/portlet" prefix="portlet"%>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.StatsGraph" %>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.GraphsBuilder" %>
-<%@ page import="java.util.Vector" %>
 <%@ page import="java.util.Set" %>
 <%@ page import="java.util.Iterator" %>
 <%@ page import="java.util.HashMap" %>

Modified: geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringPage.jsp
URL: http://svn.apache.org/viewvc/geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringPage.jsp?rev=602191&r1=602190&r2=602191&view=diff
==============================================================================
--- geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringPage.jsp
(original)
+++ geronimo/sandbox/monitoring/client/client-war/src/main/webapp/WEB-INF/view/monitoringPage.jsp
Fri Dec  7 11:33:39 2007
@@ -19,7 +19,6 @@
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.StatsGraph" %>
 <%@ page import="org.apache.geronimo.plugins.monitoring.client.GraphsBuilder" %>
 <%@ page import="java.util.ArrayList" %>
-<%@ page import="java.util.Vector" %>
 <%@ page import="java.util.Set" %>
 <%@ page import="java.sql.Connection" %>
 <%@ page import="java.sql.DatabaseMetaData" %>
@@ -64,7 +63,7 @@
         
     }
     
-    Vector <StatsGraph> graphs = new Vector<StatsGraph>();
+    ArrayList <StatsGraph> graphs = new ArrayList<StatsGraph>();
     for(int i = 0 ; i < ids.size(); i++) {
         try {
             StatsGraph graph = run.buildOneDB( ids.get(i).intValue() );



Mime
View raw message