feat[Datasource]:add summary refresh (#1433)

Co-authored-by: hzh97 <2976151305@qq.com>
This commit is contained in:
Aries-ckt
2024-04-20 10:04:12 +08:00
committed by GitHub
parent 57be1ece18
commit b49b07f011
175 changed files with 61020 additions and 1494 deletions

View File

@@ -185,8 +185,11 @@ class ConnectorManager(BaseComponent):
async def async_db_summary_embedding(self, db_name, db_type):
"""Async db summary embedding."""
# TODO: async embedding
self.db_summary_client.db_summary_embedding(db_name, db_type)
executor = self.system_app.get_component(
ComponentType.EXECUTOR_DEFAULT, ExecutorFactory
).create() # type: ignore
executor.submit(self.db_summary_client.db_summary_embedding, db_name, db_type)
return True
def add_db(self, db_info: DBConfig):
"""Add db connect info.