jazkarta / edx-platform

the edX learning management system (LMS) and course authoring tool, Studio
http://code.edx.org/
GNU Affero General Public License v3.0
1 stars 0 forks source link

Changes to a CCX course should emit a course_published event, #80

Closed pdpinch closed 9 years ago

pdpinch commented 9 years ago

... just like regular courses. (edX is willing to help with this one as we didn't discuss this specifically. It is a low effort ask and has lots of downstream value)

This is what triggers search indexing, as a well as course structure updates that Insights needs for
outline information. We're going to be building on the latter in order to make the expanded grade report
as well in Q4. Basically, it's all in the general theme of "Make CCX look like just another course to the
rest of the system"
pdpinch commented 9 years ago

Dave Ormsbee told us that edX would take care of this change.

pdpinch commented 9 years ago

After more discussion, Dave has asked us to take a first pass on this.

course_published (base_course_id) --> listener --> start celery task --> emit course_published event for all ccx_course_id derived from base_course_id.

for catching the publish signal:

https://github.com/edx/edx-platform/blob/master/openedx/core/djangoapps/content/course_structures/si...

you'd add a listener for that signal. when it was triggered, your listener would check to see if the course_id it was triggered with is a CCX course. if it was, then the listener does nothing. if it wasn't, the listener would check in its models as to whether there are any CCX courses that are derived from the published course_id. if there are, we'd loop through all of those and emit the course_published signal with the CCX course_ids.

the only wrinkle is that to be scalable, we'd probably want to have the listener itself be a celery task. so ccx would need a tasks.py similar to what's in:

https://github.com/edx/edx-platform/blob/master/lms/djangoapps/lti_provider/tasks.py

cguardia commented 9 years ago

The task looks to be pretty well defined, thanks. I will do this, most likely at the beginning of next week.

cguardia commented 9 years ago

@pdpinch Made PR https://github.com/edx/edx-platform/pull/9109.

pdpinch commented 9 years ago

Closed by https://github.com/edx/edx-platform/issues/9109