geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jgenen...@apache.org
Subject svn commit: r475887 - in /geronimo/sandbox/gcache/common/src: main/java/org/apache/geronimo/gcache/transports/ main/java/org/apache/geronimo/gcache/transports/discovery/ main/java/org/apache/geronimo/gcache/transports/discovery/multicast/ main/java/org...
Date Thu, 16 Nov 2006 19:26:11 GMT
Author: jgenender
Date: Thu Nov 16 11:26:10 2006
New Revision: 475887

URL: http://svn.apache.org/viewvc?view=rev&rev=475887
Log:
Move network stuff

Added:
    geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/network/
      - copied from r474856, geronimo/sandbox/gcache/server/src/main/java/org/apache/geronimo/gcache/transports/network/
    geronimo/sandbox/gcache/common/src/test/resources/
    geronimo/sandbox/gcache/common/src/test/resources/log4j.xml   (with props)
Modified:
    geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/EndpointManager.java
    geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/TransportFactory.java
    geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/discovery/DiscoveryAgentFactory.java
    geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/discovery/multicast/MulticastDiscoveryAgent.java
    geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/util/FactoryFinder.java

Modified: geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/EndpointManager.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/EndpointManager.java?view=diff&rev=475887&r1=475886&r2=475887
==============================================================================
--- geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/EndpointManager.java
(original)
+++ geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/EndpointManager.java
Thu Nov 16 11:26:10 2006
@@ -20,29 +20,31 @@
 import java.util.Collections;
 import java.util.HashSet;
 import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.CopyOnWriteArraySet;
 
 public class EndpointManager {
-    
-    Set<Endpoint> endpoints = Collections.synchronizedSet(new HashSet<Endpoint>());
-    
-    public void addEndpoint(Endpoint endpoint){
-	endpoints.add(endpoint);
+
+    CopyOnWriteArraySet endpoints = new CopyOnWriteArraySet();
+
+    public void addEndpoint(Endpoint endpoint) {
+        endpoints.add(endpoint);
     }
-    
-    public void removeEndpoint(Endpoint endpoint){
-	endpoints.remove(endpoint);
+
+    public void removeEndpoint(Endpoint endpoint) {
+        endpoints.remove(endpoint);
     }
-    
-    public boolean contains(Endpoint endpoint){
-	return endpoints.contains(endpoint);
+
+    public boolean contains(Endpoint endpoint) {
+        return endpoints.contains(endpoint);
     }
-    
-    public int size(){
-	return endpoints.size();
+
+    public int size() {
+        return endpoints.size();
     }
 
     public Set<Endpoint> getEndpoints() {
         return endpoints;
     }
-    
+
 }

Modified: geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/TransportFactory.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/TransportFactory.java?view=diff&rev=475887&r1=475886&r2=475887
==============================================================================
--- geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/TransportFactory.java
(original)
+++ geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/TransportFactory.java
Thu Nov 16 11:26:10 2006
@@ -19,12 +19,12 @@
 
 import java.io.IOException;
 import java.net.URI;
+import java.util.concurrent.ConcurrentHashMap;
 
 import org.apache.geronimo.gcache.CacheInfoHolder;
 import org.apache.geronimo.gcache.util.FactoryFinder;
 import org.apache.geronimo.gcache.util.IOExceptionSupport;
 
-import edu.emory.mathcs.backport.java.util.concurrent.ConcurrentHashMap;
 
 public abstract class TransportFactory {
     

Modified: geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/discovery/DiscoveryAgentFactory.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/discovery/DiscoveryAgentFactory.java?view=diff&rev=475887&r1=475886&r2=475887
==============================================================================
--- geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/discovery/DiscoveryAgentFactory.java
(original)
+++ geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/discovery/DiscoveryAgentFactory.java
Thu Nov 16 11:26:10 2006
@@ -19,12 +19,11 @@
 
 import java.io.IOException;
 import java.net.URI;
+import java.util.concurrent.ConcurrentHashMap;
 
 import org.apache.geronimo.gcache.util.FactoryFinder;
 import org.apache.geronimo.gcache.CacheInfoHolder;
 import org.apache.geronimo.gcache.util.IOExceptionSupport;
-
-import edu.emory.mathcs.backport.java.util.concurrent.ConcurrentHashMap;
 
 public abstract class DiscoveryAgentFactory {
     static final private FactoryFinder discoveryAgentFinder = new FactoryFinder("META-INF/services/org/apache/geronimo/gcache/transport/discovery/");
   

Modified: geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/discovery/multicast/MulticastDiscoveryAgent.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/discovery/multicast/MulticastDiscoveryAgent.java?view=diff&rev=475887&r1=475886&r2=475887
==============================================================================
--- geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/discovery/multicast/MulticastDiscoveryAgent.java
(original)
+++ geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/transports/discovery/multicast/MulticastDiscoveryAgent.java
Thu Nov 16 11:26:10 2006
@@ -17,31 +17,24 @@
  */
 package org.apache.geronimo.gcache.transports.discovery.multicast;
 
-import java.io.IOException;
-import java.net.DatagramPacket;
-import java.net.InetAddress;
-import java.net.InetSocketAddress;
-import java.net.MulticastSocket;
-import java.net.SocketAddress;
-import java.net.SocketTimeoutException;
-import java.net.URI;
-import java.util.Iterator;
-import java.util.Map;
-
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.apache.geronimo.gcache.command.DiscoveryCommand;
 import org.apache.geronimo.gcache.transports.discovery.DiscoveryAgent;
 import org.apache.geronimo.gcache.transports.discovery.DiscoveryListener;
 
-import edu.emory.mathcs.backport.java.util.concurrent.ConcurrentHashMap;
-import edu.emory.mathcs.backport.java.util.concurrent.Executor;
-import edu.emory.mathcs.backport.java.util.concurrent.LinkedBlockingQueue;
-import edu.emory.mathcs.backport.java.util.concurrent.ThreadFactory;
-import edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor;
-import edu.emory.mathcs.backport.java.util.concurrent.TimeUnit;
-import edu.emory.mathcs.backport.java.util.concurrent.atomic.AtomicBoolean;
-import edu.emory.mathcs.backport.java.util.concurrent.atomic.AtomicLong;
+import java.io.IOException;
+import java.net.*;
+import java.util.Iterator;
+import java.util.Map;
+import java.util.concurrent.atomic.AtomicBoolean;
+import java.util.concurrent.atomic.AtomicLong;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.ThreadFactory;
+import java.util.concurrent.LinkedBlockingQueue;
+import java.util.concurrent.TimeUnit;
+import java.util.concurrent.Executor;
+import java.util.concurrent.ThreadPoolExecutor;
 
 public class MulticastDiscoveryAgent extends DiscoveryAgent implements Runnable {
 

Modified: geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/util/FactoryFinder.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/util/FactoryFinder.java?view=diff&rev=475887&r1=475886&r2=475887
==============================================================================
--- geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/util/FactoryFinder.java
(original)
+++ geronimo/sandbox/gcache/common/src/main/java/org/apache/geronimo/gcache/util/FactoryFinder.java
Thu Nov 16 11:26:10 2006
@@ -21,8 +21,8 @@
 import java.io.IOException;
 import java.io.InputStream;
 import java.util.Properties;
+import java.util.concurrent.ConcurrentHashMap;
 
-import edu.emory.mathcs.backport.java.util.concurrent.ConcurrentHashMap;
 
 public class FactoryFinder {
     private final String path;

Added: geronimo/sandbox/gcache/common/src/test/resources/log4j.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gcache/common/src/test/resources/log4j.xml?view=auto&rev=475887
==============================================================================
--- geronimo/sandbox/gcache/common/src/test/resources/log4j.xml (added)
+++ geronimo/sandbox/gcache/common/src/test/resources/log4j.xml Thu Nov 16 11:26:10 2006
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<log4j:configuration xmlns:log4j='http://jakarta.apache.org/log4j/'>
+
+	<appender name="ConsoleAppender" class="org.apache.log4j.ConsoleAppender">
+		<layout class="org.apache.log4j.PatternLayout">
+			<!--param name="ConversionPattern" value="[%p] %c %m%n"/-->
+			<param name="ConversionPattern" value="[%p] [%c{1}] %m%n"/>
+		</layout>
+	</appender>
+
+   <category name="net.sf.ehcache.config.ConfigurationFactory">
+      <priority value="ERROR"/>
+   </category>
+
+	<root>
+		<priority value="debug"/>
+		<appender-ref ref="ConsoleAppender"/>
+	</root>
+
+</log4j:configuration>
\ No newline at end of file

Propchange: geronimo/sandbox/gcache/common/src/test/resources/log4j.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gcache/common/src/test/resources/log4j.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/sandbox/gcache/common/src/test/resources/log4j.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml



Mime
View raw message