-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: add real life use cases based on community adoption
- Loading branch information
1 parent
3bf528b
commit 6ae8ceb
Showing
1 changed file
with
137 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,137 @@ | ||
Real-Life Use Cases for Open edX Events | ||
======================================= | ||
|
||
Overview | ||
-------- | ||
|
||
As mentioned in the Hooks Extension Framework, Open edX Events can be used to integrate application components with each other or with external services, allowing them to communicate, synchronize, and perform additional actions when specific triggers occur. | ||
|
||
To illustrate the different solutions that can be implemented with this framework, we have compiled a list of implementations built using Open edX Events to address various challenges. | ||
|
||
The goal of this list is to serve as a reference for extension developers to implement their own solutions in their own plugins or IDAs based on the community's experience. | ||
|
||
Communication, coordination or synchronization between IDAs | ||
------------------------------------------------------------ | ||
|
||
Communication between IDAs in the Open edX ecosystem is currently managed through an event-based architecture implemented via Event Bus. | ||
|
||
The Event Bus functionality for asynchronous communication between services is built on top of sending Open edX Events (Open edX-specific Django signals) within a service. The Event Bus extends these signals, allowing them to be broadcast and handled across multiple services. For more details on the Event Bus, please see `How to Start Using the Event Bus`_. | ||
|
||
Here are some examples of how the Event Bus can be used to facilitate communication between IDAs: | ||
|
||
Exam Downstream Effects | ||
*********************** | ||
|
||
The edx-exams service adopts an event-driven architecture, using the event bus to allow communication with edx-platform to downstream effects. Unlike the legacy exams system (`edx-proctoring`_), which relied on direct function calls to edx-platform services, the event bus allows edx-exams to emit events, triggering responses like grade overrides without creating dependencies between the two. | ||
|
||
This approach implements a modular and scalable system by enabling edx-exams to function independently from edx-platform while still interacting through asynchronous communication. | ||
|
||
More details on: `ADR Implementation of Event Driven Architecture for Exam Downstream Effects`_. | ||
|
||
Course Metadata Synchronization | ||
******************************* | ||
|
||
An event is emitted each time a course is published by the CMS, which is sent to the event bus and received by the Course Discovery service. This process allows course discovery to automatically update course metadata, ensuring that any changes in the CMS are reflected. By communicating through the event bus, this setup decreases the need for manual data syncs, keeping course metadata consistently up-to-date across services. | ||
|
||
More details on: `Use Event Bus to Replace Refresh Course Metadata`_. | ||
|
||
Credentials Management | ||
********************** | ||
|
||
When the LMS emits certificate-related events, they are sent to the event bus and consumed by the Credentials service. Based on the event type, the credentials can automatically award or revoke learner credentials. This integration simplifies credential management by enabling real-time updates from the LMS, ensuring appropiate generation of learner credentials without requiring manual synchronization. | ||
|
||
More details on: `Credentials - Event Bus`_. | ||
|
||
Credly Integration | ||
****************** | ||
|
||
The LMS sends events about learner progress, like course and section completions, to the event bus. The Credentials service then receives these events, adds extra information, and forwards them to external credential providers such as Credly, Accredible, or OBv3. These providers create and display digital credentials for learners based on the completion data. | ||
|
||
More details on: `Credly Integration`_. | ||
|
||
Real-Time Event Tracking | ||
************************ | ||
|
||
To make event tracking faster and more efficient, tracking logs are optionally sent through the event bus instead of the traditional method, which relied on asynchronous tasks to process logs. A signal listens for each tracking event and sends it directly to the event bus, allowing real-time updates. This new approach improves performance by reducing delays, as logs now reach the Aspects stack in a near real-time manner. | ||
|
||
More details on: `Real-Time Event Tracking`_. | ||
|
||
Communication, coordination or synchronization between application components | ||
----------------------------------------------------------------------------- | ||
|
||
Open edX Events can also be used to facilitate communication between different application components, allowing them to interact and synchronize their actions. Here are some examples of how Open edX Events can be used to coordinate between application components: | ||
|
||
Automatic Content Tagging | ||
************************ | ||
|
||
When new content is created or existing content is edited, these events trigger updates to automatically apply relevant tags based on system-defined categories. This ensures that content is consistently tagged, reducing the need for manual tagging and keeping content classification up-to-date. | ||
|
||
More details on: `Automatic Content Tagging`_. | ||
|
||
Keep Search Indexes Up-To-Date | ||
****************************** | ||
|
||
Each time content is updated or created, an event is emitted that triggers Meilisearch to index the new content, automatically updating the search index with the latest content metadata. This ensure that all content changes are accurately reflected in search results. | ||
|
||
External Certificate Generation | ||
****************************** | ||
|
||
Open edX Events are sent after the certificate generation for a user when they complete a course, these events trigger the generation of corresponding certificates in an external system if the proper conditions are met. | ||
|
||
More details on: `External Certificate Generation`_. | ||
|
||
Automatic Group Association | ||
************************** | ||
|
||
Open edX Events are sent after a user enrolls into a course, these events trigger the association of the user into a pre-defined cohort based on the user's preference language. This way, instructors don't need to manually add a student into a cohort but it's automatically done reducing logistic efforts and a seamless integration with language-based restricted content. | ||
|
||
More details on: `Automatic Group Association`_. | ||
|
||
Linking In-Context Discussions to Units | ||
*************************************** | ||
|
||
Events are sent after the discussion configuration changes for the course structure, these trigger the update of the corresponding model associating discussion configuration to units. This allows the synchronization of discussion configurations for the course structure to the units approach in a more decentralized manner. | ||
|
||
More details on: `Linking In-Context Discussions to Units`_. | ||
|
||
Forum Emails Notifier with Digest Frequency | ||
******************************************* | ||
|
||
When new threads, responses or comments are created in the discussion forum events are sent with relevant information about what occurred, triggering email notifications with relevant information about the update based on the user's preferences. This allows users stay up-to-date with discussions threads and customize digest frequency for instructors. | ||
|
||
More details on: `Forum Emails Notifier with Digest Frequency`_. | ||
|
||
Webhooks Integration | ||
******************** | ||
|
||
A Webhook is a mechanism that triggers an HTTP POST request to a configurable URL when certain events happen in the platform, including information relevant to the event <taken from…>. When these events are sent, then the data is sent to services like Zapier or any other configured. | ||
|
||
More details on: | ||
|
||
* `Webhooks`_ | ||
* `Open edX Events Sender`_ | ||
* `Open edX Events To Zapier`_ | ||
|
||
Send ORA Submissions to Third-Party Plagiarism Services | ||
******************************************************* | ||
|
||
Each time a student submits an Open Response Assessment (ORA), an event is emitted triggering a request to external services to review the student response for plagiarism. This allows a seamless integration of tools to help instructors while grading. | ||
|
||
More details on: `Send ORA Submissions to Third-Party Plagiarism Services`_. | ||
|
||
.. _How to Start Using the Event Bus: https://openedx.atlassian.net/wiki/spaces/AC/pages/3508699151/How+to+start+using+the+Event+Bus | ||
.. _edx-proctoring: https://github.com/openedx/edx-proctoring | ||
.. _ADR Implementation of Event Driven Architecture for Exam Downstream Effects: https://github.com/edx/edx-exams/blob/main/docs/decisions/0004-downstream-effect-events.rst | ||
.. _Use Event Bus to Replace Refresh Course Metadata: https://github.com/openedx/course-discovery/blob/master/docs/decisions/0015-event-bus-with-rcm.rst | ||
.. _Credentials - Event Bus: https://github.com/openedx/credentials/blob/master/docs/event_bus.rst | ||
.. _Credly Integration: https://github.com/openedx/platform-roadmap/issues/280 | ||
.. _Real-Time Event Tracking: https://github.com/openedx/wg-data/issues/28 | ||
.. _Automatic Content Tagging: https://github.com/openedx/modular-learning/issues/78 | ||
.. _External Certificate Generation: https://github.com/eduNEXT/eox-nelp/blob/master/eox_nelp/signals/receivers.py#L113-L160 | ||
.. _Automatic Group Association: https://github.com/eduNEXT/openedx-unidigital/blob/main/openedx_unidigital/handlers.py#L26-L51 | ||
.. _Linking In-Context Discussions to Units: https://github.com/openedx/edx-platform/blob/master/openedx/core/djangoapps/discussions/docs/decisions/0004-in-context-discussions-linking.rst | ||
.. _Forum Emails Notifier with Digest Frequency: https://github.com/eduNEXT/platform-plugin-forum-email-notifier | ||
.. _Webhooks: https://github.com/aulasneo/openedx-webhooks?tab=readme-ov-file#introduction | ||
.. _Open edX Events Sender: https://github.com/open-craft/openedx-events-sender: | ||
.. _Open edX Events To Zapier: https://github.com/eduNEXT/openedx-events-2-zapier: | ||
.. _Send ORA Submissions to Third-Party Plagiarism Services: https://github.com/eduNEXT/platform-plugin-turnitin/blob/main/platform_plugin_turnitin/handlers.py#L9-L26 |