cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject svn commit: r925394 - /cassandra/trunk/contrib/py_stress/stress.py
Date Fri, 19 Mar 2010 19:33:02 GMT
Author: jbellis
Date: Fri Mar 19 19:33:01 2010
New Revision: 925394

URL: http://svn.apache.org/viewvc?rev=925394&view=rev
Log:
allow more columns per row in stress test. patch by Brandon Williams; reviewed by jbellis
for CASSANDRA-908

Modified:
    cassandra/trunk/contrib/py_stress/stress.py

Modified: cassandra/trunk/contrib/py_stress/stress.py
URL: http://svn.apache.org/viewvc/cassandra/trunk/contrib/py_stress/stress.py?rev=925394&r1=925393&r2=925394&view=diff
==============================================================================
--- cassandra/trunk/contrib/py_stress/stress.py (original)
+++ cassandra/trunk/contrib/py_stress/stress.py Fri Mar 19 19:33:01 2010
@@ -160,10 +160,10 @@ class Operation(Thread):
 class Inserter(Operation):
     def run(self):
         data = md5(str(get_ident())).hexdigest()
-        columns = [Column(chr(ord('A') + j), data, 0) for j in xrange(columns_per_key)]
+        columns = [Column('C' + str(j), data, 0) for j in xrange(columns_per_key)]
         fmt = '%0' + str(len(str(total_keys))) + 'd'
         if 'super' == options.cftype:
-            supers = [SuperColumn(chr(ord('A') + j), columns) for j in xrange(supers_per_key)]
+            supers = [SuperColumn('S' + str(j), columns) for j in xrange(supers_per_key)]
         for i in self.range:
             key = fmt % i
             if 'super' == options.cftype:
@@ -192,7 +192,7 @@ class Reader(Operation):
             for i in xrange(keys_per_thread):
                 key = key_generator()
                 for j in xrange(supers_per_key):
-                    parent = ColumnParent('Super1', chr(ord('A') + j))
+                    parent = ColumnParent('Super1', 'S' + str(j))
                     start = time.time()
                     try:
                         r = self.cclient.get_slice('Keyspace1', key, parent, p, ConsistencyLevel.ONE)



Mime
View raw message