You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by db...@apache.org on 2016/08/31 02:42:46 UTC
[1/3] cassandra git commit: Fixing double division and rounding.
Repository: cassandra
Updated Branches:
refs/heads/trunk 71640f1e3 -> c5f128021
Fixing double division and rounding.
Patch by Per Otterstrom; reviewed by dbrosius for CASSANDRA-11752
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/ac24b88e
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/ac24b88e
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/ac24b88e
Branch: refs/heads/trunk
Commit: ac24b88e56275583b71bd6a1feba443e05e88c39
Parents: 6eff082
Author: Per Otterstrom <pe...@ericsson.com>
Authored: Tue Aug 30 22:33:49 2016 -0400
Committer: Dave Brosius <db...@mebigfatguy.com>
Committed: Tue Aug 30 22:33:49 2016 -0400
----------------------------------------------------------------------
.../metrics/DecayingEstimatedHistogramReservoir.java | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/ac24b88e/src/java/org/apache/cassandra/metrics/DecayingEstimatedHistogramReservoir.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/metrics/DecayingEstimatedHistogramReservoir.java b/src/java/org/apache/cassandra/metrics/DecayingEstimatedHistogramReservoir.java
index 14a4366..2458164 100644
--- a/src/java/org/apache/cassandra/metrics/DecayingEstimatedHistogramReservoir.java
+++ b/src/java/org/apache/cassandra/metrics/DecayingEstimatedHistogramReservoir.java
@@ -179,7 +179,7 @@ public class DecayingEstimatedHistogramReservoir implements Reservoir
try
{
- decayingBuckets.getAndAdd(index, forwardDecayWeight(now));
+ decayingBuckets.getAndAdd(index, Math.round(forwardDecayWeight(now)));
}
finally
{
@@ -189,9 +189,9 @@ public class DecayingEstimatedHistogramReservoir implements Reservoir
buckets.getAndIncrement(index);
}
- private long forwardDecayWeight(long now)
+ private double forwardDecayWeight(long now)
{
- return Math.round(Math.exp(((now - decayLandmark) / 1000L) / MEAN_LIFETIME_IN_S));
+ return Math.exp(((now - decayLandmark) / 1000L) / MEAN_LIFETIME_IN_S);
}
/**
@@ -270,7 +270,7 @@ public class DecayingEstimatedHistogramReservoir implements Reservoir
try
{
- final long rescaleFactor = forwardDecayWeight(now);
+ final double rescaleFactor = forwardDecayWeight(now);
decayLandmark = now;
final int bucketCount = decayingBuckets.length();
[2/3] cassandra git commit: Merge branch 'cassandra-2.2' into
cassandra-3.0
Posted by db...@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/4133c74a
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/4133c74a
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/4133c74a
Branch: refs/heads/trunk
Commit: 4133c74a9cde484ec081d37b9423d0d4eacc333a
Parents: 3483418 ac24b88
Author: Dave Brosius <db...@mebigfatguy.com>
Authored: Tue Aug 30 22:37:54 2016 -0400
Committer: Dave Brosius <db...@mebigfatguy.com>
Committed: Tue Aug 30 22:37:54 2016 -0400
----------------------------------------------------------------------
.../metrics/DecayingEstimatedHistogramReservoir.java | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
[3/3] cassandra git commit: Merge branch 'cassandra-3.0' into trunk
Posted by db...@apache.org.
Merge branch 'cassandra-3.0' into trunk
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/c5f12802
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/c5f12802
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/c5f12802
Branch: refs/heads/trunk
Commit: c5f128021617d67bcb1279e95df6c4be2dde90c2
Parents: 71640f1 4133c74
Author: Dave Brosius <db...@mebigfatguy.com>
Authored: Tue Aug 30 22:42:17 2016 -0400
Committer: Dave Brosius <db...@mebigfatguy.com>
Committed: Tue Aug 30 22:42:17 2016 -0400
----------------------------------------------------------------------
----------------------------------------------------------------------