feat(signalr): Add real-time notifications for Epic/Story/Task operations
Extends SignalR notification system to cover all ProjectManagement CRUD operations:
Domain Events Created:
- EpicUpdatedEvent, EpicDeletedEvent
- StoryCreatedEvent, StoryUpdatedEvent, StoryDeletedEvent
- TaskCreatedEvent, TaskUpdatedEvent, TaskDeletedEvent, TaskAssignedEvent
Event Handlers Added (10 handlers):
- EpicCreatedEventHandler, EpicUpdatedEventHandler, EpicDeletedEventHandler
- StoryCreatedEventHandler, StoryUpdatedEventHandler, StoryDeletedEventHandler
- TaskCreatedEventHandler, TaskUpdatedEventHandler, TaskDeletedEventHandler
- TaskAssignedEventHandler
Infrastructure Extensions:
- Extended IProjectNotificationService with Epic/Story/Task methods
- Extended IRealtimeNotificationService with Epic/Story/Task methods
- Extended RealtimeNotificationService with implementations
- Extended ProjectNotificationServiceAdapter for delegation
Domain Changes:
- Updated EpicCreatedEvent to include TenantId (consistency with other events)
- Added Epic/Story/Task CRUD methods to Project aggregate root
- All operations raise appropriate domain events
Broadcasting Strategy:
- Created events: Broadcast to both project-{projectId} and tenant-{tenantId} groups
- Updated events: Broadcast to project-{projectId} group only
- Deleted events: Broadcast to project-{projectId} group only
- Assigned events: Broadcast to project-{projectId} group with assignment details
Test Results:
- All 192 domain tests passing
- Domain and Application layers compile successfully
- Event handlers auto-registered by MediatR
Files Changed:
- 9 new domain event files
- 10 new event handler files
- 3 service interfaces extended
- 2 service implementations extended
- 1 aggregate updated with event raising logic
- 1 test file updated for new event signature
Status: Complete real-time collaboration for ProjectManagement module
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -8,6 +8,22 @@ public interface IRealtimeNotificationService
|
||||
Task NotifyProjectArchived(Guid tenantId, Guid projectId);
|
||||
Task NotifyProjectUpdate(Guid tenantId, Guid projectId, object data);
|
||||
|
||||
// Epic notifications
|
||||
Task NotifyEpicCreated(Guid tenantId, Guid projectId, Guid epicId, object epic);
|
||||
Task NotifyEpicUpdated(Guid tenantId, Guid projectId, Guid epicId, object epic);
|
||||
Task NotifyEpicDeleted(Guid tenantId, Guid projectId, Guid epicId);
|
||||
|
||||
// Story notifications
|
||||
Task NotifyStoryCreated(Guid tenantId, Guid projectId, Guid epicId, Guid storyId, object story);
|
||||
Task NotifyStoryUpdated(Guid tenantId, Guid projectId, Guid epicId, Guid storyId, object story);
|
||||
Task NotifyStoryDeleted(Guid tenantId, Guid projectId, Guid epicId, Guid storyId);
|
||||
|
||||
// Task notifications
|
||||
Task NotifyTaskCreated(Guid tenantId, Guid projectId, Guid storyId, Guid taskId, object task);
|
||||
Task NotifyTaskUpdated(Guid tenantId, Guid projectId, Guid storyId, Guid taskId, object task);
|
||||
Task NotifyTaskDeleted(Guid tenantId, Guid projectId, Guid storyId, Guid taskId);
|
||||
Task NotifyTaskAssigned(Guid tenantId, Guid projectId, Guid taskId, Guid assigneeId);
|
||||
|
||||
// Issue notifications
|
||||
Task NotifyIssueCreated(Guid tenantId, Guid projectId, object issue);
|
||||
Task NotifyIssueUpdated(Guid tenantId, Guid projectId, object issue);
|
||||
|
||||
Reference in New Issue
Block a user