mirror of
https://github.com/trustgraph-ai/trustgraph.git
synced 2026-07-11 22:32:12 +02:00
Add CASSANDRA_REPLICATION_FACTOR environment variable and --cassandra-replication-factor CLI argument to cassandra_config.py. Update all four table store constructors (ConfigTableStore, KnowledgeTableStore, LibraryTableStore, IamTableStore) to accept an optional replication_factor parameter and use it in keyspace creation CQL queries. Thread the replication factor through all service constructors: Configuration, KnowledgeManager, Librarian, IamService, and knowledge store Processor.
This commit is contained in:
parent
f9d6606423
commit
e23d4a5b58
10 changed files with 46 additions and 20 deletions
|
|
@ -11,13 +11,14 @@ logger = logging.getLogger(__name__)
|
|||
|
||||
class Configuration:
|
||||
|
||||
def __init__(self, push, host, username, password, keyspace):
|
||||
def __init__(self, push, host, username, password, keyspace,
|
||||
replication_factor=1):
|
||||
|
||||
# External function to respond to update
|
||||
self.push = push
|
||||
|
||||
self.table_store = ConfigTableStore(
|
||||
host, username, password, keyspace
|
||||
host, username, password, keyspace, replication_factor
|
||||
)
|
||||
|
||||
async def inc_version(self):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue