Infrastructure low complexity backend
1
Dependencies
0
Dependents
3
Entities
0
Integrations

Description

Infrastructure adapter that subscribes to assignment status-change events from the backend event bus or database trigger layer. When an assignment transitions to 'completed', it dispatches the event to the Threshold Tracking Service for counter increment and threshold evaluation. Provides decoupled integration between the assignment lifecycle and threshold logic.

Feature: Assignment Threshold Tracking

assignment-completion-event-listener

Responsibilities

  • Subscribe to assignment status-change events for completed transitions
  • Filter relevant events (only completed status, not reversals or other statuses)
  • Invoke Threshold Tracking Service with normalized event payload
  • Handle retries and error logging for failed threshold evaluations

Interfaces

onAssignmentStatusChanged(event: AssignmentStatusEvent): void
filterCompleted(event: AssignmentStatusEvent): bool
dispatchToTrackingService(mentorId: String, assignmentId: String, orgId: String): void
handleProcessingError(event: AssignmentStatusEvent, error: Error): void

Relationships

Dependencies (1)

Components this component depends on