cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cassandra-node.apache-extras....@codespot.com
Subject [cassandra-node] 3 new revisions pushed by christop...@gmail.com on 2012-02-03 17:12 GMT
Date Fri, 03 Feb 2012 17:13:05 GMT
3 new revisions:

Revision: e388831c4050
Author:   Christoph Tavan <dev@tavan.de>
Date:     Thu Jan 12 08:25:08 2012
Log:      Add support for blob (i.e. node Buffer()) inserts
http://code.google.com/a/apache-extras.org/p/cassandra-node/source/detail?r=e388831c4050

Revision: 1f56096b0ea6
Author:   Christoph Tavan <dev@tavan.de>
Date:     Thu Jan 12 09:08:00 2012
Log:      Remove my blob test and make binaryTest use the binary values.  
Also re...
http://code.google.com/a/apache-extras.org/p/cassandra-node/source/detail?r=1f56096b0ea6

Revision: 0d9f2cef25ed
Author:   Christoph Tavan <dev@tavan.de>
Date:     Fri Feb  3 02:40:10 2012
Log:      Switch to helenus-thrift client
http://code.google.com/a/apache-extras.org/p/cassandra-node/source/detail?r=0d9f2cef25ed

==============================================================================
Revision: e388831c4050
Author:   Christoph Tavan <dev@tavan.de>
Date:     Thu Jan 12 08:25:08 2012
Log:      Add support for blob (i.e. node Buffer()) inserts

http://code.google.com/a/apache-extras.org/p/cassandra-node/source/detail?r=e388831c4050

Modified:
  /test/test_driver.js

=======================================
--- /test/test_driver.js	Mon Jan 30 13:54:09 2012
+++ /test/test_driver.js	Thu Jan 12 08:25:08 2012
@@ -766,6 +766,44 @@
    });
  };

+exports.testBlob = function(test, assert) {
+  connect(function(err, con) {
+    if (err) {
+      assert.ok(false);
+      test.finish();
+    } else {
+      assert.ok(true);
+
+      var col = new Buffer('columnName');
+      var val = new Buffer('value');
+      var key = new Buffer('rowKey');
+      var updParms = [
+        col,
+        val,
+        key
+      ];
+      con.execute('UPDATE CfBytes SET ?=? WHERE KEY=?', updParms,  
function(updErr) {
+        if (updErr) {
+          con.close();
+          assert.ok(false);
+          test.finish();
+        } else {
+          con.execute('SELECT ? FROM CfBytes WHERE KEY=?', [col, key],  
function(selErr, rows) {
+            con.close();
+            assert.strictEqual(rows.rowCount(), 1);
+            var row = rows[0];
+            assert.strictEqual(1, row.colCount());
+            // Buffers cannot be compared in their native form, so we have  
to serialize them:
+            assert.strictEqual(col.toString('hex'),  
row.cols[0].name.toString('hex'));
+            assert.strictEqual(val.toString('hex'),  
row.cols[0].value.toString('hex'));
+            test.finish();
+          });
+        }
+      });
+    }
+  });
+};
+
  // this test only works an order-preserving partitioner.
  // it also uses an event-based approach to doing things.
  //exports.ZDISABLED_testMultipleRows = function(test, assert) {

==============================================================================
Revision: 1f56096b0ea6
Author:   Christoph Tavan <dev@tavan.de>
Date:     Thu Jan 12 09:08:00 2012
Log:      Remove my blob test and make binaryTest use the binary values.  
Also remove unneeded bufferToString() function

http://code.google.com/a/apache-extras.org/p/cassandra-node/source/detail?r=1f56096b0ea6

Modified:
  /test/test_driver.js

=======================================
--- /test/test_driver.js	Thu Jan 12 08:25:08 2012
+++ /test/test_driver.js	Thu Jan 12 09:08:00 2012
@@ -766,44 +766,6 @@
    });
  };

-exports.testBlob = function(test, assert) {
-  connect(function(err, con) {
-    if (err) {
-      assert.ok(false);
-      test.finish();
-    } else {
-      assert.ok(true);
-
-      var col = new Buffer('columnName');
-      var val = new Buffer('value');
-      var key = new Buffer('rowKey');
-      var updParms = [
-        col,
-        val,
-        key
-      ];
-      con.execute('UPDATE CfBytes SET ?=? WHERE KEY=?', updParms,  
function(updErr) {
-        if (updErr) {
-          con.close();
-          assert.ok(false);
-          test.finish();
-        } else {
-          con.execute('SELECT ? FROM CfBytes WHERE KEY=?', [col, key],  
function(selErr, rows) {
-            con.close();
-            assert.strictEqual(rows.rowCount(), 1);
-            var row = rows[0];
-            assert.strictEqual(1, row.colCount());
-            // Buffers cannot be compared in their native form, so we have  
to serialize them:
-            assert.strictEqual(col.toString('hex'),  
row.cols[0].name.toString('hex'));
-            assert.strictEqual(val.toString('hex'),  
row.cols[0].value.toString('hex'));
-            test.finish();
-          });
-        }
-      });
-    }
-  });
-};
-
  // this test only works an order-preserving partitioner.
  // it also uses an event-based approach to doing things.
  //exports.ZDISABLED_testMultipleRows = function(test, assert) {

==============================================================================
Revision: 0d9f2cef25ed
Author:   Christoph Tavan <dev@tavan.de>
Date:     Fri Feb  3 02:40:10 2012
Log:      Switch to helenus-thrift client

http://code.google.com/a/apache-extras.org/p/cassandra-node/source/detail?r=0d9f2cef25ed

Modified:
  /lib/driver.js
  /lib/gen-nodejs/Cassandra.js
  /lib/gen-nodejs/cassandra_types.js
  /lib/system.js
  /package.json

=======================================
--- /lib/driver.js	Fri Feb  3 07:43:44 2012
+++ /lib/driver.js	Fri Feb  3 02:40:10 2012
@@ -21,7 +21,7 @@
  var constants = require('constants');
  var EventEmitter = require('events').EventEmitter;

-var thrift = require('thrift');
+var thrift = require('helenus-thrift');
  var async = require('async');
  var Cassandra = require('./gen-nodejs/Cassandra');
  var ttypes = require('./gen-nodejs/cassandra_types');
=======================================
--- /lib/gen-nodejs/Cassandra.js	Thu Jan 12 09:21:14 2012
+++ /lib/gen-nodejs/Cassandra.js	Fri Feb  3 02:40:10 2012
@@ -3,7 +3,7 @@
  //
  // DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
  //
-var Thrift = require('thrift').Thrift;
+var Thrift = require('helenus-thrift').Thrift;

  var ttypes = require('./cassandra_types');
  //HELPER FUNCTIONS AND STRUCTURES
=======================================
--- /lib/gen-nodejs/cassandra_types.js	Thu Jan 12 09:21:14 2012
+++ /lib/gen-nodejs/cassandra_types.js	Fri Feb  3 02:40:10 2012
@@ -3,7 +3,7 @@
  //
  // DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
  //
-var Thrift = require('thrift').Thrift;
+var Thrift = require('helenus-thrift').Thrift;
  var ttypes = module.exports = {};
  ttypes.ConsistencyLevel = {
  'ONE' : 1,
=======================================
--- /lib/system.js	Thu Jan 26 14:40:08 2012
+++ /lib/system.js	Fri Feb  3 02:40:10 2012
@@ -18,7 +18,7 @@
  var util = require('util');
  var EventEmitter = require('events').EventEmitter;

-var thrift = require('thrift');
+var thrift = require('helenus-thrift');
  var Cassandra = require('./gen-nodejs/Cassandra');
  var ttypes = require('./gen-nodejs/cassandra_types');

=======================================
--- /package.json	Fri Feb  3 07:44:05 2012
+++ /package.json	Fri Feb  3 02:40:10 2012
@@ -27,7 +27,7 @@
    },
    "dependencies": {
      "async": ">= 0.1.12",
-    "thrift": ">= 0.6.0-1",
+    "helenus-thrift": "~0.7.2",
      "whiskey": ">= 0.6.1",
      "node-uuid": ">= 1.3.3"
    },

Mime
View raw message