Commit b2bb0ca
authored
[MBL-19563][Student] Add retry parameter to Pendo submission analytics (#3420)
## Summary
Adds a "Retry" parameter to all Pendo submission tracking events (both SUCCEEDED and FAILED) to distinguish between first-time submission attempts and retry attempts after failures. This enables product managers to accurately analyze submission success rates and understand whether high failure counts include multiple retry attempts from the same user.
## Changes
- Added `RETRY` constant to `AnalyticsParamConstants` in canvas-api-2 library
- Updated all 13 submission analytics events in `SubmissionWorker` to include retry parameter:
- Value = 1 if `retryCount > 0` (retry attempt)
- Value = 0 if `retryCount == 0` (first attempt)
- Leverages existing `retryCount` field from `CreateSubmissionEntity` added in MBL-19546
## Events Updated
All submission analytics events now include the retry parameter:
- `SUBMIT_MEDIARECORDING_SUCCEEDED` / `FAILED` (3 events)
- `SUBMIT_FILEUPLOAD_SUCCEEDED` / `FAILED` (2 events)
- `SUBMIT_TEXTENTRY_SUCCEEDED` / `FAILED` (2 events)
- `SUBMIT_URL_SUCCEEDED` / `FAILED` (2 events)
- `SUBMIT_STUDIO_SUCCEEDED` / `FAILED` (2 events)
- `SUBMIT_ANNOTATION_SUCCEEDED` / `FAILED` (2 events)
## Test Plan
### Manual Testing
1. Create an assignment requiring any submission type (text, file, URL, etc.)
2. As a student, submit to the assignment
3. Verify submission succeeds and check Pendo analytics event includes `retry: 0`
4. Simulate a network failure during submission (airplane mode or network throttling)
5. Retry the submission after the failure
6. Verify the retry attempt includes `retry: 1` in the Pendo analytics event
### Verification
- Pendo analytics events for successful first-time submissions should have `retry: 0`
- Pendo analytics events for retry attempts (after WorkManager retries) should have `retry: 1`
- All 13 submission events should include the retry parameter
refs: MBL-19563
affects: Student
release note: Improved analytics tracking for submission attempts to better distinguish between first attempts and retries
- [ ] Dark/light mode testing - N/A (analytics only, no UI changes)
- [ ] Landscape/tablet testing - N/A (analytics only, no UI changes)
- [ ] Accessibility testing - N/A (analytics only, no UI changes)
- [ ] Product approval - Not required (analytics enhancement)
🤖 Generated with [Claude Code](https://claude.com/claude-code)1 parent 5c1cd61 commit b2bb0ca
File tree
2 files changed
+14
-0
lines changed- apps/student/src/main/java/com/instructure/student/mobius/common/ui
- libs/canvas-api-2/src/main/java/com/instructure/canvasapi2/utils
2 files changed
+14
-0
lines changedLines changed: 13 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
249 | 249 | | |
250 | 250 | | |
251 | 251 | | |
| 252 | + | |
252 | 253 | | |
253 | 254 | | |
254 | 255 | | |
| |||
272 | 273 | | |
273 | 274 | | |
274 | 275 | | |
| 276 | + | |
275 | 277 | | |
276 | 278 | | |
277 | 279 | | |
| |||
281 | 283 | | |
282 | 284 | | |
283 | 285 | | |
| 286 | + | |
284 | 287 | | |
285 | 288 | | |
286 | 289 | | |
| |||
387 | 390 | | |
388 | 391 | | |
389 | 392 | | |
| 393 | + | |
390 | 394 | | |
391 | 395 | | |
392 | 396 | | |
| |||
409 | 413 | | |
410 | 414 | | |
411 | 415 | | |
| 416 | + | |
412 | 417 | | |
413 | 418 | | |
414 | 419 | | |
| |||
669 | 674 | | |
670 | 675 | | |
671 | 676 | | |
| 677 | + | |
672 | 678 | | |
673 | 679 | | |
674 | 680 | | |
675 | 681 | | |
676 | 682 | | |
| 683 | + | |
677 | 684 | | |
678 | 685 | | |
679 | 686 | | |
680 | 687 | | |
681 | 688 | | |
| 689 | + | |
682 | 690 | | |
683 | 691 | | |
684 | 692 | | |
685 | 693 | | |
686 | 694 | | |
| 695 | + | |
687 | 696 | | |
688 | 697 | | |
689 | 698 | | |
| |||
724 | 733 | | |
725 | 734 | | |
726 | 735 | | |
| 736 | + | |
727 | 737 | | |
728 | 738 | | |
729 | 739 | | |
730 | 740 | | |
731 | 741 | | |
| 742 | + | |
732 | 743 | | |
733 | 744 | | |
734 | 745 | | |
735 | 746 | | |
736 | 747 | | |
| 748 | + | |
737 | 749 | | |
738 | 750 | | |
739 | 751 | | |
740 | 752 | | |
741 | 753 | | |
| 754 | + | |
742 | 755 | | |
743 | 756 | | |
744 | 757 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
196 | 196 | | |
197 | 197 | | |
198 | 198 | | |
| 199 | + | |
199 | 200 | | |
200 | 201 | | |
201 | 202 | | |
| |||
0 commit comments