MCPcopy Create free account
hub / github.com/apache/cassandra-python-driver / _get_context

Function _get_context

cassandra/cqlengine/management.py:42–56  ·  view source on GitHub ↗

Return all the execution contexts

(keyspaces, connections)

Source from the content-addressed store, hash-verified

40
41
42def _get_context(keyspaces, connections):
43 """Return all the execution contexts"""
44
45 if keyspaces:
46 if not isinstance(keyspaces, (list, tuple)):
47 raise ValueError('keyspaces must be a list or a tuple.')
48
49 if connections:
50 if not isinstance(connections, (list, tuple)):
51 raise ValueError('connections must be a list or a tuple.')
52
53 keyspaces = keyspaces if keyspaces else [None]
54 connections = connections if connections else [None]
55
56 return product(connections, keyspaces)
57
58
59def create_keyspace_simple(name, replication_factor, durable_writes=True, connections=None):

Callers 2

sync_tableFunction · 0.85
drop_tableFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected