Sailday
A trip planner for a group cruise. It checks public prices every hour, compares them with the saved booking, graphs the history and sends opt-in alerts. Plans work offline and sync without losing anyone's edits.
- Hourlyprice checks that run in the database, even with the app closed
- 15 mincooldown shared by scheduled and manual checks
- 3 rolesowner, editor and viewer, enforced in PostgreSQL
- Offlineedits queued and synced; conflicting edits go to the user
Key decisionSeparate reading prices from collecting them. Opening the app reads saved prices; only a scheduled or deliberate check contacts the source, and a failed check keeps the last good price.
What it shows
Scheduled collection
Three pg_cron jobs collect public prices hourly. A queued job wakes a server function to send encrypted Web Push alerts, with bounded retries and expired-subscription cleanup.
Prices you can compare
Only quotes for the same sailing and room category count, compared with fare plus taxes rather than the deposit. Gaps in the data break the graph instead of showing a fake drop.
Permissions on the server
PostgreSQL checks the signed-in user and current membership on every edit. Invites are expiring, limited-use links stored as hashes.
Offline without lost work
Edits wait in a durable outbox. Separate field edits merge; two edits to the same field go to the user. The app never claims a save it hasn't confirmed.
Limits
- Automatic collection covers one sailing; other items use quotes entered by hand.
- Public prices are a guide; personal offers and repricing need confirming with the cruise line.
- Removing a member stops future access but can't erase what they already downloaded.
Discuss Sailday
Ask about scheduled jobs in the database, push notifications or offline sync. Email me at aagarwalcollege@gmail.com.