You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by br...@apache.org on 2014/07/29 20:59:25 UTC
[01/12] git commit: Handle KeyboardInterrupt properly in cqlsh
Repository: cassandra
Updated Branches:
refs/heads/cassandra-1.2 192596ad7 -> 249bbfc3b
refs/heads/cassandra-2.0 a5cc16d18 -> b44bbb83a
refs/heads/cassandra-2.1 a5bc52eee -> 6b47853d5
refs/heads/trunk 2827af469 -> 82211f698
Handle KeyboardInterrupt properly in cqlsh
Patch by Jordon Pittier, reviewed by brandonwilliams for CASSANDRA-5481
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/249bbfc3
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/249bbfc3
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/249bbfc3
Branch: refs/heads/cassandra-1.2
Commit: 249bbfc3b205d934764e5b05e955378f78c28480
Parents: 192596a
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:57:42 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:57:42 2014 -0500
----------------------------------------------------------------------
bin/cqlsh | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/249bbfc3/bin/cqlsh
----------------------------------------------------------------------
diff --git a/bin/cqlsh b/bin/cqlsh
index bb0ffdf..d2a503d 100755
--- a/bin/cqlsh
+++ b/bin/cqlsh
@@ -504,15 +504,9 @@ class Shell(cmd.Cmd):
self.conn = use_conn
else:
transport = transport_factory(hostname, port, os.environ, CONFIG_FILE)
- self.conn = cql.connect(hostname, port, user=username, password=password,
- cql_version=cqlver, transport=transport)
+ self.conn = cql.connect(hostname, port, keyspace=keyspace, user=username,
+ password=password, cql_version=cqlver, transport=transport)
self.set_expanded_cql_version(cqlver)
- # we could set the keyspace through cql.connect(), but as of 1.0.10,
- # it doesn't quote the keyspace for USE :(
- if keyspace is not None:
- tempcurs = self.conn.cursor()
- tempcurs.execute('USE %s;' % self.cql_protect_name(keyspace))
- tempcurs.close()
self.cursor = self.conn.cursor()
self.get_connection_versions()
@@ -1056,6 +1050,16 @@ class Shell(cmd.Cmd):
except CQL_ERRORS, err:
self.printerr(str(err))
return False
+ except KeyboardInterrupt:
+ self.cursor.close()
+ self.conn.terminate_connection()
+ transport = self.transport_factory(self.hostname, self.port,
+ os.environ, CONFIG_FILE)
+ self.conn = cql.connect(self.hostname, self.port, keyspace=self.keyspace,
+ user=self.username, password=self.password,
+ cql_version=self.cql_version, transport=transport)
+ self.cursor = self.conn.cursor()
+ return False
except Exception, err:
import traceback
self.printerr(traceback.format_exc())
[08/12] git commit: Merge branch 'cassandra-2.0' into cassandra-2.1.0
Posted by br...@apache.org.
Merge branch 'cassandra-2.0' into cassandra-2.1.0
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/90c81c78
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/90c81c78
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/90c81c78
Branch: refs/heads/trunk
Commit: 90c81c78f58bb281001267bc297f9f2dd10cadd9
Parents: 5544ecb b44bbb8
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:58:37 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:58:37 2014 -0500
----------------------------------------------------------------------
----------------------------------------------------------------------
[12/12] git commit: Merge branch 'cassandra-2.1' into trunk
Posted by br...@apache.org.
Merge branch 'cassandra-2.1' into trunk
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/82211f69
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/82211f69
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/82211f69
Branch: refs/heads/trunk
Commit: 82211f6987e58c2d74283252a0c6297ab57b3272
Parents: 2827af4 6b47853
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:59:18 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:59:18 2014 -0500
----------------------------------------------------------------------
----------------------------------------------------------------------
[09/12] git commit: Merge branch 'cassandra-2.0' into cassandra-2.1.0
Posted by br...@apache.org.
Merge branch 'cassandra-2.0' into cassandra-2.1.0
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/90c81c78
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/90c81c78
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/90c81c78
Branch: refs/heads/cassandra-2.1
Commit: 90c81c78f58bb281001267bc297f9f2dd10cadd9
Parents: 5544ecb b44bbb8
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:58:37 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:58:37 2014 -0500
----------------------------------------------------------------------
----------------------------------------------------------------------
[10/12] git commit: Merge branch 'cassandra-2.1.0' into cassandra-2.1
Posted by br...@apache.org.
Merge branch 'cassandra-2.1.0' into cassandra-2.1
Conflicts:
CHANGES.txt
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/6b47853d
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/6b47853d
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/6b47853d
Branch: refs/heads/cassandra-2.1
Commit: 6b47853d5a1064ae0742237c0d4ac8766d8c2a6f
Parents: a5bc52e 90c81c7
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:59:09 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:59:09 2014 -0500
----------------------------------------------------------------------
----------------------------------------------------------------------
[11/12] git commit: Merge branch 'cassandra-2.1.0' into cassandra-2.1
Posted by br...@apache.org.
Merge branch 'cassandra-2.1.0' into cassandra-2.1
Conflicts:
CHANGES.txt
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/6b47853d
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/6b47853d
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/6b47853d
Branch: refs/heads/trunk
Commit: 6b47853d5a1064ae0742237c0d4ac8766d8c2a6f
Parents: a5bc52e 90c81c7
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:59:09 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:59:09 2014 -0500
----------------------------------------------------------------------
----------------------------------------------------------------------
[03/12] git commit: Handle KeyboardInterrupt properly in cqlsh
Posted by br...@apache.org.
Handle KeyboardInterrupt properly in cqlsh
Patch by Jordon Pittier, reviewed by brandonwilliams for CASSANDRA-5481
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/249bbfc3
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/249bbfc3
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/249bbfc3
Branch: refs/heads/cassandra-2.1
Commit: 249bbfc3b205d934764e5b05e955378f78c28480
Parents: 192596a
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:57:42 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:57:42 2014 -0500
----------------------------------------------------------------------
bin/cqlsh | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/249bbfc3/bin/cqlsh
----------------------------------------------------------------------
diff --git a/bin/cqlsh b/bin/cqlsh
index bb0ffdf..d2a503d 100755
--- a/bin/cqlsh
+++ b/bin/cqlsh
@@ -504,15 +504,9 @@ class Shell(cmd.Cmd):
self.conn = use_conn
else:
transport = transport_factory(hostname, port, os.environ, CONFIG_FILE)
- self.conn = cql.connect(hostname, port, user=username, password=password,
- cql_version=cqlver, transport=transport)
+ self.conn = cql.connect(hostname, port, keyspace=keyspace, user=username,
+ password=password, cql_version=cqlver, transport=transport)
self.set_expanded_cql_version(cqlver)
- # we could set the keyspace through cql.connect(), but as of 1.0.10,
- # it doesn't quote the keyspace for USE :(
- if keyspace is not None:
- tempcurs = self.conn.cursor()
- tempcurs.execute('USE %s;' % self.cql_protect_name(keyspace))
- tempcurs.close()
self.cursor = self.conn.cursor()
self.get_connection_versions()
@@ -1056,6 +1050,16 @@ class Shell(cmd.Cmd):
except CQL_ERRORS, err:
self.printerr(str(err))
return False
+ except KeyboardInterrupt:
+ self.cursor.close()
+ self.conn.terminate_connection()
+ transport = self.transport_factory(self.hostname, self.port,
+ os.environ, CONFIG_FILE)
+ self.conn = cql.connect(self.hostname, self.port, keyspace=self.keyspace,
+ user=self.username, password=self.password,
+ cql_version=self.cql_version, transport=transport)
+ self.cursor = self.conn.cursor()
+ return False
except Exception, err:
import traceback
self.printerr(traceback.format_exc())
[02/12] git commit: Handle KeyboardInterrupt properly in cqlsh
Posted by br...@apache.org.
Handle KeyboardInterrupt properly in cqlsh
Patch by Jordon Pittier, reviewed by brandonwilliams for CASSANDRA-5481
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/249bbfc3
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/249bbfc3
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/249bbfc3
Branch: refs/heads/cassandra-2.0
Commit: 249bbfc3b205d934764e5b05e955378f78c28480
Parents: 192596a
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:57:42 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:57:42 2014 -0500
----------------------------------------------------------------------
bin/cqlsh | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/249bbfc3/bin/cqlsh
----------------------------------------------------------------------
diff --git a/bin/cqlsh b/bin/cqlsh
index bb0ffdf..d2a503d 100755
--- a/bin/cqlsh
+++ b/bin/cqlsh
@@ -504,15 +504,9 @@ class Shell(cmd.Cmd):
self.conn = use_conn
else:
transport = transport_factory(hostname, port, os.environ, CONFIG_FILE)
- self.conn = cql.connect(hostname, port, user=username, password=password,
- cql_version=cqlver, transport=transport)
+ self.conn = cql.connect(hostname, port, keyspace=keyspace, user=username,
+ password=password, cql_version=cqlver, transport=transport)
self.set_expanded_cql_version(cqlver)
- # we could set the keyspace through cql.connect(), but as of 1.0.10,
- # it doesn't quote the keyspace for USE :(
- if keyspace is not None:
- tempcurs = self.conn.cursor()
- tempcurs.execute('USE %s;' % self.cql_protect_name(keyspace))
- tempcurs.close()
self.cursor = self.conn.cursor()
self.get_connection_versions()
@@ -1056,6 +1050,16 @@ class Shell(cmd.Cmd):
except CQL_ERRORS, err:
self.printerr(str(err))
return False
+ except KeyboardInterrupt:
+ self.cursor.close()
+ self.conn.terminate_connection()
+ transport = self.transport_factory(self.hostname, self.port,
+ os.environ, CONFIG_FILE)
+ self.conn = cql.connect(self.hostname, self.port, keyspace=self.keyspace,
+ user=self.username, password=self.password,
+ cql_version=self.cql_version, transport=transport)
+ self.cursor = self.conn.cursor()
+ return False
except Exception, err:
import traceback
self.printerr(traceback.format_exc())
[05/12] git commit: Merge branch 'cassandra-1.2' into cassandra-2.0
Posted by br...@apache.org.
Merge branch 'cassandra-1.2' into cassandra-2.0
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/b44bbb83
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/b44bbb83
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/b44bbb83
Branch: refs/heads/cassandra-2.1
Commit: b44bbb83aa997a583dbbdeb7b1375e999fac6dda
Parents: a5cc16d 249bbfc
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:58:27 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:58:27 2014 -0500
----------------------------------------------------------------------
bin/cqlsh | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/b44bbb83/bin/cqlsh
----------------------------------------------------------------------
[06/12] git commit: Merge branch 'cassandra-1.2' into cassandra-2.0
Posted by br...@apache.org.
Merge branch 'cassandra-1.2' into cassandra-2.0
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/b44bbb83
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/b44bbb83
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/b44bbb83
Branch: refs/heads/cassandra-2.0
Commit: b44bbb83aa997a583dbbdeb7b1375e999fac6dda
Parents: a5cc16d 249bbfc
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:58:27 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:58:27 2014 -0500
----------------------------------------------------------------------
bin/cqlsh | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/b44bbb83/bin/cqlsh
----------------------------------------------------------------------
[04/12] git commit: Handle KeyboardInterrupt properly in cqlsh
Posted by br...@apache.org.
Handle KeyboardInterrupt properly in cqlsh
Patch by Jordon Pittier, reviewed by brandonwilliams for CASSANDRA-5481
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/249bbfc3
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/249bbfc3
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/249bbfc3
Branch: refs/heads/trunk
Commit: 249bbfc3b205d934764e5b05e955378f78c28480
Parents: 192596a
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:57:42 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:57:42 2014 -0500
----------------------------------------------------------------------
bin/cqlsh | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/249bbfc3/bin/cqlsh
----------------------------------------------------------------------
diff --git a/bin/cqlsh b/bin/cqlsh
index bb0ffdf..d2a503d 100755
--- a/bin/cqlsh
+++ b/bin/cqlsh
@@ -504,15 +504,9 @@ class Shell(cmd.Cmd):
self.conn = use_conn
else:
transport = transport_factory(hostname, port, os.environ, CONFIG_FILE)
- self.conn = cql.connect(hostname, port, user=username, password=password,
- cql_version=cqlver, transport=transport)
+ self.conn = cql.connect(hostname, port, keyspace=keyspace, user=username,
+ password=password, cql_version=cqlver, transport=transport)
self.set_expanded_cql_version(cqlver)
- # we could set the keyspace through cql.connect(), but as of 1.0.10,
- # it doesn't quote the keyspace for USE :(
- if keyspace is not None:
- tempcurs = self.conn.cursor()
- tempcurs.execute('USE %s;' % self.cql_protect_name(keyspace))
- tempcurs.close()
self.cursor = self.conn.cursor()
self.get_connection_versions()
@@ -1056,6 +1050,16 @@ class Shell(cmd.Cmd):
except CQL_ERRORS, err:
self.printerr(str(err))
return False
+ except KeyboardInterrupt:
+ self.cursor.close()
+ self.conn.terminate_connection()
+ transport = self.transport_factory(self.hostname, self.port,
+ os.environ, CONFIG_FILE)
+ self.conn = cql.connect(self.hostname, self.port, keyspace=self.keyspace,
+ user=self.username, password=self.password,
+ cql_version=self.cql_version, transport=transport)
+ self.cursor = self.conn.cursor()
+ return False
except Exception, err:
import traceback
self.printerr(traceback.format_exc())
[07/12] git commit: Merge branch 'cassandra-1.2' into cassandra-2.0
Posted by br...@apache.org.
Merge branch 'cassandra-1.2' into cassandra-2.0
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/b44bbb83
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/b44bbb83
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/b44bbb83
Branch: refs/heads/trunk
Commit: b44bbb83aa997a583dbbdeb7b1375e999fac6dda
Parents: a5cc16d 249bbfc
Author: Brandon Williams <br...@apache.org>
Authored: Tue Jul 29 13:58:27 2014 -0500
Committer: Brandon Williams <br...@apache.org>
Committed: Tue Jul 29 13:58:27 2014 -0500
----------------------------------------------------------------------
bin/cqlsh | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/b44bbb83/bin/cqlsh
----------------------------------------------------------------------