Performance: Creating notifications
MEDIUM IMPACT
This affects how quickly notifications are generated and delivered, impacting server response time and user experience.
Notification::send($user, (new InvoicePaid($invoice))->onQueue('notifications'));Notification::send($user, new InvoicePaid($invoice));
| Pattern | Server Blocking | Queue Usage | User Response Delay | Verdict |
|---|---|---|---|---|
| Synchronous notification sending | High (blocks request) | No | Increases by 100-300ms | [X] Bad |
| Queued notification sending | Low (non-blocking) | Yes | Minimal delay | [OK] Good |