You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by al...@apache.org on 2015/11/12 19:06:49 UTC
[1/3] cassandra git commit: Add nodetool command to refresh
system.size_estimates
Repository: cassandra
Updated Branches:
refs/heads/cassandra-3.0 b54836b12 -> 9f056a917
Add nodetool command to refresh system.size_estimates
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/ecd66de2
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/ecd66de2
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/ecd66de2
Branch: refs/heads/cassandra-3.0
Commit: ecd66de2bdf2ecb88c4276a4616a76f5ec2921bb
Parents: 9ab1c83
Author: Carl Yeksigian <ca...@apache.org>
Authored: Tue Nov 10 17:22:11 2015 +0000
Committer: Aleksey Yeschenko <al...@apache.org>
Committed: Thu Nov 12 17:53:33 2015 +0000
----------------------------------------------------------------------
CHANGES.txt | 2 ++
.../org/apache/cassandra/service/StorageService.java | 6 ++++++
.../apache/cassandra/service/StorageServiceMBean.java | 5 +++++
src/java/org/apache/cassandra/tools/NodeProbe.java | 12 ++++++++++++
src/java/org/apache/cassandra/tools/NodeTool.java | 11 +++++++++++
5 files changed, 36 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/ecd66de2/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index d0c0af9..2eeda94 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
2.1.12
+ * Add a nodetool command to refresh size_estimates (CASSANDRA-9579)
* Shutdown compaction in drain to prevent leak (CASSANDRA-10079)
* Invalidate cache after stream receive task is completed (CASSANDRA-10341)
* Reject counter writes in CQLSSTableWriter (CASSANDRA-10258)
@@ -33,6 +34,7 @@
* Mark nodes as dead even if they've already left (CASSANDRA-10205)
* Update internal python driver used by cqlsh (CASSANDRA-10161, CASSANDRA-10507)
+
2.1.10
* Bulk Loader API could not tolerate even node failure (CASSANDRA-10347)
* Avoid misleading pushed notifications when multiple nodes
http://git-wip-us.apache.org/repos/asf/cassandra/blob/ecd66de2/src/java/org/apache/cassandra/service/StorageService.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/service/StorageService.java b/src/java/org/apache/cassandra/service/StorageService.java
index 93b1b97..665ce3a 100644
--- a/src/java/org/apache/cassandra/service/StorageService.java
+++ b/src/java/org/apache/cassandra/service/StorageService.java
@@ -83,6 +83,7 @@ import org.apache.cassandra.db.MutationVerbHandler;
import org.apache.cassandra.db.ReadRepairVerbHandler;
import org.apache.cassandra.db.ReadVerbHandler;
import org.apache.cassandra.db.SchemaCheckVerbHandler;
+import org.apache.cassandra.db.SizeEstimatesRecorder;
import org.apache.cassandra.db.SnapshotDetailsTabularData;
import org.apache.cassandra.db.SystemKeyspace;
import org.apache.cassandra.db.TruncateVerbHandler;
@@ -2604,6 +2605,11 @@ public class StorageService extends NotificationBroadcasterSupport implements IE
return total;
}
+ public void refreshSizeEstimates() throws ExecutionException
+ {
+ FBUtilities.waitOnFuture(ScheduledExecutors.optionalTasks.submit(SizeEstimatesRecorder.instance));
+ }
+
/**
* @param allowIndexes Allow index CF names to be passed in
* @param autoAddIndexes Automatically add secondary indexes if a CF has them
http://git-wip-us.apache.org/repos/asf/cassandra/blob/ecd66de2/src/java/org/apache/cassandra/service/StorageServiceMBean.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/service/StorageServiceMBean.java b/src/java/org/apache/cassandra/service/StorageServiceMBean.java
index b8582a3..1351fea 100644
--- a/src/java/org/apache/cassandra/service/StorageServiceMBean.java
+++ b/src/java/org/apache/cassandra/service/StorageServiceMBean.java
@@ -248,6 +248,11 @@ public interface StorageServiceMBean extends NotificationEmitter
public long trueSnapshotsSize();
/**
+ * Forces refresh of values stored in system.size_estimates of all column families.
+ */
+ public void refreshSizeEstimates() throws ExecutionException;
+
+ /**
* Forces major compaction of a single keyspace
*/
public void forceKeyspaceCompaction(String keyspaceName, String... columnFamilies) throws IOException, ExecutionException, InterruptedException;
http://git-wip-us.apache.org/repos/asf/cassandra/blob/ecd66de2/src/java/org/apache/cassandra/tools/NodeProbe.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/tools/NodeProbe.java b/src/java/org/apache/cassandra/tools/NodeProbe.java
index 6f2b6fb..49c493d 100644
--- a/src/java/org/apache/cassandra/tools/NodeProbe.java
+++ b/src/java/org/apache/cassandra/tools/NodeProbe.java
@@ -901,6 +901,18 @@ public class NodeProbe implements AutoCloseable
}
}
+ public void refreshSizeEstimates()
+ {
+ try
+ {
+ ssProxy.refreshSizeEstimates();
+ }
+ catch (ExecutionException e)
+ {
+ throw new RuntimeException("Error while refreshing system.size_estimates", e);
+ }
+ }
+
public void stopNativeTransport()
{
ssProxy.stopNativeTransport();
http://git-wip-us.apache.org/repos/asf/cassandra/blob/ecd66de2/src/java/org/apache/cassandra/tools/NodeTool.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/tools/NodeTool.java b/src/java/org/apache/cassandra/tools/NodeTool.java
index 277f42c..1d4a420 100644
--- a/src/java/org/apache/cassandra/tools/NodeTool.java
+++ b/src/java/org/apache/cassandra/tools/NodeTool.java
@@ -151,6 +151,7 @@ public class NodeTool
ProxyHistograms.class,
Rebuild.class,
Refresh.class,
+ RefreshSizeEstimates.class,
RemoveToken.class,
RemoveNode.class,
Repair.class,
@@ -1807,6 +1808,16 @@ public class NodeTool
}
}
+ @Command(name = "refreshsizeestimates", description = "Refresh system.size_estimates")
+ public static class RefreshSizeEstimates extends NodeToolCmd
+ {
+ @Override
+ public void execute(NodeProbe probe)
+ {
+ probe.refreshSizeEstimates();
+ }
+ }
+
@Deprecated
@Command(name = "removetoken", description = "DEPRECATED (see removenode)", hidden = true)
public static class RemoveToken extends NodeToolCmd
[2/3] cassandra git commit: Merge branch 'cassandra-2.1' into
cassandra-2.2
Posted by al...@apache.org.
Merge branch 'cassandra-2.1' into cassandra-2.2
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/84d44885
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/84d44885
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/84d44885
Branch: refs/heads/cassandra-3.0
Commit: 84d4488537605a86373325f86bbc4cd358921223
Parents: d84b42b ecd66de
Author: Aleksey Yeschenko <al...@apache.org>
Authored: Thu Nov 12 17:58:38 2015 +0000
Committer: Aleksey Yeschenko <al...@apache.org>
Committed: Thu Nov 12 17:58:38 2015 +0000
----------------------------------------------------------------------
CHANGES.txt | 1 +
.../cassandra/service/StorageService.java | 6 ++++
.../cassandra/service/StorageServiceMBean.java | 5 +++
.../org/apache/cassandra/tools/NodeProbe.java | 12 +++++++
.../org/apache/cassandra/tools/NodeTool.java | 3 +-
.../tools/nodetool/RefreshSizeEstimates.java | 33 ++++++++++++++++++++
6 files changed, 59 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/84d44885/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index 2cfcb55,2eeda94..9c834f3
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -1,15 -1,5 +1,16 @@@
-2.1.12
+2.2.4
+ * (Hadoop) fix splits calculation (CASSANDRA-10640)
+ * (Hadoop) ensure that Cluster instances are always closed (CASSANDRA-10058)
+ * (cqlsh) show partial trace if incomplete after max_trace_wait (CASSANDRA-7645)
+ * Use most up-to-date version of schema for system tables (CASSANDRA-10652)
+ * Deprecate memory_allocator in cassandra.yaml (CASSANDRA-10581,10628)
+ * Expose phi values from failure detector via JMX and tweak debug
+ and trace logging (CASSANDRA-9526)
+ * Fix RangeNamesQueryPager (CASSANDRA-10509)
+ * Deprecate Pig support (CASSANDRA-10542)
+ * Reduce contention getting instances of CompositeType (CASSANDRA-10433)
+Merged from 2.1:
+ * Add a nodetool command to refresh size_estimates (CASSANDRA-9579)
* Shutdown compaction in drain to prevent leak (CASSANDRA-10079)
* Invalidate cache after stream receive task is completed (CASSANDRA-10341)
* Reject counter writes in CQLSSTableWriter (CASSANDRA-10258)
http://git-wip-us.apache.org/repos/asf/cassandra/blob/84d44885/src/java/org/apache/cassandra/service/StorageService.java
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/84d44885/src/java/org/apache/cassandra/service/StorageServiceMBean.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/service/StorageServiceMBean.java
index 2c92d43,1351fea..00060ae
--- a/src/java/org/apache/cassandra/service/StorageServiceMBean.java
+++ b/src/java/org/apache/cassandra/service/StorageServiceMBean.java
@@@ -239,9 -248,14 +239,14 @@@ public interface StorageServiceMBean ex
public long trueSnapshotsSize();
/**
+ * Forces refresh of values stored in system.size_estimates of all column families.
+ */
+ public void refreshSizeEstimates() throws ExecutionException;
+
+ /**
* Forces major compaction of a single keyspace
*/
- public void forceKeyspaceCompaction(String keyspaceName, String... columnFamilies) throws IOException, ExecutionException, InterruptedException;
+ public void forceKeyspaceCompaction(boolean splitOutput, String keyspaceName, String... columnFamilies) throws IOException, ExecutionException, InterruptedException;
/**
* Trigger a cleanup of keys on a single keyspace
http://git-wip-us.apache.org/repos/asf/cassandra/blob/84d44885/src/java/org/apache/cassandra/tools/NodeProbe.java
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/84d44885/src/java/org/apache/cassandra/tools/NodeTool.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/tools/NodeTool.java
index 175b325,1d4a420..fcb6ed0
--- a/src/java/org/apache/cassandra/tools/NodeTool.java
+++ b/src/java/org/apache/cassandra/tools/NodeTool.java
@@@ -129,23 -187,14 +129,24 @@@ public class NodeToo
TpStats.class,
TopPartitions.class,
SetLoggingLevel.class,
- GetLoggingLevels.class
+ GetLoggingLevels.class,
- FailureDetectorInfo.class
++ FailureDetectorInfo.class,
++ RefreshSizeEstimates.class
);
- Cli<Runnable> parser = Cli.<Runnable>builder("nodetool")
- .withDescription("Manage your Cassandra cluster")
+ Cli.CliBuilder<Runnable> builder = Cli.builder("nodetool");
+
+ builder.withDescription("Manage your Cassandra cluster")
+ .withDefaultCommand(Help.class)
+ .withCommands(commands);
+
+ // bootstrap commands
+ builder.withGroup("bootstrap")
+ .withDescription("Monitor/manage node's bootstrap process")
.withDefaultCommand(Help.class)
- .withCommands(commands)
- .build();
+ .withCommand(BootstrapResume.class);
+
+ Cli<Runnable> parser = builder.build();
int status = 0;
try
http://git-wip-us.apache.org/repos/asf/cassandra/blob/84d44885/src/java/org/apache/cassandra/tools/nodetool/RefreshSizeEstimates.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/tools/nodetool/RefreshSizeEstimates.java
index 0000000,0000000..870c7b4
new file mode 100644
--- /dev/null
+++ b/src/java/org/apache/cassandra/tools/nodetool/RefreshSizeEstimates.java
@@@ -1,0 -1,0 +1,33 @@@
++/*
++ * Licensed to the Apache Software Foundation (ASF) under one
++ * or more contributor license agreements. See the NOTICE file
++ * distributed with this work for additional information
++ * regarding copyright ownership. The ASF licenses this file
++ * to you under the Apache License, Version 2.0 (the
++ * "License"); you may not use this file except in compliance
++ * with the License. You may obtain a copy of the License at
++ *
++ * http://www.apache.org/licenses/LICENSE-2.0
++ *
++ * Unless required by applicable law or agreed to in writing, software
++ * distributed under the License is distributed on an "AS IS" BASIS,
++ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++ * See the License for the specific language governing permissions and
++ * limitations under the License.
++ */
++
++package org.apache.cassandra.tools.nodetool;
++
++import io.airlift.command.Command;
++import org.apache.cassandra.tools.NodeProbe;
++import org.apache.cassandra.tools.NodeTool;
++
++@Command(name = "refreshsizeestimates", description = "Refresh system.size_estimates")
++public class RefreshSizeEstimates extends NodeTool.NodeToolCmd
++{
++ @Override
++ public void execute(NodeProbe probe)
++ {
++ probe.refreshSizeEstimates();
++ }
++}
[3/3] cassandra git commit: Merge branch 'cassandra-2.2' into
cassandra-3.0
Posted by al...@apache.org.
Merge branch 'cassandra-2.2' into cassandra-3.0
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/9f056a91
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/9f056a91
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/9f056a91
Branch: refs/heads/cassandra-3.0
Commit: 9f056a91754b3516ad1521d32abb075b554e62c3
Parents: b54836b 84d4488
Author: Aleksey Yeschenko <al...@apache.org>
Authored: Thu Nov 12 18:05:54 2015 +0000
Committer: Aleksey Yeschenko <al...@apache.org>
Committed: Thu Nov 12 18:05:54 2015 +0000
----------------------------------------------------------------------
CHANGES.txt | 1 +
.../cassandra/service/StorageService.java | 5 +++
.../cassandra/service/StorageServiceMBean.java | 5 +++
.../org/apache/cassandra/tools/NodeProbe.java | 12 +++++++
.../org/apache/cassandra/tools/NodeTool.java | 3 +-
.../tools/nodetool/RefreshSizeEstimates.java | 33 ++++++++++++++++++++
6 files changed, 58 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/9f056a91/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index 8f1b163,9c834f3..d554323
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -1,51 -1,6 +1,52 @@@
-2.2.4
+3.0.1
+ * Keep the file open in trySkipCache (CASSANDRA-10669)
+ * Updated trigger example (CASSANDRA-10257)
+Merged from 2.2:
* (Hadoop) fix splits calculation (CASSANDRA-10640)
* (Hadoop) ensure that Cluster instances are always closed (CASSANDRA-10058)
+Merged from 2.1:
++ * Add a nodetool command to refresh size_estimates (CASSANDRA-9579)
+ * Invalidate cache after stream receive task is completed (CASSANDRA-10341)
+ * Reject counter writes in CQLSSTableWriter (CASSANDRA-10258)
+ * Remove superfluous COUNTER_MUTATION stage mapping (CASSANDRA-10605)
+
+
+3.0
+ * Fix AssertionError while flushing memtable due to materialized views
+ incorrectly inserting empty rows (CASSANDRA-10614)
+ * Store UDA initcond as CQL literal in the schema table, instead of a blob (CASSANDRA-10650)
+ * Don't use -1 for the position of partition key in schema (CASSANDRA-10491)
+ * Fix distinct queries in mixed version cluster (CASSANDRA-10573)
+ * Skip sstable on clustering in names query (CASSANDRA-10571)
+ * Remove value skipping as it breaks read-repair (CASSANDRA-10655)
+ * Fix bootstrapping with MVs (CASSANDRA-10621)
+ * Make sure EACH_QUORUM reads are using NTS (CASSANDRA-10584)
+ * Fix MV replica filtering for non-NetworkTopologyStrategy (CASSANDRA-10634)
+ * (Hadoop) fix CIF describeSplits() not handling 0 size estimates (CASSANDRA-10600)
+ * Fix reading of legacy sstables (CASSANDRA-10590)
+ * Use CQL type names in schema metadata tables (CASSANDRA-10365)
+ * Guard batchlog replay against integer division by zero (CASSANDRA-9223)
+ * Fix bug when adding a column to thrift with the same name than a primary key (CASSANDRA-10608)
+ * Add client address argument to IAuthenticator::newSaslNegotiator (CASSANDRA-8068)
+ * Fix implementation of LegacyLayout.LegacyBoundComparator (CASSANDRA-10602)
+ * Don't use 'names query' read path for counters (CASSANDRA-10572)
+ * Fix backward compatibility for counters (CASSANDRA-10470)
+ * Remove memory_allocator paramter from cassandra.yaml (CASSANDRA-10581,10628)
+ * Execute the metadata reload task of all registered indexes on CFS::reload (CASSANDRA-10604)
+ * Fix thrift cas operations with defined columns (CASSANDRA-10576)
+ * Fix PartitionUpdate.operationCount()for updates with static column operations (CASSANDRA-10606)
+ * Fix thrift get() queries with defined columns (CASSANDRA-10586)
+ * Fix marking of indexes as built and removed (CASSANDRA-10601)
+ * Skip initialization of non-registered 2i instances, remove Index::getIndexName (CASSANDRA-10595)
+ * Fix batches on multiple tables (CASSANDRA-10554)
+ * Ensure compaction options are validated when updating KeyspaceMetadata (CASSANDRA-10569)
+ * Flatten Iterator Transformation Hierarchy (CASSANDRA-9975)
+ * Remove token generator (CASSANDRA-5261)
+ * RolesCache should not be created for any authenticator that does not requireAuthentication (CASSANDRA-10562)
+ * Fix LogTransaction checking only a single directory for files (CASSANDRA-10421)
+ * Fix handling of range tombstones when reading old format sstables (CASSANDRA-10360)
+ * Aggregate with Initial Condition fails with C* 3.0 (CASSANDRA-10367)
+Merged from 2.2:
* (cqlsh) show partial trace if incomplete after max_trace_wait (CASSANDRA-7645)
* Use most up-to-date version of schema for system tables (CASSANDRA-10652)
* Deprecate memory_allocator in cassandra.yaml (CASSANDRA-10581,10628)
http://git-wip-us.apache.org/repos/asf/cassandra/blob/9f056a91/src/java/org/apache/cassandra/service/StorageService.java
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/9f056a91/src/java/org/apache/cassandra/service/StorageServiceMBean.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/service/StorageServiceMBean.java
index fbc1bf8,00060ae..7f88890
--- a/src/java/org/apache/cassandra/service/StorageServiceMBean.java
+++ b/src/java/org/apache/cassandra/service/StorageServiceMBean.java
@@@ -239,9 -239,14 +239,14 @@@ public interface StorageServiceMBean ex
public long trueSnapshotsSize();
/**
+ * Forces refresh of values stored in system.size_estimates of all column families.
+ */
+ public void refreshSizeEstimates() throws ExecutionException;
+
+ /**
* Forces major compaction of a single keyspace
*/
- public void forceKeyspaceCompaction(boolean splitOutput, String keyspaceName, String... columnFamilies) throws IOException, ExecutionException, InterruptedException;
+ public void forceKeyspaceCompaction(boolean splitOutput, String keyspaceName, String... tableNames) throws IOException, ExecutionException, InterruptedException;
/**
* Trigger a cleanup of keys on a single keyspace
http://git-wip-us.apache.org/repos/asf/cassandra/blob/9f056a91/src/java/org/apache/cassandra/tools/NodeProbe.java
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/9f056a91/src/java/org/apache/cassandra/tools/NodeTool.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/tools/NodeTool.java
index e4bed4c,fcb6ed0..668c075
--- a/src/java/org/apache/cassandra/tools/NodeTool.java
+++ b/src/java/org/apache/cassandra/tools/NodeTool.java
@@@ -131,9 -130,8 +131,10 @@@ public class NodeToo
TopPartitions.class,
SetLoggingLevel.class,
GetLoggingLevels.class,
+ DisableHintsForDC.class,
+ EnableHintsForDC.class,
- FailureDetectorInfo.class
+ FailureDetectorInfo.class,
+ RefreshSizeEstimates.class
);
Cli.CliBuilder<Runnable> builder = Cli.builder("nodetool");