labs-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From psm...@apache.org
Subject svn commit: r567011 - in /labs/pinpoint/trunk: ./ pinpoint-cli/ pinpoint-core/ pinpoint-core/src/main/java/org/apache/logging/pinpoint/converter/ pinpoint-core/src/main/java/org/apache/logging/pinpoint/jms/ pinpoint-importer/ pinpoint-metric/ pinpoint-...
Date Fri, 17 Aug 2007 10:59:20 GMT
Author: psmith
Date: Fri Aug 17 03:59:16 2007
New Revision: 567011

URL: http://svn.apache.org/viewvc?view=rev&rev=567011
Log:
Added some Metric infrastructure so one can see in more detail the rates
of receiving events versus indexing. These numbers are in fact already exposed
via AMQ's destination metrics, but given we may not always be using JMS as an underlying
buffering strategy.

These metrics will become important when events are screaming in, because it is likely that indexing
will not be able to sustain the same rates as reception of events.

Eventually the Service layer will be able to expose graphs of reception versus indexing rates via a RESTlet interface.



Added:
    labs/pinpoint/trunk/pinpoint-metric/   (with props)
    labs/pinpoint/trunk/pinpoint-metric/pom.xml
    labs/pinpoint/trunk/pinpoint-metric/src/
    labs/pinpoint/trunk/pinpoint-metric/src/main/
    labs/pinpoint/trunk/pinpoint-metric/src/main/java/
    labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/
    labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/
    labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/
    labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/
    labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/
    labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/Counter.java
    labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/MetricRegistry.java
    labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/ObservedValue.java
    labs/pinpoint/trunk/pinpoint-metric/src/test/
    labs/pinpoint/trunk/pinpoint-metric/src/test/java/
    labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/
    labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/
    labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/
    labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/
    labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/
    labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/CounterTest.java
    labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/MetricRegistryTest.java
Modified:
    labs/pinpoint/trunk/.classpath
    labs/pinpoint/trunk/pinpoint-cli/.classpath
    labs/pinpoint/trunk/pinpoint-cli/.project
    labs/pinpoint/trunk/pinpoint-core/.classpath
    labs/pinpoint/trunk/pinpoint-core/.project
    labs/pinpoint/trunk/pinpoint-core/pom.xml
    labs/pinpoint/trunk/pinpoint-core/src/main/java/org/apache/logging/pinpoint/converter/PinpointEventWriterHandler.java
    labs/pinpoint/trunk/pinpoint-core/src/main/java/org/apache/logging/pinpoint/jms/BufferedJMSLoggingEventHandler.java
    labs/pinpoint/trunk/pinpoint-importer/.classpath
    labs/pinpoint/trunk/pinpoint-importer/.project
    labs/pinpoint/trunk/pinpoint-search/.classpath
    labs/pinpoint/trunk/pinpoint-search/.project
    labs/pinpoint/trunk/pinpoint-service/.classpath
    labs/pinpoint/trunk/pinpoint-service/.project
    labs/pinpoint/trunk/pinpoint-service/pom.xml
    labs/pinpoint/trunk/pinpoint-service/src/main/resources/org/apache/logging/pinpoint/service/pinpoint-context.xml
    labs/pinpoint/trunk/pom.xml

Modified: labs/pinpoint/trunk/.classpath
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/.classpath?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/.classpath (original)
+++ labs/pinpoint/trunk/.classpath Fri Aug 17 03:59:16 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <classpath>
+	<classpathentry kind="src" path="pinpoint-metric/src/main/java"/>
+	<classpathentry kind="src" path="pinpoint-metric/src/test/java"/>
 	<classpathentry kind="src" path="pinpoint-core/src/main/java"/>
 	<classpathentry kind="src" path="pinpoint-core/src/test/java"/>
 	<classpathentry excluding="**" kind="src" output="pinpoint-core/src/main/resources" path="pinpoint-core/src/main/resources"/>
@@ -22,6 +24,7 @@
 	<classpathentry kind="src" path="pinpoint-service/src/test/java"/>
 	<classpathentry excluding="**" kind="src" output="pinpoint-service/src/main/resources" path="pinpoint-service/src/main/resources"/>
 	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/3"/>
 	<classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
 	<classpathentry kind="output" path="target/classes"/>
 </classpath>

Modified: labs/pinpoint/trunk/pinpoint-cli/.classpath
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-cli/.classpath?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-cli/.classpath (original)
+++ labs/pinpoint/trunk/pinpoint-cli/.classpath Fri Aug 17 03:59:16 2007
@@ -1,5 +1,41 @@
-<?xml version="1.0" encoding="UTF-8"?>
 <classpath>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="output" path="target/classes"/>
-</classpath>
+  <classpathentry kind="src" path="src/main/java"/>
+  <classpathentry kind="src" path="src/main/resources" excluding="**/*.java"/>
+  <classpathentry kind="src" path="src/test/java" output="target/test-classes"/>
+  <classpathentry kind="src" path="src/test/resources" output="target/test-classes" excluding="**/*.java"/>
+  <classpathentry kind="output" path="target/classes"/>
+  <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+  <classpathentry kind="var" path="M2_REPO/javax/activation/activation/1.1/activation-1.1.jar" sourcepath="M2_REPO/javax/activation/activation/1.1/activation-1.1-sources.jar"/>
+  <classpathentry kind="src" path="/pinpoint-core"/>
+  <classpathentry kind="var" path="M2_REPO/org/springframework/spring/2.0.5/spring-2.0.5.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-collections/commons-collections/3.2/commons-collections-3.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-discovery/commons-discovery/0.2/commons-discovery-0.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-math/commons-math/1.1/commons-math-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-cli/commons-cli/1.0/commons-cli-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-sources.jar">
+    <attributes>
+      <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
+    </attributes>
+  </classpathentry>
+  <classpathentry kind="var" path="M2_REPO/javax/mail/mail/1.4/mail-1.4.jar" sourcepath="M2_REPO/javax/mail/mail/1.4/mail-1.4-sources.jar"/>
+  <classpathentry kind="src" path="/pinpoint-metric"/>
+  <classpathentry kind="var" path="M2_REPO/javax/jms/jms/1.1/jms-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-io/commons-io/1.2/commons-io-1.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/junit/junit/3.8.1/junit-3.8.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/com/sun/jmx/jmxri/1.2.1/jmxri-1.2.1.jar"/>
+  <classpathentry kind="src" path="/pinpoint-search"/>
+  <classpathentry kind="var" path="M2_REPO/jfree/jfreechart/1.0.5/jfreechart-1.0.5.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jline/jline/0.9.91/jline-0.9.91.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-logging/commons-logging/1.0/commons-logging-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/hsqldb/hsqldb/1.8.0.7/hsqldb-1.8.0.7.jar"/>
+  <classpathentry kind="var" path="M2_REPO/com/sun/jdmk/jmxtools/1.2.1/jmxtools-1.2.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/joda-time/joda-time/1.4/joda-time-1.4.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jfree/jcommon/1.0.9/jcommon-1.0.9.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0.jar" sourcepath="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-component/1.0-SNAPSHOT/apache-log4j-component-1.0-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/apache-log4j-component/1.0-SNAPSHOT/apache-log4j-component-1.0-SNAPSHOT-sources.jar">
+    <attributes>
+      <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/apache-log4j-component/1.0-SNAPSHOT/apache-log4j-component-1.0-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
+    </attributes>
+  </classpathentry>
+  <classpathentry kind="var" path="M2_REPO/commons-lang/commons-lang/2.2/commons-lang-2.2.jar"/>
+</classpath>
\ No newline at end of file

Modified: labs/pinpoint/trunk/pinpoint-cli/.project
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-cli/.project?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-cli/.project (original)
+++ labs/pinpoint/trunk/pinpoint-cli/.project Fri Aug 17 03:59:16 2007
@@ -1,7 +1,11 @@
 <projectDescription>
   <name>pinpoint-cli</name>
   <comment>Index and search infrastructure for log4j</comment>
-  <projects/>
+  <projects>
+    <project>pinpoint-core</project>
+    <project>pinpoint-metric</project>
+    <project>pinpoint-search</project>
+  </projects>
   <buildSpec>
     <buildCommand>
       <name>org.eclipse.jdt.core.javabuilder</name>

Modified: labs/pinpoint/trunk/pinpoint-core/.classpath
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-core/.classpath?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-core/.classpath (original)
+++ labs/pinpoint/trunk/pinpoint-core/.classpath Fri Aug 17 03:59:16 2007
@@ -1,5 +1,38 @@
-<?xml version="1.0" encoding="UTF-8"?>
 <classpath>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="output" path="target/classes"/>
-</classpath>
+  <classpathentry kind="src" path="src/main/java"/>
+  <classpathentry kind="src" path="src/main/resources" excluding="**/*.java"/>
+  <classpathentry kind="src" path="src/test/java" output="target/test-classes"/>
+  <classpathentry kind="src" path="src/test/resources" output="target/test-classes" excluding="**/*.java"/>
+  <classpathentry kind="output" path="target/classes"/>
+  <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0.jar" sourcepath="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-collections/commons-collections/3.2/commons-collections-3.2.jar"/>
+  <classpathentry kind="src" path="/pinpoint-metric"/>
+  <classpathentry kind="var" path="M2_REPO/javax/activation/activation/1.1/activation-1.1.jar" sourcepath="M2_REPO/javax/activation/activation/1.1/activation-1.1-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-lang/commons-lang/2.2/commons-lang-2.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-math/commons-math/1.1/commons-math-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-component/1.0-SNAPSHOT/apache-log4j-component-1.0-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/apache-log4j-component/1.0-SNAPSHOT/apache-log4j-component-1.0-SNAPSHOT-sources.jar">
+    <attributes>
+      <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/apache-log4j-component/1.0-SNAPSHOT/apache-log4j-component-1.0-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
+    </attributes>
+  </classpathentry>
+  <classpathentry kind="var" path="M2_REPO/commons-discovery/commons-discovery/0.2/commons-discovery-0.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/mail/mail/1.4/mail-1.4.jar" sourcepath="M2_REPO/javax/mail/mail/1.4/mail-1.4-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/junit/junit/4.1/junit-4.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jfree/jcommon/1.0.9/jcommon-1.0.9.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-io/commons-io/1.2/commons-io-1.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/com/sun/jdmk/jmxtools/1.2.1/jmxtools-1.2.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-sources.jar">
+    <attributes>
+      <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
+    </attributes>
+  </classpathentry>
+  <classpathentry kind="var" path="M2_REPO/joda-time/joda-time/1.4/joda-time-1.4.jar"/>
+  <classpathentry kind="var" path="M2_REPO/com/sun/jmx/jmxri/1.2.1/jmxri-1.2.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/hsqldb/hsqldb/1.8.0.7/hsqldb-1.8.0.7.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jfree/jfreechart/1.0.5/jfreechart-1.0.5.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-cli/commons-cli/1.0/commons-cli-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/springframework/spring/2.0.5/spring-2.0.5.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/jms/jms/1.1/jms-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-logging/commons-logging/1.0/commons-logging-1.0.jar"/>
+</classpath>
\ No newline at end of file

Modified: labs/pinpoint/trunk/pinpoint-core/.project
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-core/.project?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-core/.project (original)
+++ labs/pinpoint/trunk/pinpoint-core/.project Fri Aug 17 03:59:16 2007
@@ -1,7 +1,9 @@
 <projectDescription>
   <name>pinpoint-core</name>
   <comment>Index and search infrastructure for log4j</comment>
-  <projects/>
+  <projects>
+    <project>pinpoint-metric</project>
+  </projects>
   <buildSpec>
     <buildCommand>
       <name>org.eclipse.jdt.core.javabuilder</name>

Modified: labs/pinpoint/trunk/pinpoint-core/pom.xml
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-core/pom.xml?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-core/pom.xml (original)
+++ labs/pinpoint/trunk/pinpoint-core/pom.xml Fri Aug 17 03:59:16 2007
@@ -21,6 +21,11 @@
       <artifactId>apache-log4j-component</artifactId>
       <version>${log4j.companion.version}</version>
     </dependency>
+	<dependency>
+		<groupId>org.apache.logging</groupId>
+		<artifactId>pinpoint-metric</artifactId>
+		<version>1.0-SNAPSHOT</version>
+	</dependency>
     <dependency>
       <groupId>org.apache.lucene</groupId>
       <artifactId>lucene-core</artifactId>

Modified: labs/pinpoint/trunk/pinpoint-core/src/main/java/org/apache/logging/pinpoint/converter/PinpointEventWriterHandler.java
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-core/src/main/java/org/apache/logging/pinpoint/converter/PinpointEventWriterHandler.java?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-core/src/main/java/org/apache/logging/pinpoint/converter/PinpointEventWriterHandler.java (original)
+++ labs/pinpoint/trunk/pinpoint-core/src/main/java/org/apache/logging/pinpoint/converter/PinpointEventWriterHandler.java Fri Aug 17 03:59:16 2007
@@ -16,6 +16,7 @@
 import org.apache.logging.pinpoint.LoggingEventHandler;
 import org.apache.logging.pinpoint.PinpointContext;
 import org.apache.logging.pinpoint.analyser.AnalyzerFactory;
+import org.apache.logging.pinpoint.metric.Counter;
 import org.apache.logging.pinpoint.selector.PinpointContextSelector;
 import org.apache.logging.pinpoint.store.EventStore;
 import org.apache.logging.pinpoint.store.SimpleEventStore;
@@ -36,12 +37,15 @@
 
     private final AnalyzerFactory analyserFactory;
 
+    private final Counter eventsWrittenCounter;
+
     public PinpointEventWriterHandler(PinpointContextSelector selector,
             IndexWriterFactory indexWriterFactory,
-            AnalyzerFactory analyzerFactory) {
+            AnalyzerFactory analyzerFactory, Counter counter) {
         this.selector = selector;
         this.indexWriterFactor = indexWriterFactory;
         this.analyserFactory = analyzerFactory;
+        this.eventsWrittenCounter = counter;
         final PinpointEventWriterHandler toClose = this;
 
         // TODO this is to ensure things are flushed cleanly to the index if the
@@ -76,6 +80,7 @@
                 contextMap.put(ctx, container);
             }
             container.eventWriter.writeEvent(event);
+            this.eventsWrittenCounter.inc();
         } catch (IOException e) {
             // TODO Handle failure
             e.printStackTrace();

Modified: labs/pinpoint/trunk/pinpoint-core/src/main/java/org/apache/logging/pinpoint/jms/BufferedJMSLoggingEventHandler.java
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-core/src/main/java/org/apache/logging/pinpoint/jms/BufferedJMSLoggingEventHandler.java?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-core/src/main/java/org/apache/logging/pinpoint/jms/BufferedJMSLoggingEventHandler.java (original)
+++ labs/pinpoint/trunk/pinpoint-core/src/main/java/org/apache/logging/pinpoint/jms/BufferedJMSLoggingEventHandler.java Fri Aug 17 03:59:16 2007
@@ -14,6 +14,7 @@
 
 import org.apache.log4j.spi.LoggingEvent;
 import org.apache.logging.pinpoint.LoggingEventHandler;
+import org.apache.logging.pinpoint.metric.Counter;
 import org.springframework.jms.core.JmsTemplate;
 import org.springframework.jms.core.MessageCreator;
 
@@ -32,6 +33,8 @@
 
     private final JmsTemplate jmsTemplate;
 
+    private final Counter receivedCounter;
+
     public void handleEvent(final LoggingEvent event) {
         jmsTemplate.send(new MessageCreator() {
 
@@ -39,12 +42,15 @@
                 return session.createObjectMessage(event);
             }
         });
+        receivedCounter.inc();
 
     }
 
-    public BufferedJMSLoggingEventHandler(JmsTemplate jmsTemplate) {
+    public BufferedJMSLoggingEventHandler(JmsTemplate jmsTemplate,
+            Counter counter) {
         super();
         this.jmsTemplate = jmsTemplate;
+        this.receivedCounter = counter;
     }
 
 }

Modified: labs/pinpoint/trunk/pinpoint-importer/.classpath
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-importer/.classpath?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-importer/.classpath (original)
+++ labs/pinpoint/trunk/pinpoint-importer/.classpath Fri Aug 17 03:59:16 2007
@@ -5,30 +5,46 @@
   <classpathentry kind="src" path="src/test/resources" output="target/test-classes" excluding="**/*.java"/>
   <classpathentry kind="output" path="target/classes"/>
   <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-  <classpathentry kind="var" path="M2_REPO/commons-cli/commons-cli/1.1/commons-cli-1.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-component/1.0/apache-log4j-component-1.0.jar"/>
-  <classpathentry kind="var" path="M2_REPO/joda-time/joda-time/1.4/joda-time-1.4.jar"/>
-  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-receivers/1.1-SNAPSHOT/apache-log4j-receivers-1.1-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/apache-log4j-receivers/1.1-SNAPSHOT/apache-log4j-receivers-1.1-SNAPSHOT-sources.jar">
+  <classpathentry kind="var" path="M2_REPO/commons-io/commons-io/1.2/commons-io-1.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jfree/jcommon/1.0.9/jcommon-1.0.9.jar"/>
+  <classpathentry kind="src" path="/pinpoint-metric"/>
+  <classpathentry kind="var" path="M2_REPO/com/sun/jdmk/jmxtools/1.2.1/jmxtools-1.2.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/logkit/logkit/1.0.1/logkit-1.0.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-extras/1.0/apache-log4j-extras-1.0.jar" sourcepath="M2_REPO/log4j/apache-log4j-extras/1.0/apache-log4j-extras-1.0-sources.jar">
     <attributes>
-      <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/apache-log4j-receivers/1.1-SNAPSHOT/apache-log4j-receivers-1.1-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
+      <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/apache-log4j-extras/1.0/apache-log4j-extras-1.0-javadoc.jar!/" name="javadoc_location"/>
     </attributes>
   </classpathentry>
-  <classpathentry kind="var" path="M2_REPO/commons-lang/commons-lang/2.2/commons-lang-2.2.jar"/>
-  <classpathentry kind="var" path="M2_REPO/junit/junit/3.8.1/junit-3.8.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/oro/oro/2.0.8/oro-2.0.8.jar" sourcepath="M2_REPO/oro/oro/2.0.8/oro-2.0.8-sources.jar"/>
-  <classpathentry kind="var" path="M2_REPO/javax/activation/activation/1.1/activation-1.1.jar" sourcepath="M2_REPO/javax/activation/activation/1.1/activation-1.1-sources.jar"/>
-  <classpathentry kind="var" path="M2_REPO/com/sun/jdmk/jmxtools/1.2.1/jmxtools-1.2.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/com/sun/jmx/jmxri/1.2.1/jmxri-1.2.1.jar"/>
   <classpathentry kind="var" path="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-sources.jar">
     <attributes>
       <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
     </attributes>
   </classpathentry>
-  <classpathentry kind="var" path="M2_REPO/commons-io/commons-io/1.2/commons-io-1.2.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/logging/pinpoint-core/1.0-SNAPSHOT/pinpoint-core-1.0-SNAPSHOT.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0.jar"/>
-  <classpathentry kind="var" path="M2_REPO/javax/jms/jms/1.1/jms-1.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-filters/1.0/apache-log4j-filters-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/activation/activation/1.1/activation-1.1.jar" sourcepath="M2_REPO/javax/activation/activation/1.1/activation-1.1-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-receivers/1.1-SNAPSHOT/apache-log4j-receivers-1.1-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/apache-log4j-receivers/1.1-SNAPSHOT/apache-log4j-receivers-1.1-SNAPSHOT-sources.jar">
+    <attributes>
+      <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/apache-log4j-receivers/1.1-SNAPSHOT/apache-log4j-receivers-1.1-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
+    </attributes>
+  </classpathentry>
+  <classpathentry kind="var" path="M2_REPO/junit/junit/3.8.1/junit-3.8.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0.jar" sourcepath="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-cli/commons-cli/1.1/commons-cli-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-logging/commons-logging/1.1/commons-logging-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/joda-time/joda-time/1.4/joda-time-1.4.jar"/>
+  <classpathentry kind="var" path="M2_REPO/avalon-framework/avalon-framework/4.1.3/avalon-framework-4.1.3.jar"/>
+  <classpathentry kind="var" path="M2_REPO/com/sun/jmx/jmxri/1.2.1/jmxri-1.2.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jfree/jfreechart/1.0.5/jfreechart-1.0.5.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/springframework/spring/2.0.5/spring-2.0.5.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-lang/commons-lang/2.2/commons-lang-2.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/hsqldb/hsqldb/1.8.0.7/hsqldb-1.8.0.7.jar"/>
   <classpathentry kind="var" path="M2_REPO/javax/mail/mail/1.4/mail-1.4.jar" sourcepath="M2_REPO/javax/mail/mail/1.4/mail-1.4-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-math/commons-math/1.1/commons-math-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-collections/commons-collections/3.2/commons-collections-3.2.jar"/>
   <classpathentry kind="var" path="M2_REPO/jline/jline/0.9.91/jline-0.9.91.jar"/>
+  <classpathentry kind="src" path="/pinpoint-core"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-component/1.0/apache-log4j-component-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/jms/jms/1.1/jms-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/oro/oro/2.0.8/oro-2.0.8.jar" sourcepath="M2_REPO/oro/oro/2.0.8/oro-2.0.8-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-discovery/commons-discovery/0.2/commons-discovery-0.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/servlet/servlet-api/2.3/servlet-api-2.3.jar" sourcepath="M2_REPO/javax/servlet/servlet-api/2.3/servlet-api-2.3-sources.jar"/>
 </classpath>

Modified: labs/pinpoint/trunk/pinpoint-importer/.project
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-importer/.project?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-importer/.project (original)
+++ labs/pinpoint/trunk/pinpoint-importer/.project Fri Aug 17 03:59:16 2007
@@ -1,7 +1,10 @@
 <projectDescription>
   <name>pinpoint-importer</name>
   <comment>Index and search infrastructure for log4j</comment>
-  <projects/>
+  <projects>
+    <project>pinpoint-metric</project>
+    <project>pinpoint-core</project>
+  </projects>
   <buildSpec>
     <buildCommand>
       <name>org.eclipse.jdt.core.javabuilder</name>

Propchange: labs/pinpoint/trunk/pinpoint-metric/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Fri Aug 17 03:59:16 2007
@@ -0,0 +1,4 @@
+target
+.settings
+.classpath
+.project

Added: labs/pinpoint/trunk/pinpoint-metric/pom.xml
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-metric/pom.xml?view=auto&rev=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-metric/pom.xml (added)
+++ labs/pinpoint/trunk/pinpoint-metric/pom.xml Fri Aug 17 03:59:16 2007
@@ -0,0 +1,38 @@
+<?xml version="1.0"?>
+<project>
+  <parent>
+    <artifactId>pinpoint</artifactId>
+    <groupId>org.apache.logging</groupId>
+    <version>1.0-SNAPSHOT</version>
+  </parent>
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>org.apache.logging</groupId>
+  <artifactId>pinpoint-metric</artifactId>
+  <name>Pinpoint Metric</name>
+  <description>Provides performance metric infrastructure for observing metric data over time</description>
+  <version>1.0-SNAPSHOT</version>
+  <url>http://maven.apache.org</url>
+  <dependencies>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>commons-math</groupId>
+      <artifactId>commons-math</artifactId>
+      <version>1.1</version>
+    </dependency>
+    <dependency>
+      <groupId>org.springframework</groupId>
+      <artifactId>spring</artifactId>
+      <version>2.0.5</version>
+    </dependency>
+	<dependency>
+	    <groupId>jfree</groupId>
+	    <artifactId>jfreechart</artifactId>
+	    <version>1.0.5</version>
+	</dependency>
+  </dependencies>
+</project>

Added: labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/Counter.java
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/Counter.java?view=auto&rev=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/Counter.java (added)
+++ labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/Counter.java Fri Aug 17 03:59:16 2007
@@ -0,0 +1,62 @@
+package org.apache.logging.pinpoint.metric;
+
+import java.util.Collections;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.concurrent.atomic.AtomicLong;
+
+import org.springframework.jmx.export.annotation.ManagedAttribute;
+import org.springframework.jmx.export.annotation.ManagedResource;
+
+@ManagedResource
+public class Counter {
+
+    /**
+     * Default value should hold enough data for 1 hours worth of data sampled
+     * every 5 seconds.
+     */
+    private static final int DEFAULT_WINDOW_SIZE = (60 * 60) / 5;
+
+    private final String metricName;
+
+    private LinkedList<ObservedValue> observations = new LinkedList<ObservedValue>();
+
+    private final AtomicLong counter = new AtomicLong(0);
+
+    private int windowSize = DEFAULT_WINDOW_SIZE;
+
+    public Counter(String metricName) {
+        this.metricName = metricName;
+    }
+
+    public void inc() {
+        counter.incrementAndGet();
+    }
+
+    public final List<ObservedValue> getObservations() {
+        return Collections.unmodifiableList(observations);
+    }
+
+    @ManagedAttribute(description = "Current value")
+    public long getValue() {
+        return counter.get();
+    }
+
+    @ManagedAttribute(description = "Metric Name")
+    public final String getMetricName() {
+        return metricName;
+    }
+
+    /**
+     * Call this method periodically to internally sample the current value and
+     * store it with the internally buffered statistics
+     */
+    public synchronized void observe() {
+        observations.add(new ObservedValue(System.currentTimeMillis(),
+                getValue()));
+        while (observations.size() > this.windowSize) {
+            observations.removeFirst();
+        }
+    }
+
+}

Added: labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/MetricRegistry.java
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/MetricRegistry.java?view=auto&rev=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/MetricRegistry.java (added)
+++ labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/MetricRegistry.java Fri Aug 17 03:59:16 2007
@@ -0,0 +1,72 @@
+package org.apache.logging.pinpoint.metric;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Timer;
+import java.util.TimerTask;
+
+import org.apache.log4j.Logger;
+import org.springframework.context.Lifecycle;
+import org.springframework.jmx.export.annotation.ManagedAttribute;
+import org.springframework.jmx.export.annotation.ManagedResource;
+
+@ManagedResource
+public class MetricRegistry implements Lifecycle {
+
+    private static final Logger LOG = Logger.getLogger(MetricRegistry.class);
+
+    private List<Counter> counters = new ArrayList<Counter>();
+    private Timer timer = new Timer("MetricRegistry", true);
+    private boolean running = true;
+
+    private int sampleInterval = 5;
+
+    public MetricRegistry(int sampleInterval) {
+        this.sampleInterval = sampleInterval;
+    }
+
+    public void addCounter(Counter counter) {
+        if (LOG.isDebugEnabled()) {
+            LOG.debug("Adding counter '" + counter.getMetricName() + "'");
+        }
+        counters.add(counter);
+    }
+
+    public void setCounters(List<Counter> counters) {
+        this.counters = counters;
+    }
+
+    private class ObservingTimerTask extends TimerTask {
+
+        @Override
+        public void run() {
+            for (Counter counter : counters) {
+                counter.observe();
+            }
+        }
+
+    }
+
+    public boolean isRunning() {
+        return this.running;
+    }
+
+    public void start() {
+        LOG.info("MetricRegistry is starting.  Scheduling every " + 5 +
+                " seconds");
+        timer.schedule(new ObservingTimerTask(), 0, sampleInterval * 1000);
+        this.running = true;
+    }
+
+    public void stop() {
+        LOG.info("MetricRegistry is stopping");
+        timer.cancel();
+        this.running = false;
+    }
+
+    @ManagedAttribute(description = "The number of seconds between observations of all registered metrics")
+    public final int getSampleInterval() {
+        return sampleInterval;
+    }
+
+}

Added: labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/ObservedValue.java
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/ObservedValue.java?view=auto&rev=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/ObservedValue.java (added)
+++ labs/pinpoint/trunk/pinpoint-metric/src/main/java/org/apache/logging/pinpoint/metric/ObservedValue.java Fri Aug 17 03:59:16 2007
@@ -0,0 +1,20 @@
+package org.apache.logging.pinpoint.metric;
+
+public class ObservedValue {
+
+    private long timestamp;
+    private long observedValue;
+
+    public ObservedValue(long timestamp, long observedValue) {
+        this.timestamp = timestamp;
+        this.observedValue = observedValue;
+    }
+
+    public final long getTimestamp() {
+        return timestamp;
+    }
+
+    public final long getObservedValue() {
+        return observedValue;
+    }
+}

Added: labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/CounterTest.java
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/CounterTest.java?view=auto&rev=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/CounterTest.java (added)
+++ labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/CounterTest.java Fri Aug 17 03:59:16 2007
@@ -0,0 +1,26 @@
+package org.apache.logging.pinpoint.metric;
+
+import junit.framework.TestCase;
+
+public class CounterTest extends TestCase {
+
+    protected void setUp() throws Exception {
+        super.setUp();
+    }
+
+    protected void tearDown() throws Exception {
+        super.tearDown();
+    }
+
+    public void testObserve() {
+        Counter counter = new Counter("Foo");
+        assertEquals(0, counter.getValue());
+        counter.inc();
+        assertEquals(1, counter.getValue());
+        assertEquals(counter.getObservations().size(), 0);
+        counter.observe();
+        assertEquals(counter.getObservations().size(), 1);
+
+    }
+
+}

Added: labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/MetricRegistryTest.java
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/MetricRegistryTest.java?view=auto&rev=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/MetricRegistryTest.java (added)
+++ labs/pinpoint/trunk/pinpoint-metric/src/test/java/org/apache/logging/pinpoint/metric/MetricRegistryTest.java Fri Aug 17 03:59:16 2007
@@ -0,0 +1,26 @@
+package org.apache.logging.pinpoint.metric;
+
+import junit.framework.TestCase;
+
+public class MetricRegistryTest extends TestCase {
+
+    private MetricRegistry registry = new MetricRegistry(100);
+    private Counter fooCounter;
+
+    public void setUp() throws Exception {
+        this.fooCounter = new Counter("foo");
+        registry.addCounter(fooCounter);
+        registry.start();
+    }
+
+    public void tearDown() throws Exception {
+        registry.stop();
+    }
+
+    public void testObservation() throws Exception {
+        fooCounter.inc();
+        Thread.sleep(1000);
+        assertEquals(1, fooCounter.getObservations().size());
+        assertEquals(1, fooCounter.getObservations().get(0).getObservedValue());
+    }
+}

Modified: labs/pinpoint/trunk/pinpoint-search/.classpath
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-search/.classpath?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-search/.classpath (original)
+++ labs/pinpoint/trunk/pinpoint-search/.classpath Fri Aug 17 03:59:16 2007
@@ -5,27 +5,38 @@
   <classpathentry kind="src" path="src/test/resources" output="target/test-classes" excluding="**/*.java"/>
   <classpathentry kind="output" path="target/classes"/>
   <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-  <classpathentry kind="var" path="M2_REPO/javax/activation/activation/1.1/activation-1.1.jar" sourcepath="M2_REPO/javax/activation/activation/1.1/activation-1.1-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-io/commons-io/1.2/commons-io-1.2.jar"/>
+  <classpathentry kind="src" path="/pinpoint-metric"/>
+  <classpathentry kind="var" path="M2_REPO/commons-logging/commons-logging/1.1/commons-logging-1.1.jar"/>
   <classpathentry kind="var" path="M2_REPO/com/sun/jmx/jmxri/1.2.1/jmxri-1.2.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/hsqldb/hsqldb/1.8.0.7/hsqldb-1.8.0.7.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/springframework/spring/2.0.5/spring-2.0.5.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jfree/jcommon/1.0.9/jcommon-1.0.9.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/mail/mail/1.4/mail-1.4.jar" sourcepath="M2_REPO/javax/mail/mail/1.4/mail-1.4-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-cli/commons-cli/1.0/commons-cli-1.0.jar"/>
+  <classpathentry kind="src" path="/pinpoint-core"/>
+  <classpathentry kind="var" path="M2_REPO/commons-discovery/commons-discovery/0.2/commons-discovery-0.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jfree/jfreechart/1.0.5/jfreechart-1.0.5.jar"/>
+  <classpathentry kind="var" path="M2_REPO/com/sun/jdmk/jmxtools/1.2.1/jmxtools-1.2.1.jar"/>
   <classpathentry kind="var" path="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-sources.jar">
     <attributes>
       <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
     </attributes>
   </classpathentry>
-  <classpathentry kind="var" path="M2_REPO/commons-logging/commons-logging/1.0/commons-logging-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/junit/junit/3.8.2/junit-3.8.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-collections/commons-collections/3.2/commons-collections-3.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/jms/jms/1.1/jms-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/logkit/logkit/1.0.1/logkit-1.0.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/avalon-framework/avalon-framework/4.1.3/avalon-framework-4.1.3.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0.jar" sourcepath="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/activation/activation/1.1/activation-1.1.jar" sourcepath="M2_REPO/javax/activation/activation/1.1/activation-1.1-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-math/commons-math/1.1/commons-math-1.1.jar"/>
   <classpathentry kind="var" path="M2_REPO/commons-lang/commons-lang/2.2/commons-lang-2.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/joda-time/joda-time/1.4/joda-time-1.4.jar"/>
   <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-component/1.0-SNAPSHOT/apache-log4j-component-1.0-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/apache-log4j-component/1.0-SNAPSHOT/apache-log4j-component-1.0-SNAPSHOT-sources.jar">
     <attributes>
       <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/apache-log4j-component/1.0-SNAPSHOT/apache-log4j-component-1.0-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
     </attributes>
   </classpathentry>
-  <classpathentry kind="var" path="M2_REPO/com/sun/jdmk/jmxtools/1.2.1/jmxtools-1.2.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/javax/mail/mail/1.4/mail-1.4.jar" sourcepath="M2_REPO/javax/mail/mail/1.4/mail-1.4-sources.jar"/>
-  <classpathentry kind="var" path="M2_REPO/joda-time/joda-time/1.4/joda-time-1.4.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/logging/pinpoint-core/1.0-SNAPSHOT/pinpoint-core-1.0-SNAPSHOT.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0.jar"/>
-  <classpathentry kind="var" path="M2_REPO/commons-io/commons-io/1.2/commons-io-1.2.jar"/>
-  <classpathentry kind="var" path="M2_REPO/javax/jms/jms/1.1/jms-1.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/junit/junit/3.8.2/junit-3.8.2.jar"/>
-  <classpathentry kind="var" path="M2_REPO/commons-cli/commons-cli/1.0/commons-cli-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/servlet/servlet-api/2.3/servlet-api-2.3.jar" sourcepath="M2_REPO/javax/servlet/servlet-api/2.3/servlet-api-2.3-sources.jar"/>
 </classpath>

Modified: labs/pinpoint/trunk/pinpoint-search/.project
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-search/.project?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-search/.project (original)
+++ labs/pinpoint/trunk/pinpoint-search/.project Fri Aug 17 03:59:16 2007
@@ -1,7 +1,10 @@
 <projectDescription>
   <name>pinpoint-search</name>
   <comment>Index and search infrastructure for log4j</comment>
-  <projects/>
+  <projects>
+    <project>pinpoint-metric</project>
+    <project>pinpoint-core</project>
+  </projects>
   <buildSpec>
     <buildCommand>
       <name>org.eclipse.jdt.core.javabuilder</name>

Modified: labs/pinpoint/trunk/pinpoint-service/.classpath
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-service/.classpath?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-service/.classpath (original)
+++ labs/pinpoint/trunk/pinpoint-service/.classpath Fri Aug 17 03:59:16 2007
@@ -4,43 +4,56 @@
   <classpathentry kind="src" path="src/test/java" output="target/test-classes"/>
   <classpathentry kind="output" path="target/classes"/>
   <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/geronimo/specs/geronimo-jms_1.1_spec/1.0/geronimo-jms_1.1_spec-1.0.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/geronimo/specs/geronimo-j2ee-management_1.0_spec/1.0/geronimo-j2ee-management_1.0_spec-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/springframework/spring/2.0.5/spring-2.0.5.jar"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-component/1.0/apache-log4j-component-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-extras/1.0/apache-log4j-extras-1.0.jar" sourcepath="M2_REPO/log4j/apache-log4j-extras/1.0/apache-log4j-extras-1.0-sources.jar">
+    <attributes>
+      <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/apache-log4j-extras/1.0/apache-log4j-extras-1.0-javadoc.jar!/" name="javadoc_location"/>
+    </attributes>
+  </classpathentry>
   <classpathentry kind="var" path="M2_REPO/avalon-framework/avalon-framework/4.1.3/avalon-framework-4.1.3.jar"/>
+  <classpathentry kind="var" path="M2_REPO/hsqldb/hsqldb/1.8.0.7/hsqldb-1.8.0.7.jar"/>
+  <classpathentry kind="var" path="M2_REPO/logkit/logkit/1.0.1/logkit-1.0.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/jms/jms/1.1/jms-1.1.jar"/>
   <classpathentry kind="var" path="M2_REPO/javax/mail/mail/1.4/mail-1.4.jar" sourcepath="M2_REPO/javax/mail/mail/1.4/mail-1.4-sources.jar"/>
-  <classpathentry kind="var" path="M2_REPO/oro/oro/2.0.8/oro-2.0.8.jar" sourcepath="M2_REPO/oro/oro/2.0.8/oro-2.0.8-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-math/commons-math/1.1/commons-math-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-discovery/commons-discovery/0.2/commons-discovery-0.2.jar"/>
   <classpathentry kind="var" path="M2_REPO/org/apache/xbean/xbean-spring-v2/2.8/xbean-spring-v2-2.8.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/springframework/spring/2.0.5/spring-2.0.5.jar"/>
-  <classpathentry kind="var" path="M2_REPO/logkit/logkit/1.0.1/logkit-1.0.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/activemq/activeio-core/3.0.0-incubator/activeio-core-3.0.0-incubator.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0.jar"/>
-  <classpathentry kind="var" path="M2_REPO/javax/servlet/servlet-api/2.3/servlet-api-2.3.jar" sourcepath="M2_REPO/javax/servlet/servlet-api/2.3/servlet-api-2.3-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/com/sun/jdmk/jmxtools/1.2.1/jmxtools-1.2.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-collections/commons-collections/3.2/commons-collections-3.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0.jar" sourcepath="M2_REPO/org/apache/lucene/lucene-core/2.2.0/lucene-core-2.2.0-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-lang/commons-lang/2.2/commons-lang-2.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/oro/oro/2.0.8/oro-2.0.8.jar" sourcepath="M2_REPO/oro/oro/2.0.8/oro-2.0.8-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-logging/commons-logging/1.1/commons-logging-1.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jfree/jcommon/1.0.9/jcommon-1.0.9.jar"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-sources.jar">
+    <attributes>
+      <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
+    </attributes>
+  </classpathentry>
+  <classpathentry kind="var" path="M2_REPO/commons-daemon/commons-daemon/1.0.1/commons-daemon-1.0.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/xbean/xbean-spring-common/2.8/xbean-spring-common-2.8.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/geronimo/specs/geronimo-j2ee-management_1.0_spec/1.0/geronimo-j2ee-management_1.0_spec-1.0.jar"/>
   <classpathentry kind="var" path="M2_REPO/com/sun/jmx/jmxri/1.2.1/jmxri-1.2.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/junit/junit/3.8.1/junit-3.8.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-filters/1.0/apache-log4j-filters-1.0.jar"/>
-  <classpathentry kind="var" path="M2_REPO/commons-cli/commons-cli/1.0/commons-cli-1.0.jar"/>
-  <classpathentry kind="var" path="M2_REPO/javax/jms/jms/1.1/jms-1.1.jar"/>
   <classpathentry kind="var" path="M2_REPO/javax/activation/activation/1.1/activation-1.1.jar" sourcepath="M2_REPO/javax/activation/activation/1.1/activation-1.1-sources.jar"/>
   <classpathentry kind="var" path="M2_REPO/backport-util-concurrent/backport-util-concurrent/2.1/backport-util-concurrent-2.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/commons-lang/commons-lang/2.2/commons-lang-2.2.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/activemq/activemq-core/4.1.1/activemq-core-4.1.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/logging/pinpoint-core/1.0-SNAPSHOT/pinpoint-core-1.0-SNAPSHOT.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-io/commons-io/1.2/commons-io-1.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/servlet/servlet-api/2.3/servlet-api-2.3.jar" sourcepath="M2_REPO/javax/servlet/servlet-api/2.3/servlet-api-2.3-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jfree/jfreechart/1.0.5/jfreechart-1.0.5.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/derby/derby/10.2.2.0/derby-10.2.2.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/joda-time/joda-time/1.4/joda-time-1.4.jar"/>
   <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-receivers/1.1-SNAPSHOT/apache-log4j-receivers-1.1-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/apache-log4j-receivers/1.1-SNAPSHOT/apache-log4j-receivers-1.1-SNAPSHOT-sources.jar">
     <attributes>
       <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/apache-log4j-receivers/1.1-SNAPSHOT/apache-log4j-receivers-1.1-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
     </attributes>
   </classpathentry>
+  <classpathentry kind="var" path="M2_REPO/org/apache/activemq/activemq-core/4.1.1/activemq-core-4.1.1.jar"/>
+  <classpathentry kind="src" path="/pinpoint-metric"/>
+  <classpathentry kind="var" path="M2_REPO/junit/junit/3.8.1/junit-3.8.1.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/geronimo/specs/geronimo-jms_1.1_spec/1.0/geronimo-jms_1.1_spec-1.0.jar"/>
   <classpathentry kind="var" path="M2_REPO/org/apache/xbean/xbean-spring/2.8/xbean-spring-2.8.jar"/>
-  <classpathentry kind="var" path="M2_REPO/log4j/apache-log4j-component/1.0/apache-log4j-component-1.0.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/logging/pinpoint-search/1.0-SNAPSHOT/pinpoint-search-1.0-SNAPSHOT.jar"/>
-  <classpathentry kind="var" path="M2_REPO/com/sun/jdmk/jmxtools/1.2.1/jmxtools-1.2.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/joda-time/joda-time/1.4/joda-time-1.4.jar"/>
-  <classpathentry kind="var" path="M2_REPO/commons-io/commons-io/1.2/commons-io-1.2.jar"/>
-  <classpathentry kind="var" path="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT.jar" sourcepath="M2_REPO/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-sources.jar">
-    <attributes>
-      <attribute value="jar:file://Users/paulsmith/.m2/repository/log4j/log4j/1.2.15-SNAPSHOT/log4j-1.2.15-SNAPSHOT-javadoc.jar!/" name="javadoc_location"/>
-    </attributes>
-  </classpathentry>
-  <classpathentry kind="var" path="M2_REPO/commons-logging/commons-logging/1.1/commons-logging-1.1.jar"/>
-  <classpathentry kind="var" path="M2_REPO/org/apache/xbean/xbean-spring-common/2.8/xbean-spring-common-2.8.jar"/>
+  <classpathentry kind="src" path="/pinpoint-core"/>
+  <classpathentry kind="src" path="/pinpoint-search"/>
+  <classpathentry kind="var" path="M2_REPO/commons-cli/commons-cli/1.0/commons-cli-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/activemq/activeio-core/3.0.0-incubator/activeio-core-3.0.0-incubator.jar"/>
 </classpath>

Modified: labs/pinpoint/trunk/pinpoint-service/.project
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-service/.project?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-service/.project (original)
+++ labs/pinpoint/trunk/pinpoint-service/.project Fri Aug 17 03:59:16 2007
@@ -1,7 +1,11 @@
 <projectDescription>
   <name>pinpoint-service</name>
   <comment>Index and search infrastructure for log4j</comment>
-  <projects/>
+  <projects>
+    <project>pinpoint-metric</project>
+    <project>pinpoint-core</project>
+    <project>pinpoint-search</project>
+  </projects>
   <buildSpec>
     <buildCommand>
       <name>org.eclipse.jdt.core.javabuilder</name>

Modified: labs/pinpoint/trunk/pinpoint-service/pom.xml
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-service/pom.xml?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-service/pom.xml (original)
+++ labs/pinpoint/trunk/pinpoint-service/pom.xml Fri Aug 17 03:59:16 2007
@@ -10,6 +10,38 @@
   <artifactId>pinpoint-service</artifactId>
   <name>Pinpoint Service Layer</name>
   <version>1.0-SNAPSHOT</version>
+  <build>
+    <plugins>
+      <plugin>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <configuration>
+          <source>1.5</source>
+          <target>1.5</target>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>appassembler-maven-plugin</artifactId>
+        <executions>
+          <execution>
+            <phase>package</phase>
+            <goals>
+              <goal>assemble</goal>
+            </goals>
+          </execution>
+        </executions>
+        <configuration>
+          <extraJvmArguments>-Xmx256m -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.port=5678 -Dcom.sun.management.jmxremote.ssl=false</extraJvmArguments>
+          <programs>
+            <program>
+              <mainClass>org.apache.logging.pinpoint.service.Service</mainClass>
+              <name>pinpoint-service</name>
+            </program>
+          </programs>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
   <dependencies>
     <dependency>
       <groupId>org.apache.logging</groupId>
@@ -71,4 +103,3 @@
     <lucene.version>2.2.0</lucene.version>
   </properties>
 </project>
-

Modified: labs/pinpoint/trunk/pinpoint-service/src/main/resources/org/apache/logging/pinpoint/service/pinpoint-context.xml
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pinpoint-service/src/main/resources/org/apache/logging/pinpoint/service/pinpoint-context.xml?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pinpoint-service/src/main/resources/org/apache/logging/pinpoint/service/pinpoint-context.xml (original)
+++ labs/pinpoint/trunk/pinpoint-service/src/main/resources/org/apache/logging/pinpoint/service/pinpoint-context.xml Fri Aug 17 03:59:16 2007
@@ -49,10 +49,33 @@
   	<constructor-arg ref="contextSelector" />
   	<constructor-arg ref="indexWriterFactory" />
   	<constructor-arg ref="analyserFactory" />
+  	<constructor-arg ref="eventsWrittenCounter" />
+  </bean>
+
+  <bean id="receivedEventsCounter" class="org.apache.logging.pinpoint.metric.Counter" >
+  	<meta key="jmxObjectName" value="Pinpoint:type=Metrics,name=receivedEventsCounter" />
+  	<constructor-arg value="Number of Received Events" />
+  </bean>  
+
+  <bean id="eventsWrittenCounter" class="org.apache.logging.pinpoint.metric.Counter" >
+  	<meta key="jmxObjectName" value="Pinpoint:type=Metrics,name=indexedEventsCounter" />
+  	<constructor-arg value="Number of Indexed Events" />
+  </bean>  
+  
+  <bean id="metricRegistry" class="org.apache.logging.pinpoint.metric.MetricRegistry" >
+  	<meta key="jmxObjectName" value="Pinpoint:type=Metrics,name=MetricRegistry" />
+    <constructor-arg value="5" />
+	<property name="counters">
+		<list>
+			<ref bean="receivedEventsCounter" />
+			<ref bean="eventsWrittenCounter" />
+		</list>
+	</property>  	
   </bean>
   
   <bean id="loggingEventHandler" class="org.apache.logging.pinpoint.jms.BufferedJMSLoggingEventHandler">
  	<constructor-arg ref="jmsTemplate" />
+ 	<constructor-arg ref="receivedEventsCounter" />
   </bean>
   
   <bean id="pinpointAppender" class="org.apache.logging.pinpoint.converter.PinpointAppender" init-method="activateOptions">

Modified: labs/pinpoint/trunk/pom.xml
URL: http://svn.apache.org/viewvc/labs/pinpoint/trunk/pom.xml?view=diff&rev=567011&r1=567010&r2=567011
==============================================================================
--- labs/pinpoint/trunk/pom.xml (original)
+++ labs/pinpoint/trunk/pom.xml Fri Aug 17 03:59:16 2007
@@ -15,8 +15,7 @@
  See the License for the specific language governing permissions and
  limitations under the License.
 
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+--><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
   <modelVersion>4.0.0</modelVersion>
   <groupId>org.apache.logging</groupId>
   <artifactId>pinpoint</artifactId>
@@ -38,6 +37,7 @@
     <module>pinpoint-core</module>
     <module>pinpoint-web</module>
     <module>pinpoint-service</module>
+    <module>pinpoint-metric</module>
   </modules>
   <build>
     <plugins>



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@labs.apache.org
For additional commands, e-mail: commits-help@labs.apache.org


Mime
View raw message