Skip to content

Use Case Diagram (Final)

Mehmet Bora Sarioglu edited this page May 16, 2026 · 2 revisions

Use Case Diagram — Final Milestone

This page documents the use case surface of the MyMentorNet platform at the final-milestone tag. The use cases are split across the five actors that interact with the system so each diagram remains readable. Every use case below corresponds to a real REST endpoint, scheduled job, or AFTER_COMMIT listener verified against the deployed backend at https://mymentornet.org.

The actor hierarchy is:

  • Guest — unauthenticated visitor; only the authentication flows are reachable.
  • User — abstract authenticated user, specialised into Mentee, Mentor, and Admin (JPA JOINED inheritance on the users table). Use cases that any authenticated user can trigger (own profile, follow graph, social feed, notifications, messaging, reports, keyword mutes, taxonomy lookups) are folded into the per-role diagrams below to keep each one self-contained.
  • Mentee, Mentor, Admin — role-specific actors gated server-side by @PreAuthorize("hasRole(...)") on every privileged endpoint.
  • System / Scheduler — non-human actor representing the Spring @Scheduled jobs and the AFTER_COMMIT listeners that handle side effects asynchronously.

1. Guest — Authentication & Account Lifecycle

The full pre-authenticated surface. Spam-bot defences (form token + honeypot) are enforced by SpamDetectionService; the AFTER_COMMIT listener on registration may impose an automatic temporary ban if the bot-signal threshold is crossed.

Guest Use Cases

2. Mentee — Discovery, Mentorship Lifecycle (mentee side), Social, Reporting

The mentee-facing surface covers mentor discovery via the matching ranker, the request / cancellation / rating lifecycle, mentee-side mentorship participation (task submission, action-item completion, shared-goal authorship jointly with the mentor), and the user-facing reporting + social-feed surfaces.

Mentee Use Cases

3. Mentor — Mentee Discovery, Mentorship Lifecycle (mentor side), Peer Network

The mentor-facing surface mirrors the mentee side but owns the request-acceptance side of the lifecycle, milestone and task authorship, meeting scheduling, the iCalendar (RFC 5545) availability export, and the mentor-only peer-mentor messaging surface. The milestone-creation path is gated by MentorshipPreconditions.requireSharedGoal — milestones cannot be opened until the shared goal is defined.

Mentor Use Cases

4. Admin — Moderation, User Management, Direct Messaging

The admin-only moderation surface: user listing and ban administration, the polymorphic report queue and its state machine transitions, and the admin-direct / admin-broadcast messaging channels.

Admin Use Cases

5. System / Scheduler — Background Jobs & Inline Auto-actions

Periodic @Scheduled jobs (auto-cancel unconfirmed meetings, auto-complete expired mentorships, reminders, orphan-attachment cleanup, trending-hashtag refresh, ban expiry, token purges) plus the inline AFTER_COMMIT listeners that drive the auto-ban subsystem, social-feed STOMP fanout, and the For-You ranker's bandit posterior updates.

System / Scheduler Use Cases


Coverage notes

The five diagrams above collectively cover the entire deployed REST surface (129 paths, 156 operations — see the live OpenAPI spec at https://mymentornet.org/v3/api-docs) plus the scheduler / listener side. Two intentional omissions:

  • No logout use case. JWT auth is stateless; the client simply drops the token (AuthContext.logout in frontend/src/context/AuthContext.jsx). There is nothing on the server to invalidate before natural expiry, so a /api/auth/logout endpoint would be no-op work.
  • No "change password while authenticated" use case. Password mutation today goes through the forgot-password → emailed reset-token → reset-password chain. A first-party authenticated-change surface is not implemented and is therefore intentionally absent.

A single combined diagram covering all five actors at once (143 KB PNG) is also available at images/final-milestone/use-case-puml.png for cross-reference, but it is dense at this resolution and the per-actor split above is the canonical reading.

Source

Per-actor PlantUML sources are committed to this wiki at sources/final-milestone-diagrams/:

  • use-case-1-guest.puml
  • use-case-2-mentee.puml
  • use-case-3-mentor.puml
  • use-case-4-admin.puml
  • use-case-5-system.puml

A combined PlantUML source at sources/final-milestone-diagrams/use-case-diagram.puml and a Mermaid alternative at sources/final-milestone-diagrams/use-case-diagram.md are kept alongside.

Team Members

Lab Reports


Weekly Meetings


Customer Meetings


Stakeholder Meetings


Project Requirements


🎦 Scenarios and Mock-ups

Use Case Diagrams

Class Diagram

Sequence Diagrams

Test Plan and Coverage


Project Standards


Final Milestone and MVP Plan

MVP Report


Final Milestone Report

Per-Member Prompt Logs


Future Work

Clone this wiki locally