This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import io.Source | |
object SpellChecker { | |
val NWORDS = train(words(Source.fromFile("/tmp/big.txt", "ISO-8859-1").mkString)) | |
val alphabet = ('a' to 'z').toList | |
def words(text: String):Iterator[String] = """[a-z]+""".r.findAllIn(text.toLowerCase) | |
def train(features: Iterator[String]):Map[String,Int] = { | |
val empty = Map[String,Int]().withDefaultValue(1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/java/voldemort/server/VoldemortServer.java b/src/java/voldemort/server/VoldemortServer.java | |
index f69cd5e..302c5de 100644 | |
--- a/src/java/voldemort/server/VoldemortServer.java | |
+++ b/src/java/voldemort/server/VoldemortServer.java | |
@@ -62,8 +62,7 @@ public class VoldemortServer extends AbstractService { | |
private static final Logger logger = Logger.getLogger(VoldemortServer.class.getName()); | |
public static final long DEFAULT_PUSHER_POLL_MS = 60 * 1000; | |
- | |
- private final static int ASYNC_REQUEST_THREADS = 8; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl -w | |
use strict; | |
use warnings; | |
use Test::More qw( no_plan ); | |
BEGIN { | |
use File::Basename; | |
use File::Spec; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl -w | |
package Foo; | |
use strict; | |
sub new { | |
my $class = shift; | |
my $foo = shift; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/java/voldemort/cluster/failuredetector/AbstractFailureDetector.java b/src/java/voldemort/cluster/failuredetector/Ab | |
index 146cdba..2ad9c3c 100644 | |
--- a/src/java/voldemort/cluster/failuredetector/AbstractFailureDetector.java | |
+++ b/src/java/voldemort/cluster/failuredetector/AbstractFailureDetector.java | |
@@ -216,8 +216,8 @@ public abstract class AbstractFailureDetector implements FailureDetector { | |
if(nodeStatus == null) { | |
logger.warn("creating new node status for node " + node + " for failure detector."); | |
- nodeStatusMap.put(node, createNodeStatus(node, failureDetectorConfig.getTime() | |
- .getMilliseconds())); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-Xms18g | |
-Xmx18g | |
-XX:NewSize=2048m | |
-XX:MaxNewSize=2048m | |
-XX:+UseConcMarkSweepGC | |
-XX:+UseParNewGC | |
-XX:CMSInitiatingOccupancyFraction=70 | |
-XX:SurvivorRatio=2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/java/voldemort/client/AbstractStoreClientFactory.java b/src/java/voldemort/client/AbstractStoreClientFactory.java | |
index 2991553..b7d134c 100644 | |
--- a/src/java/voldemort/client/AbstractStoreClientFactory.java | |
+++ b/src/java/voldemort/client/AbstractStoreClientFactory.java | |
@@ -19,6 +19,7 @@ package voldemort.client; | |
import java.io.StringReader; | |
import java.net.URI; | |
import java.net.URISyntaxException; | |
+import java.util.Collection; | |
import java.util.List; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Release 0.80 on 2/18/2010 | |
Changes made since 0.70.1: | |
* IMPORTANT: backwards compatibility between the client and server has | |
changed. A backwards incompatibility in the wire protocol was found | |
between releases 0.60 to 0.70.1 and releases prior to 0.60. We chose | |
to make 0.80 compatible with 0.57.1 and earlier versions, while | |
introducing an incompatibility with 0.60-0.70.1. What this means is | |
that if you're presently running 0.60 and higher, you would need to |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/java/voldemort/store/routed/RoutedStore.java b/src/java/voldemort/store/routed/Routed | |
index b4857b3..162d240 100644 | |
--- a/src/java/voldemort/store/routed/RoutedStore.java | |
+++ b/src/java/voldemort/store/routed/RoutedStore.java | |
@@ -769,7 +769,8 @@ public class RoutedStore implements Store<ByteArray, byte[]> { | |
// Okay looks like it worked, increment the version for the caller | |
VectorClock versionedClock = (VectorClock) versioned.getVersion(); | |
- versionedClock.incrementVersion(master.getId(), time.getMilliseconds()); | |
+ VectorClock incrementedClock = versionedClock.incremented(master.getId(), time.getMillisecond |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
iff --git a/src/java/voldemort/client/ClientConfig.java b/src/java/voldemort/client/ClientConfig.java | |
index d0025ff..5459f1b 100644 | |
--- a/src/java/voldemort/client/ClientConfig.java | |
+++ b/src/java/voldemort/client/ClientConfig.java | |
@@ -58,7 +58,7 @@ public class ClientConfig { | |
private volatile long failureDetectorThresholdInterval = FailureDetectorConfig.DEFAULT_THRESHOLD_INTERVAL; | |
private volatile long failureDetectorAsyncRecoveryInterval = FailureDetectorConfig.DEFAULT_ASYNC_RECOVERY_INTERVAL; | |
private volatile List<String> failureDetectorCatastrophicErrorTypes = FailureDetectorConfig.DEFAULT_CATASTROPHIC_ERROR_TYPES; | |
- private long failureDetectorRequestLengthThreshold = FailureDetectorConfig.DEFAULT_REQUEST_LENGTH_THRESHOLD; | |
+ private long failureDetectorRequestLengthThreshold = socketTimeoutMs; |