Skip to content

Commit

Permalink
other management commands added on wordpress service (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
marslanabdulrauf authored Mar 8, 2023
1 parent 2528c04 commit 2bf8071
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions course_discovery/apps/edly_discovery_app/tasks.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
from celery.task import task
from celery.utils.log import get_task_logger
from django.core import management


from course_discovery.apps.course_metadata.data_loaders.api import (
CoursesApiDataLoader,
Expand Down Expand Up @@ -30,3 +32,7 @@ def run_dataloader(partner, course_id, service):
max_workers=1,
course_id=course_id
).ingest()

if service == 'wordpress':
management.call_command('update_index', '--disable-change-limit')
management.call_command('remove_unused_indexes')

0 comments on commit 2bf8071

Please sign in to comment.