diff --git a/BUILD b/BUILD index 00952033fa200ed705706e585623c9cf763b9190..e520c2d9ce6b4919d30cad8a35c7f61991b38833 100644 --- a/BUILD +++ b/BUILD @@ -4,6 +4,13 @@ To build YCSB, run: mvn clean package +# Running YCSB + +Once `mvn clean package` succeeds, you can run `ycsb` command: + + ./bin/ycsb load basic workloads/workloada + ./bin/ycsb run basic workloads/workloada + # Oracle NoSQL Database Oracle NoSQL Database binding doesn't get built by default because there is no diff --git a/bin/ycsb b/bin/ycsb index 6771c8bd42f0e41bd3ff96787f232fd06cc78e96..9c521c22ae5895880eb20005ce131728b2e4e7c9 100755 --- a/bin/ycsb +++ b/bin/ycsb @@ -4,6 +4,7 @@ import os import sys import subprocess +BASE_URL = "https://github.com/brianfrankcooper/YCSB/tree/master/" COMMANDS = { "load" : { "command" : "-load", @@ -47,7 +48,7 @@ def usage(): print "\nDatabases:" for db in sorted(DATABASES.keys()): - print " %s" % db + print " {0:13} {1}".format(db, BASE_URL + db.split("-")[0]) print """\nWorkload Files: There are various predefined workloads under workloads/ directory. @@ -66,8 +67,9 @@ def find_jars(dir, database): jars.append(dirpath) for filename in filenames: if filename.endswith(".jar") and \ - filename.startswith("core") or \ - filename.startswith(database.split("-")[0]): + (filename.startswith("core") or \ + filename.startswith(database.split("-")[0]) or \ + not "binding" in filename): jars.append(os.path.join(dirpath, filename)) return jars @@ -96,4 +98,5 @@ options = sys.argv[4:] ycsb_command = ["java", "-cp", ":".join(find_jars(ycsb_home, database)), \ "com.yahoo.ycsb.Client", command, "-db", db_classname, \ "-P", workload] + options +print " ".join(ycsb_command) subprocess.call(ycsb_command)