cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John R. Frank" <>
Subject Re: consistency level for "create keyspace"?
Date Wed, 05 Jun 2013 01:27:59 GMT

Further the question below, the same thing seems to happen with 
ColumnFamily:  If I make a ColumnFamily, and then don't wait long enough, 
an attempt to query it can fail if the particular node that gets queried 
does not know about it yet.  Is there something smarter to do than just 
try/except all such failures and sleep it off?

This is particularly cumbersome for writing tests that setup/teardown 
keyspaces repeatedly.


On Mon, 3 Jun 2013, John R. Frank wrote:

> C*
> When I create a keyspace with pycassa on a multi-node cluster, it takes some 
> time before all the nodes know about the keyspace.
> So, if I do this:
>    sm = SystemManager(random.choice(server_list))
>    sm.create_keyspace(keyspace, SIMPLE_STRATEGY, {'replication_factor': 
> '1'})
>    sm.close()
> and then immediately pick a different node, it often will raise 
> InvalidRequestException(why="Keyspace 'foo' does not exist")
> Is there a better way to handle this than just avoiding immediately asking 
> other nodes for the keyspace?
> John

View raw message