docbrown/app/workers
Vaidehi Joshi f71c8b16e7
Allow dynamic authoring of welcome notifications (#6045) [deploy]
* Add "Welcome" type to Broadcasts, allow dynamic "authoring" of Broadcasts

This adds a new `type_of` to the Broadcast model: "Welcome". As we begin to create a new "welcome notification" workflow, we'll categorize them by making them all of the same type.

This also adds a concept of a "welcoming user", which can be set via an ENV var. The WELCOMING_USER_ID will allow us to explicitly set (and change) which user in the database is the one that "sends" welcoming notification. In production, we plan for this to be dev.to/sloan.

* Allow WelcomeNotificationWorker to accept + send any kind of broadcast

This abstracts out the logic of deciding which broadcast to send from the woker into the calling method. This will help us send many different kinds of welcome notifications using one, resuable worker class.

* Raise if a Notification can't be created

* Add STAFF_USER_ID as an ENV var

This is in preparation for moving away from SiteConfig.staff_user_id, and replacing it with an ENV var. We will need to set this in production first, and then make a separate PR to replace all instances of staff_user_id with the newly-set ENV var.
2020-02-12 13:50:37 -08:00
..
articles Migrate update main image background job to sidekiq (#5345) [deploy] 2020-02-04 17:51:09 -08:00
badge_achievements Move BadgeAchievements::SendEmailNotificationWorker to Sidekiq (#5779) [deploy] 2020-01-31 14:45:32 -05:00
classified_listings Move Classified Listing Cache Buster to Sidekiq (#5408) [deploy] 2020-01-09 17:23:23 -05:00
comments Add article's record key to Fastly Surrogate-Key to separate caches (#5543) 2020-01-17 08:45:47 -05:00
events Move Events::BustCacheJob to Sidekiq and rename (#5379) 2020-01-06 15:51:46 -05:00
follows Add Follows::CreateChatChannelWorker for Sidekiq (#5458) 2020-01-20 08:23:44 -05:00
mentions Add mentions send email notifications worker (#5549) 2020-01-20 08:24:42 -05:00
metrics log Notification db table size (#5920) [deploy] 2020-02-06 08:33:04 -05:00
notifications Allow dynamic authoring of welcome notifications (#6045) [deploy] 2020-02-12 13:50:37 -08:00
organizations moving org bust cache job to sidekiq (#5406) [deploy] 2020-01-08 15:03:40 -05:00
pages pages bust cache job sidekiq refactor (#5338) [deploy] 2020-01-02 15:16:09 -05:00
podcast_episodes Migrate PodcastEpisodes::UpdateMediaUrlJob to PodcastEpisodes::UpdateMediaUrlWorker for Sidekiq (#5729) 2020-01-27 09:40:34 -05:00
podcasts Move Podcasts::GetEpisodesJob to Sidekiq (#5443) [deploy] 2020-02-06 09:42:55 -08:00
pro_memberships Replace ProMemberships::PopulateHistoryJob with ProMemberships::PopulateHistoryWorker for Sidekiq 5305 (#5584) 2020-01-20 13:45:21 -05:00
reactions Change BustReactableCacheJob to BustReactableCacheWorker and move to sidekiq (#5582) [deploy] 2020-02-12 11:50:40 -05:00
search Index Tags to Elasticsearch after they are created (#5958) [deploy] 2020-02-11 11:58:58 -05:00
streams Move Twitch webhook registration from ActiveJob to Sidekiq (#5414) 2020-01-14 11:55:35 -05:00
tags Move Tags::BustCacheJob to Sidekiq (#5870) [deploy] 2020-02-04 09:24:37 -08:00
users create Users::EstimateDefaultLanguageWorker for Sidekiq (#5697) [deploy] 2020-02-07 13:49:02 -05:00
webhook Move Webhook::DispatchEventJob to Sidekiq (#5722) [deploy] 2020-01-27 14:36:27 -05:00
export_content_worker.rb Move ExportContentJob to Sidekiq (#5688) [deploy] 2020-01-24 10:12:58 -08:00
rate_limit_checker_worker.rb Change RateLimitCheckerJob to RateLimitCheckerWorker and move to sidekiq (#5269) [deploy] 2019-12-27 16:09:25 -06:00
rss_reader_fetch_user_worker.rb Move RssReaderFetchUserJob to Sidekiq (#5685) [deploy] 2020-01-24 14:14:20 -08:00
slack_bot_ping_worker.rb Move SlackBotPingJob to Sidekiq (#5615) 2020-01-22 08:24:33 -05:00