mirror of
https://github.com/langgenius/dify.git
synced 2026-04-29 12:37:20 +08:00
document indexing not bound to a Session (#21015)
Co-authored-by: xuhaixing <xuhaixing@itiger.com>
This commit is contained in:
parent
f6641c0f41
commit
f6aa2498a3
@ -30,11 +30,11 @@ def retry_document_indexing_task(dataset_id: str, document_ids: list[str]):
|
|||||||
logging.info(click.style("Dataset not found: {}".format(dataset_id), fg="red"))
|
logging.info(click.style("Dataset not found: {}".format(dataset_id), fg="red"))
|
||||||
db.session.close()
|
db.session.close()
|
||||||
return
|
return
|
||||||
|
tenant_id = dataset.tenant_id
|
||||||
for document_id in document_ids:
|
for document_id in document_ids:
|
||||||
retry_indexing_cache_key = "document_{}_is_retried".format(document_id)
|
retry_indexing_cache_key = "document_{}_is_retried".format(document_id)
|
||||||
# check document limit
|
# check document limit
|
||||||
features = FeatureService.get_features(dataset.tenant_id)
|
features = FeatureService.get_features(tenant_id)
|
||||||
try:
|
try:
|
||||||
if features.billing.enabled:
|
if features.billing.enabled:
|
||||||
vector_space = features.vector_space
|
vector_space = features.vector_space
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user