cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject svn commit: r788892 - in /incubator/cassandra/trunk: ./ src/java/org/apache/cassandra/config/ src/java/org/apache/cassandra/net/ src/java/org/apache/cassandra/net/http/ src/java/org/apache/cassandra/service/
Date Fri, 26 Jun 2009 22:29:13 GMT
Author: jbellis
Date: Fri Jun 26 22:29:12 2009
New Revision: 788892

URL: http://svn.apache.org/viewvc?rev=788892&view=rev
Log:
r/m http server (use cli, nodeprobe, jmx as necessary instead).
patch by jbellis and Eric Evans for CASSANDRA-211

Removed:
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/ColumnFamilyFormatter.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HTMLFormatter.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HttpConnection.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HttpConnectionHandler.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HttpHeaderParser.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HttpParsingException.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HttpProtocolConstants.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HttpRequest.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HttpRequestHandler.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HttpResponse.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HttpStartLineParser.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/http/HttpWriteResponse.java
Modified:
    incubator/cassandra/trunk/CHANGES.txt
    incubator/cassandra/trunk/src/java/org/apache/cassandra/config/DatabaseDescriptor.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/IMessagingService.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/net/MessagingService.java
    incubator/cassandra/trunk/src/java/org/apache/cassandra/service/StorageService.java

Modified: incubator/cassandra/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/incubator/cassandra/trunk/CHANGES.txt?rev=788892&r1=788891&r2=788892&view=diff
==============================================================================
--- incubator/cassandra/trunk/CHANGES.txt (original)
+++ incubator/cassandra/trunk/CHANGES.txt Fri Jun 26 22:29:12 2009
@@ -2,6 +2,8 @@
  * Change signature of get_slice and get_slice_super to require a starting
    column instead of an offset.  (This allows use of indexes.)  Added
    "ascending" flag to allow reasonably-efficient reverse scans as well.
+ * Removed the web interface. Node information can now be obtained by 
+   using the newly introduced nodeprobe utility.
 
 
 0.3.0

Modified: incubator/cassandra/trunk/src/java/org/apache/cassandra/config/DatabaseDescriptor.java
URL: http://svn.apache.org/viewvc/incubator/cassandra/trunk/src/java/org/apache/cassandra/config/DatabaseDescriptor.java?rev=788892&r1=788891&r2=788892&view=diff
==============================================================================
--- incubator/cassandra/trunk/src/java/org/apache/cassandra/config/DatabaseDescriptor.java
(original)
+++ incubator/cassandra/trunk/src/java/org/apache/cassandra/config/DatabaseDescriptor.java
Fri Jun 26 22:29:12 2009
@@ -42,7 +42,6 @@
     public static final String ophf_ = "OPHF";
     private static int storagePort_ = 7000;
     private static int controlPort_ = 7001;
-    private static int httpPort_ = 7002;
     private static int thriftPort_ = 9160;
     private static String listenAddress_; // leave null so we can fall through to getLocalHost
     private static String clusterName_ = "Test";
@@ -195,11 +194,6 @@
             if ( port != null )
                 controlPort_ = Integer.parseInt(port);
 
-            /* HTTP port for HTTP messages */
-            port = xmlUtils.getNodeValue("/Storage/HttpPort");
-            if ( port != null )
-                httpPort_ = Integer.parseInt(port);
-
             /* get the thrift port from conf file */
             port = xmlUtils.getNodeValue("/Storage/ThriftPort");
             if (port != null)
@@ -640,11 +634,6 @@
         return controlPort_;
     }
 
-    public static int getHttpPort()
-    {
-        return httpPort_;
-    }
-
     public static int getThriftPort()
     {
         return thriftPort_;

Modified: incubator/cassandra/trunk/src/java/org/apache/cassandra/net/IMessagingService.java
URL: http://svn.apache.org/viewvc/incubator/cassandra/trunk/src/java/org/apache/cassandra/net/IMessagingService.java?rev=788892&r1=788891&r2=788892&view=diff
==============================================================================
--- incubator/cassandra/trunk/src/java/org/apache/cassandra/net/IMessagingService.java (original)
+++ incubator/cassandra/trunk/src/java/org/apache/cassandra/net/IMessagingService.java Fri
Jun 26 22:29:12 2009
@@ -60,7 +60,7 @@
      * @param ep EndPoint whose port to listen on.
      * @param isHttp specify if the port is an Http port.     
      */
-    public void listen(EndPoint ep, boolean isHttp) throws IOException;
+    public void listen(EndPoint ep) throws IOException;
     
     /**
      * Listen on the specified port.

Modified: incubator/cassandra/trunk/src/java/org/apache/cassandra/net/MessagingService.java
URL: http://svn.apache.org/viewvc/incubator/cassandra/trunk/src/java/org/apache/cassandra/net/MessagingService.java?rev=788892&r1=788891&r2=788892&view=diff
==============================================================================
--- incubator/cassandra/trunk/src/java/org/apache/cassandra/net/MessagingService.java (original)
+++ incubator/cassandra/trunk/src/java/org/apache/cassandra/net/MessagingService.java Fri
Jun 26 22:29:12 2009
@@ -20,7 +20,6 @@
 
 import org.apache.cassandra.concurrent.*;
 import org.apache.cassandra.config.DatabaseDescriptor;
-import org.apache.cassandra.net.http.HttpConnectionHandler;
 import org.apache.cassandra.net.io.SerializerType;
 import org.apache.cassandra.utils.*;
 import org.apache.log4j.Logger;
@@ -232,23 +231,15 @@
         return result;
     }
     
-    public void listen(EndPoint localEp, boolean isHttp) throws IOException
+    public void listen(EndPoint localEp) throws IOException
     {        
         ServerSocketChannel serverChannel = ServerSocketChannel.open();
         ServerSocket ss = serverChannel.socket();            
         ss.bind(localEp.getInetAddress());
         serverChannel.configureBlocking(false);
         
-        SelectionKeyHandler handler = null;
-        if ( isHttp )
-        {                
-            handler = new HttpConnectionHandler();
-        }
-        else
-        {
-            handler = new TcpConnectionHandler(localEp);
-        }
-        
+        SelectionKeyHandler handler = new TcpConnectionHandler(localEp);
+
         SelectionKey key = SelectorManager.getSelectorManager().register(serverChannel, handler,
SelectionKey.OP_ACCEPT);          
         endPoints_.add(localEp);            
         listenSockets_.put(localEp, key);             

Modified: incubator/cassandra/trunk/src/java/org/apache/cassandra/service/StorageService.java
URL: http://svn.apache.org/viewvc/incubator/cassandra/trunk/src/java/org/apache/cassandra/service/StorageService.java?rev=788892&r1=788891&r2=788892&view=diff
==============================================================================
--- incubator/cassandra/trunk/src/java/org/apache/cassandra/service/StorageService.java (original)
+++ incubator/cassandra/trunk/src/java/org/apache/cassandra/service/StorageService.java Fri
Jun 26 22:29:12 2009
@@ -38,7 +38,6 @@
 import org.apache.cassandra.gms.*;
 import org.apache.cassandra.locator.*;
 import org.apache.cassandra.net.*;
-import org.apache.cassandra.net.http.HttpConnection;
 import org.apache.cassandra.net.io.StreamContextManager;
 import org.apache.cassandra.tools.MembershipCleanerVerbHandler;
 import org.apache.cassandra.utils.FileUtils;
@@ -105,11 +104,6 @@
         return udpAddr_;
     }
 
-    public static String getHostUrl()
-    {
-        return "http://" + tcpAddr_.getHost() + ":" + DatabaseDescriptor.getHttpPort();
-    }
-
     public static IPartitioner getPartitioner() {
         return partitioner_;
     }
@@ -242,8 +236,6 @@
         StageManager.registerStage(StorageService.mutationStage_, new MultiThreadedStage(StorageService.mutationStage_,
threadCount));
         StageManager.registerStage(StorageService.readStage_, new MultiThreadedStage(StorageService.readStage_,
2*threadCount));        
         StageManager.registerStage(StorageService.mrStage_, new MultiThreadedStage(StorageService.mrStage_,
threadCount));
-        /* Stage for handling the HTTP messages. */
-        StageManager.registerStage(HttpConnection.httpStage_, new SingleThreadedStage("HTTP-REQUEST"));
 
         if ( DatabaseDescriptor.isRackAware() )
             nodePicker_ = new RackAwareStrategy(tokenMetadata_, partitioner_, DatabaseDescriptor.getReplicationFactor(),
DatabaseDescriptor.getStoragePort());
@@ -275,11 +267,9 @@
         tcpAddr_ = new EndPoint(DatabaseDescriptor.getStoragePort());
         udpAddr_ = new EndPoint(DatabaseDescriptor.getControlPort());
         /* Listen for application messages */
-        MessagingService.getMessagingInstance().listen(tcpAddr_, false);
+        MessagingService.getMessagingInstance().listen(tcpAddr_);
         /* Listen for control messages */
         MessagingService.getMessagingInstance().listenUDP(udpAddr_);
-        /* Listen for HTTP messages */
-        MessagingService.getMessagingInstance().listen( new EndPoint(DatabaseDescriptor.getHttpPort()
), true );
 
         SelectorManager.getSelectorManager().start();
         SelectorManager.getUdpSelectorManager().start();



Mime
View raw message