forked from phoenix-oss/llama-stack-mirror
add postgres kvstoreimpl (#374)
* add postgres kvstoreimpl * make table name configurable * add validator for table name * linter fix --------- Co-authored-by: Dinesh Yeduguru <dineshyv@fb.com>
This commit is contained in:
parent
8de845a96d
commit
dcd8cfe0f3
4 changed files with 131 additions and 2 deletions
|
@ -43,7 +43,9 @@ async def kvstore_impl(config: KVStoreConfig) -> KVStore:
|
|||
|
||||
impl = SqliteKVStoreImpl(config)
|
||||
elif config.type == KVStoreType.postgres.value:
|
||||
raise NotImplementedError()
|
||||
from .postgres import PostgresKVStoreImpl
|
||||
|
||||
impl = PostgresKVStoreImpl(config)
|
||||
else:
|
||||
raise ValueError(f"Unknown kvstore type {config.type}")
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue