Skip to content

Commit f6f2bbc

Browse files
committed
fixup! docs: add ADR for pathway catalog and content split
1 parent 306d91b commit f6f2bbc

3 files changed

Lines changed: 147 additions & 65 deletions

File tree

docs/openedx_learning/decisions/0004-pathway-catalog-content-split.rst

Lines changed: 29 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -33,31 +33,43 @@ Decisions
3333
1. A Pathway is split into two parts:
3434

3535
- **Catalog Pathway** - the learner-browsable, enrollable thing. It includes the display name, the description
36-
shown in the catalog, SEO metadata, and a **Category**: a student-facing label for the kind of Pathway it is
37-
(e.g. "Master's Degree", "Annual Training"). If it is specified, learners see the Category instead of the word
38-
"Pathway". The Catalog Pathway is **not versioned**.
36+
shown in the catalog, SEO metadata, and a **Category**. It is **not versioned**.
3937

4038
- **Pathway content** - the definition of the Pathway: its Items and its completion criteria. The content is
41-
**versioned**, so that we can always tell what the definition was at the moment a learner enrolled or earned a
42-
credential.
39+
**versioned**, so that we can always tell what the definition was at any given moment. A version of the Pathway
40+
content *implements* a Catalog Pathway.
4341

44-
2. In authoring contexts (Studio, Django admin, code, docs), the terminology is always "Pathway", with the Category
42+
2. The **Category** is a student-facing label for the kind of Pathway (e.g. "Master's Degree", "Annual Training").
43+
Learners see the Category rather than the word "Pathway". It is always required: rather than falling back to
44+
"Pathway" in code, we ship a default database entry with that name, so the behavior is uniform and operators can
45+
rename or extend the set without a code change.
46+
47+
3. In authoring contexts (Studio, Django admin, code, docs), the terminology is always "Pathway", with the Category
4548
shown explicitly. Relabelling is a learner-facing concern of the catalog side only.
4649

47-
3. Learners enroll against the Catalog Pathway. Progress and credential evaluation run against a version of the
48-
Pathway content.
50+
4. **Dependency direction: ``openedx_content`` knows about ``openedx_catalog``, never the reverse.** This has the
51+
following consequences:
52+
53+
- Pathway Items may reference ``CourseRun`` entities directly.
54+
- The link from a Catalog Pathway to the Pathway content that implements it lives on the content side.
55+
- Anything that has to tie the two sides together belongs in ``openedx_content``, or in something downstream of
56+
it, but never in ``openedx_catalog``.
57+
58+
5. **Enrollment** ties a learner to a Catalog Pathway. Progress is evaluated against the currently published
59+
content version, not against a version frozen at enrollment time, so that authoring changes reach learners who
60+
are already enrolled.
4961

5062
Example content of each model:
5163

52-
============================ ==========================
64+
============================ ===================================
5365
Catalog Pathway Pathway content
54-
============================ ==========================
66+
============================ ===================================
5567
Display name Pathway Items
5668
Category Completion criteria
57-
Description
58-
SEO metadata
69+
Description References to CourseRuns
70+
SEO metadata Link to the related Catalog Pathway
5971
Enrollment
60-
============================ ==========================
72+
============================ ===================================
6173

6274
.. Run `dot -Tsvg images/pathway-catalog-content.dot > images/pathway-catalog-content.svg` to regenerate the diagram
6375
after making changes to `images/pathway-catalog-content.dot`.
@@ -70,6 +82,8 @@ Consequences
7082
------------
7183

7284
- Catalog edits never create new content versions; definition edits (Items, criteria) always do.
73-
- Credential and progress records can reference the exact content version in effect at the time, keeping them
74-
auditable after the Pathway changes.
85+
- Because evaluation follows the published version rather than the enrollment-time version, edits to a Pathway apply
86+
to learners who are already enrolled, which is what we want, but it means edits need care and re-evaluation.
7587
- The unversioned Catalog Pathway can be long-lived even if its content definition is changed significantly over time.
88+
- The dependency direction means a Catalog Pathway cannot, on its own, tell which content implements it. Queries in
89+
that direction start from the content side.
Lines changed: 28 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,40 @@
11
digraph pathway_catalog_content {
22
rankdir=LR;
33
fontname="Helvetica";
4+
compound=true;
45
node [shape=box, style=rounded, fontname="Helvetica", fontsize=11];
56
edge [fontname="Helvetica", fontsize=10];
67

7-
learner [label="Learner", shape=ellipse];
8-
catalog [label="Catalog Pathway\n(not versioned)\nname, Category,\nmarketing, SEO"];
8+
subgraph cluster_catalog {
9+
label="openedx_catalog (not versioned)";
10+
fontsize=10;
11+
fontcolor="#4d4d4d";
12+
style=dashed;
13+
color="#b3b3b3";
14+
catalog [label="Catalog Pathway\n\nname, category,\ndescription, SEO"];
15+
courserun [label="CourseRun"];
16+
}
917

1018
subgraph cluster_content {
11-
label="Pathway content (versioned)";
12-
fontsize=11;
19+
label="openedx_content (versioned)";
20+
fontsize=10;
21+
fontcolor="#4d4d4d";
1322
style=dashed;
14-
v1 [label="v1: Items, criteria"];
15-
v2 [label="v2: Items, criteria"];
16-
v1 -> v2 [style=dotted, label="revision"];
23+
color="#b3b3b3";
24+
v1 [label="content v1\n\nItems, criteria"];
25+
v2 [label="content v2\n\nItems, criteria\n(currently published)"];
26+
v1 -> v2 [style=dotted, color="#808080", arrowsize=0.7, label="revision"];
1727
}
1828

19-
learner -> catalog [label="browses / enrolls"];
20-
catalog -> v2 [label="current definition"];
29+
user [label="User", shape=ellipse];
30+
enrollment [label="Enrollment"];
31+
32+
user -> enrollment [label="learner"];
33+
enrollment -> catalog [label="enrolled in"];
34+
enrollment -> v2 [label="progress evaluated\nagainst the currently\npublished version", style=dashed, color="#808080", fontcolor="#4d4d4d"];
35+
36+
v2 -> catalog [label="implements"];
37+
v2 -> courserun [label="Items reference"];
38+
39+
direction [label="dependency direction:\nopenedx_content knows about\nopenedx_catalog, never the reverse", shape=plaintext, fontsize=10, fontcolor="#4d4d4d"];
2140
}

docs/openedx_learning/decisions/images/pathway-catalog-content.svg

Lines changed: 90 additions & 41 deletions
Loading

0 commit comments

Comments
 (0)