iachat/app
Pranav 661e905dbd
fix: Skip HookJob for inactive or irrelevant hooks (#12093)
On Aug 2, we had a P0 because of a sudden spike in Sidekiq jobs. The
queue went up to 100k jobs and workers scaled from 400 threads to 1000+.
Most of the jobs were HookJobs, and a large chunk of them were for
Linear but they weren’t doing anything useful.

Turns out, whenever there’s an update on a contact or conversation, we
were triggering all account-level hooks without checking if the event
was relevant. So if someone did a bulk import or ran an update, it would
enqueue a huge number of unnecessary jobs.

This PR adds two checks before enqueuing:
- Whether the hook is active
- Whether the event is relevant for that hook
2025-08-04 19:08:45 -07:00
..
actions fix: Disable enqueueing Avatar jobs if the URL is invalid (#12035) 2025-07-24 12:56:39 +04:00
assets feat: Hide installation identifier (#11722) 2025-06-17 15:45:40 -07:00
builders fix: missing metrics and labels from label summary (#11718) 2025-06-12 17:58:56 +05:30
channels fix: Move contact events to account stream rather than individual user stream (#11082) 2025-03-13 17:46:48 -07:00
controllers feat(cloud): Add support for viewing status of SSL in custom domains (#12011) 2025-07-30 10:52:47 -07:00
dashboards chore: improve plan-based feature handling with plan hierarchy (#11335) 2025-04-28 14:13:56 -07:00
dispatchers feat(ee): Add Captain features (#10665) 2025-01-14 16:15:47 -08:00
drops feat: Add the support for custom attributes in message variables (#8511) 2023-12-08 14:13:35 -08:00
fields chore: improve plan-based feature handling with plan hierarchy (#11335) 2025-04-28 14:13:56 -07:00
finders feat: Add support for search_conversations in copilot (#11520) 2025-05-20 19:22:17 -07:00
helpers chore: Add submenu for super admin settings (#11860) 2025-07-15 21:28:39 -07:00
javascript chore: Add new tab and copy link to conversation context menu (#12089) 2025-08-04 15:22:20 -07:00
jobs fix: Disable IMAP inboxes that requires authorization (#12092) 2025-08-01 16:32:29 -07:00
listeners fix: Skip HookJob for inactive or irrelevant hooks (#12093) 2025-08-04 19:08:45 -07:00
mailboxes chore: Add a condition to handle bounced email (#11873) 2025-08-01 14:43:46 +05:30
mailers fix: footer in ssl_instructions email (#12076) 2025-07-31 11:44:17 -07:00
models feat: Remove subscription on WhatsApp inbox delete (#11977) 2025-07-24 14:04:19 +04:00
policies feat(cloud): Add support for viewing status of SSL in custom domains (#12011) 2025-07-30 10:52:47 -07:00
presenters chore: Add a condition to handle bounced email (#11873) 2025-08-01 14:43:46 +05:30
services fix: Populate meta field for whatsApp shared contacts (#12097) 2025-08-04 14:50:45 -07:00
views feat(cloud): Add support for viewing status of SSL in custom domains (#12011) 2025-07-30 10:52:47 -07:00
workers feat: API Endpoints to update message status (#11387) 2025-04-29 15:33:11 -07:00