File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -326,6 +326,7 @@ def _trigger_async_index_update(self, model_groups):
326326 # Import here to avoid circular import
327327 from django .conf import settings # noqa: PLC0415 circular import
328328
329+ from dojo .celery_dispatch import dojo_dispatch_task # noqa: PLC0415 circular import
329330 from dojo .tasks import update_watson_search_index_for_model # noqa: PLC0415 circular import
330331
331332 # Create tasks per model type, chunking large lists into configurable batches
@@ -337,4 +338,4 @@ def _trigger_async_index_update(self, model_groups):
337338 # Create tasks for each batch and log each one
338339 for i , batch in enumerate (batches , 1 ):
339340 logger .debug (f"AsyncSearchContextMiddleware: Triggering batch { i } /{ len (batches )} for { model_name } : { len (batch )} instances" )
340- update_watson_search_index_for_model ( model_name , batch )
341+ dojo_dispatch_task ( update_watson_search_index_for_model , model_name , batch )
You can’t perform that action at this time.
0 commit comments