TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask HN: How to design a back in stock notification system?

2 点作者 samrohn777超过 3 年前
I want to design a back in stock notification email service, where the users can sign up on the out-of-stock page and get notified when the item is back in stock. If I have the list of users subscribed to back in stock alert and another table that has latest stock availability, what would be the best appraoch to build an efficient system that looks at these data and trigger back in stock email ? - Do I poll the stock table for change in stock and then compare with user table and trigger email ? - Is there any other better ways of doing it ? Is there any design patterns/ specific tools/ constructs to solve such problems ? I am gravitating towards as event driven model - but not sure what to look out for this problem statement. I am not looking for a complete solution, but opinions/ pointers to any resource would be greatly appreciated.

1 comment

tony-allan超过 3 年前
Keep it simple -- how often do you need to send the emails? One a day, once an hour, after you update your stock items. Just check periodically.<p>Do you want to consolidate emails if a user had multiple alerts?
评论 #28930091 未加载