Merge pull request #542 from XuPeng-SH/track_0.6.0

[skip ci](shards): fix db create engine typo and exception errors
This commit is contained in:
XuPeng-SH 2019-11-26 14:55:08 +08:00 committed by GitHub
commit f0f3e96038
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 3 deletions

View File

@ -29,7 +29,7 @@ class DB:
self.engine = create_engine(url)
else:
self.engine = create_engine(uri, pool_size=pool_size,
pool_recycle=pool_size,
pool_recycle=pool_recycle,
pool_timeout=pool_timeout,
pool_pre_ping=pool_pre_ping,
echo=echo,

View File

@ -24,8 +24,11 @@ def resp_handler(err, error_code):
if resp_class == milvus_pb2.VectorIds:
return resp_class(status=status, vector_id_array=[])
if resp_class == milvus_pb2.TopKQueryResultList:
return resp_class(status=status, topk_query_result=[])
if resp_class == milvus_pb2.TopKQueryResult:
return resp_class(status=status,
row_num=0,
ids=[],
distances=[])
if resp_class == milvus_pb2.TableRowCount:
return resp_class(status=status, table_row_count=-1)