Skip to content
Snippets Groups Projects
Commit 2fabc1d2 authored by Adnan Ahmad's avatar Adnan Ahmad
Browse files

moved zookeeper to its own binding

parent 2ecbda3c
No related branches found
No related tags found
No related merge requests found
......@@ -39,17 +39,6 @@ LICENSE file.
<artifactId>core</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.apache.zookeeper</groupId>
<artifactId>zookeeper</artifactId>
<version>3.4.11</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.json/json -->
<dependency>
<groupId>org.json</groupId>
<artifactId>json</artifactId>
<version>20160810</version>
</dependency>
</dependencies>
</project>
......@@ -205,6 +205,7 @@ LICENSE file.
<module>tablestore</module>
<!--<module>voldemort</module>-->
<module>voltdb</module>
<module>zookeeper</module>
</modules>
<build>
......
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<artifactId>root</artifactId>
<groupId>site.ycsb</groupId>
<version>0.18.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>zookeeper</artifactId>
<name>Zookeeper Binding</name>
<dependencies>
<dependency>
<groupId>site.ycsb</groupId>
<artifactId>core</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.apache.zookeeper</groupId>
<artifactId>zookeeper</artifactId>
<version>3.4.11</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.json/json -->
<dependency>
<groupId>org.json</groupId>
<artifactId>json</artifactId>
<version>20160810</version>
</dependency>
</dependencies>
</project>
\ No newline at end of file
......@@ -7,9 +7,12 @@ import org.apache.zookeeper.ZooKeeper;
import java.io.IOException;
import java.util.concurrent.CountDownLatch;
/**
* Used for connecting to Zookeeper.
*/
public class ZKConnection {
private ZooKeeper zoo;
CountDownLatch connectionLatch = new CountDownLatch(1);
private CountDownLatch connectionLatch = new CountDownLatch(1);
// ...
......
......@@ -10,13 +10,15 @@ import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.util.HashMap;
import java.util.Map;
import java.util.Properties;
import java.util.Set;
import org.json.JSONObject;
import java.util.Vector;
/**
* A client that can be used by YCSB to work with Zookeeper.
*/
public class ZookeeperClient extends DB {
private static ZooKeeper zooKeeper;
......@@ -37,7 +39,8 @@ public class ZookeeperClient extends DB {
}
@Override
public Status scan(String table, String startkey, int recordcount, Set<String> fields, Vector<HashMap<String, ByteIterator>> result) {
public Status scan(String table, String startkey,
int recordcount, Set<String> fields, Vector<HashMap<String, ByteIterator>> result) {
return null;
}
......
/**
* Zookeeper integration with YCSB.
*/
package site.ycsb.db;
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment