diff --git a/docs/decisions/0004-events-status.rst b/docs/decisions/0004-events-status.rst new file mode 100644 index 00000000..2ecab1db --- /dev/null +++ b/docs/decisions/0004-events-status.rst @@ -0,0 +1,60 @@ +1. Events status +================ + +Status +------ + +Draft + +Context +------- + +Each Open edX Event will evolve according to the needs of the community. +For that reason, with this ADR, we attempt to define a lifecycle that each +event will follow individually. + +Decision +-------- + +Each Open edX Event will follow the following lifecycle: + +State 1. Provisional +~~~~~~~~~~~~~~~~~~~~ + +Events just created and accepted in the repository `openedx-events`, +these events haven't been accepted in Open edX platform or by the community. + +State 2. Active +~~~~~~~~~~~~~~~ + +Events being used by Open edX platform and by the community. + +State 3. Deprecated +~~~~~~~~~~~~~~~~~~~ + +Events that members of the community decide to deprecate in Open edX platform. + +State 4. Removed +~~~~~~~~~~~~~~~~~ + +Events that members of the community removed from Open edX platform after +documentation and discussion of the removal. + +State 5. Replaced +~~~~~~~~~~~~~~~~~ + +Events that members of the community replaced for another event after +documentation and discussion of the change. + + +Consequences +------------ + +1. Each event must carry its state in its code-annotation documentation. + +2. Each event must go through each state in order. First, must be created +in this repository with the state `provisional`, when Open edX accepts it +must change to `active` and when the community decides to deprecate it, it +must be updated to `deprecated`, then `removed` and `unused`. + +3. Each state must be up-to-date. diff --git a/openedx_events/learning/signals.py b/openedx_events/learning/signals.py index 80009c47..35bb8344 100644 --- a/openedx_events/learning/signals.py +++ b/openedx_events/learning/signals.py @@ -15,6 +15,7 @@ # .. event_name: STUDENT_REGISTRATION_COMPLETED # .. event_description: emitted when the user registration process in the LMS is completed. # .. event_data: UserData +# .. event_status: provisional STUDENT_REGISTRATION_COMPLETED = OpenEdxPublicSignal( event_type="org.openedx.learning.student.registration.completed.v1", data={ @@ -27,6 +28,7 @@ # .. event_name: SESSION_LOGIN_COMPLETED # .. event_description: emitted when the user's login process in the LMS is completed. # .. event_data: UserData +# .. event_status: provisional SESSION_LOGIN_COMPLETED = OpenEdxPublicSignal( event_type="org.openedx.learning.auth.session.login.completed.v1", data={ @@ -39,6 +41,7 @@ # .. event_name: COURSE_ENROLLMENT_CREATED # .. event_description: emitted when the user's enrollment process is completed. # .. event_data: CourseEnrollmentData +# .. event_status: provisional COURSE_ENROLLMENT_CREATED = OpenEdxPublicSignal( event_type="org.openedx.learning.course.enrollment.created.v1", data={ @@ -51,6 +54,7 @@ # .. event_name: COURSE_ENROLLMENT_CHANGED # .. event_description: emitted when the user's enrollment update process is completed. # .. event_data: CourseEnrollmentData +# .. event_status: provisional COURSE_ENROLLMENT_CHANGED = OpenEdxPublicSignal( event_type="org.openedx.learning.course.enrollment.changed.v1", data={ @@ -63,6 +67,7 @@ # .. event_name: COURSE_ENROLLMENT_CHANGED # .. event_description: emitted when the user's unenrollment process is completed. # .. event_data: CourseEnrollmentData +# .. event_status: provisional COURSE_UNENROLLMENT_COMPLETED = OpenEdxPublicSignal( event_type="org.openedx.learning.course.unenrollment.completed.v1", data={ @@ -75,6 +80,7 @@ # .. event_name: CERTIFICATE_CREATED # .. event_description: emitted when the user's certificate creation process is completed. # .. event_data: CertificateData +# .. event_status: provisional CERTIFICATE_CREATED = OpenEdxPublicSignal( event_type="org.openedx.learning.certificate.created.v1", data={ @@ -87,6 +93,7 @@ # .. event_name: CERTIFICATE_CHANGED # .. event_description: emitted when the user's certificate update process is completed. # .. event_data: CertificateData +# .. event_status: provisional CERTIFICATE_CHANGED = OpenEdxPublicSignal( event_type="org.openedx.learning.certificate.changed.v1", data={ @@ -99,6 +106,7 @@ # .. event_name: CERTIFICATE_REVOKED # .. event_description: emitted when the user's certificate annulation process is completed. # .. event_data: CertificateData +# .. event_status: provisional CERTIFICATE_REVOKED = OpenEdxPublicSignal( event_type="org.openedx.learning.certificate.revoked.v1", data={ @@ -111,6 +119,7 @@ # .. event_name: COHORT_MEMBERSHIP_CHANGED # .. event_description: emitted when the user's cohort update is completed. # .. event_data: CohortData +# .. event_status: provisional COHORT_MEMBERSHIP_CHANGED = OpenEdxPublicSignal( event_type="org.openedx.learning.cohort_membership.changed.v1", data={