cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tylerho...@apache.org
Subject [2/2] git commit: Merge branch 'cassandra-2.1' into trunk
Date Tue, 07 Oct 2014 23:07:55 GMT
Merge branch 'cassandra-2.1' into trunk

Conflicts:
	src/java/org/apache/cassandra/thrift/CassandraServer.java


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/5a249f26
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/5a249f26
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/5a249f26

Branch: refs/heads/trunk
Commit: 5a249f26cc2a2792b0a0aae3cc3775bc92999966
Parents: 2e8ba03 24c181f
Author: Tyler Hobbs <tyler@datastax.com>
Authored: Tue Oct 7 18:07:36 2014 -0500
Committer: Tyler Hobbs <tyler@datastax.com>
Committed: Tue Oct 7 18:07:36 2014 -0500

----------------------------------------------------------------------
 CHANGES.txt                                     |  1 +
 .../org/apache/cassandra/cql3/QueryHandler.java |  2 +-
 .../apache/cassandra/cql3/QueryProcessor.java   | 70 ++++++++++++++------
 .../cassandra/thrift/CassandraServer.java       |  9 +--
 4 files changed, 57 insertions(+), 25 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/5a249f26/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index 6ded509,b6299c7..707fab7
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -1,35 -1,5 +1,36 @@@
 +3.0
 + * Support for aggregation functions (CASSANDRA-4914)
 + * Improve query to read paxos table on propose (CASSANDRA-7929)
 + * Remove cassandra-cli (CASSANDRA-7920)
 + * Optimize java source-based UDF invocation (CASSANDRA-7924)
 + * Accept dollar quoted strings in CQL (CASSANDRA-7769)
 + * Make assassinate a first class command (CASSANDRA-7935)
 + * Support IN clause on any clustering column (CASSANDRA-4762)
 + * Improve compaction logging (CASSANDRA-7818)
 + * Remove YamlFileNetworkTopologySnitch (CASSANDRA-7917)
 + * Support Java source code for user-defined functions (CASSANDRA-7562)
 + * Require arg types to disambiguate UDF drops (CASSANDRA-7812)
 + * Do anticompaction in groups (CASSANDRA-6851)
 + * Verify that UDF class methods are static (CASSANDRA-7781)
 + * Support pure user-defined functions (CASSANDRA-7395, 7740)
 + * Permit configurable timestamps with cassandra-stress (CASSANDRA-7416)
 + * Move sstable RandomAccessReader to nio2, which allows using the
 +   FILE_SHARE_DELETE flag on Windows (CASSANDRA-4050)
 + * Remove CQL2 (CASSANDRA-5918)
 + * Add Thrift get_multi_slice call (CASSANDRA-6757)
 + * Optimize fetching multiple cells by name (CASSANDRA-6933)
 + * Allow compilation in java 8 (CASSANDRA-7028)
 + * Make incremental repair default (CASSANDRA-7250)
 + * Enable code coverage thru JaCoCo (CASSANDRA-7226)
 + * Switch external naming of 'column families' to 'tables' (CASSANDRA-4369) 
 + * Shorten SSTable path (CASSANDRA-6962)
 + * Use unsafe mutations for most unit tests (CASSANDRA-6969)
 + * Fix race condition during calculation of pending ranges (CASSANDRA-7390)
 + * Fail on very large batch sizes (CASSANDRA-8011)
 +
 +
  2.1.1
+  * Avoid re-parsing already prepared statements (CASSANDRA-7923)
   * Fix some Thrift slice deletions and updates of COMPACT STORAGE
     tables with some clustering columns omitted (CASSANDRA-7990)
   * Fix filtering for CONTAINS on sets (CASSANDRA-8033)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/5a249f26/src/java/org/apache/cassandra/cql3/QueryProcessor.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/5a249f26/src/java/org/apache/cassandra/thrift/CassandraServer.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/thrift/CassandraServer.java
index 713fd8f,2e76ee4..795dabf
--- a/src/java/org/apache/cassandra/thrift/CassandraServer.java
+++ b/src/java/org/apache/cassandra/thrift/CassandraServer.java
@@@ -44,7 -45,10 +44,8 @@@ import org.apache.cassandra.config.CFMe
  import org.apache.cassandra.config.DatabaseDescriptor;
  import org.apache.cassandra.config.KSMetaData;
  import org.apache.cassandra.config.Schema;
 -import org.apache.cassandra.cql.CQLStatement;
 -import org.apache.cassandra.cql.QueryProcessor;
  import org.apache.cassandra.cql3.QueryOptions;
+ import org.apache.cassandra.cql3.statements.ParsedStatement;
  import org.apache.cassandra.db.*;
  import org.apache.cassandra.db.composites.*;
  import org.apache.cassandra.db.context.CounterContext;
@@@ -1969,23 -2024,8 +1970,23 @@@ public class CassandraServer implement
  
          try
          {
 -            cState.validateLogin();
 -            return cState.getCQLQueryHandler().prepare(queryString, cState.getQueryState()).toThriftPreparedResult();
 +            ThriftClientState cState = state();
-             org.apache.cassandra.cql3.CQLStatement statement = cState.getCQLQueryHandler().getPreparedForThrift(itemId);
++            ParsedStatement.Prepared prepared = cState.getCQLQueryHandler().getPreparedForThrift(itemId);
 +
-             if (statement == null)
++            if (prepared == null)
 +                throw new InvalidRequestException(String.format("Prepared query with ID
%d not found" +
 +                                                                " (either the query was
not prepared on this host (maybe the host has been restarted?)" +
 +                                                                " or you have prepared too
many queries and it has been evicted from the internal cache)",
 +                                                                itemId));
-             logger.trace("Retrieved prepared statement #{} with {} bind markers", itemId,
statement.getBoundTerms());
++            logger.trace("Retrieved prepared statement #{} with {} bind markers", itemId,
prepared.statement.getBoundTerms());
 +
-             return cState.getCQLQueryHandler().processPrepared(statement,
++            return cState.getCQLQueryHandler().processPrepared(prepared.statement,
 +                                                               cState.getQueryState(),
 +                                                               QueryOptions.fromProtocolV2(ThriftConversion.fromThrift(cLevel),
bindVariables)).toThriftResult();
 +        }
 +        catch (RequestExecutionException e)
 +        {
 +            throw ThriftConversion.rethrow(e);
          }
          catch (RequestValidationException e)
          {


Mime
View raw message