this post was submitted on 23 Jun 2025
12 points (100.0% liked)
Golang
2482 readers
2 users here now
This is a community dedicated to the go programming language.
Useful Links:
Rules:
- Posts must be relevant to Go
- No NSFW content
- No hate speech, bigotry, etc
- Try to keep discussions on topic
- No spam of tools/companies/advertisements
- It’s OK to post your own stuff part of the time, but the primary use of the community should not be self-promotion.
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
This has worked well for me before, on a small scale https://github.com/robfig/cron
Note that while it is simple, you have to handle schedule persistence yourself, unlike the 2 you linked since they are backed by pg or redis
correct me if I'm wrong, but it seems like this wouldn't scale well
In what way? You haven't provided any information about scaling requirements
I would have to store the users' cron jobs in a database, and then run some kind of loop on startup to start the cron jobs.
That is accurate, though it doesn't say anything about scaling requirements
Oops, missed that part. Ideally, this would be able to handle thousands of users
Thousands is nothing, so having a single service holding the info on memory shouldn't be a problem