Live data from Hacker News

Deno Cron

deno.com

101–110 of 190 posts

Re: Deno Cron

#101
post #80

Earlier quoted context omitted.

Just a normal yaml file...? Why go through the complexity of putting it in another codebase when you can just make a single config file? There are probably some benefits of using the Deno.cron syntax for some functions, and benefits of using a config file for others, but acting like the only other option is "put it in a completely seperate codebase" doesn't make any sense to me.

Or even a crontab! You know, the thing that this is named after.

I think there are sensible reasons people don't like using unlabeled, whitespace-delimited formats that require an ascii-art diagram to explain in the modern day.

Re: Deno Cron

#102
post #72

Earlier quoted context omitted.

Okay, but who's taking care of the actual host? I know this is HN and we're all server admin wizards, but there is some effort and maintenance required. This is theoretically even easier than that. Yay for a spectrum of options!

That's an overblown problem, especially for a small business which is not going to have the infra problem of someone with scale problems. We've just been sold lies that pushed us to buy expensive clouds - and are not that much simpler than good old tools

I agree that "it's way too much effort to ever consider running your code on your own servers / EC2 instances" is overblown, and has very much favored cloud providers.

But for the specific problem of "I wanna execute some code on a regular schedule, but I want it to be production-ready", Deno Cron does seem much quicker and lighter than provisioning a host, setting up health checks, setting up remote access controls for new devs, etc.

There are obviously many people who would find it very easy to do all the "server-work" I'm describing. I am not one of them! This service looks awesome to me.

Re: Deno Cron

#103
post #43

Earlier quoted context omitted.

It is really disappointing to me when I hear takes like this. As an industry we are splitting the roles of programmers and engineers so that programmers can just throw spaghetti at the wall and it is the engineers problem to happily run it. We need more well rounded people that also fundamentally understand how their code is executing on the backend so performance and cost can be optimized.

> We need more well rounded people that also fundamentally understand how their code is executing on the backend so performance and cost can be optimized. There's also some sort of balance that needs to be struck. As a 'web developer'... to be 'well balanced', I need to understand (or dig in to) the minutia of: * JS build tools, syntax, oddities, versions, and be able to troubleshoot these in a variety of environment…

[deleted]

Re: Deno Cron

#104
post #37

I am a lead on a small startup team and one of the biggest pain points is dealing with infrastructure. We have no dedicated devops person and much of that work falls on me and other people who would be better writing code. I think the cloud paradigm is experiencing a shift. Few of us want to deal with cloud infrastructure (whether clicking around or via Terraform or equivalent) to execute a function every X minutes -…

> Honestly, I have never been a fan of managing services in AWS/GCP/etc - the setup overhead rarely seemed to outweigh the pros I just `ssh` into prod and `git pull` and either `docker compose up` or `kubectl apply` or `terraform apply` or `helm update` or `argocd sync`

Okay, this is either really good satire, or you are wildly overestimating the average startup engineer's knowledge of each of those tools and their configurations

Re: Deno Cron

#105
post #37

I am a lead on a small startup team and one of the biggest pain points is dealing with infrastructure. We have no dedicated devops person and much of that work falls on me and other people who would be better writing code. I think the cloud paradigm is experiencing a shift. Few of us want to deal with cloud infrastructure (whether clicking around or via Terraform or equivalent) to execute a function every X minutes -…

The "crappy bespoke cloud setup" is usually the result of people whose jobs are usually just regular app devs, but had been thrown into the infrastructure side head first. I think the key is to actually have someone who knows what they are talking about.

Unlike other people I don't think you need to hire someone directly. I do devops freelancing so you could hire someone like me. Or look online for various people that do it. I mean if its a toy app without many customers then who cares, but once you start scaling infrastructure gets to me more and more important.

Re: Deno Cron

#106
post #42

Earlier quoted context omitted.

You should check Windmill.dev.

I will check out windmill. Though it does look somewhat complex. One tangentially related is I'm looking for somewhere to just run a python script once a day. I'll see if I can do that with windmill.

We have been using a self-hosted Windmill instance for running batch processes in Production for a while now. It has been a very nice upgrade from cron jobs for us (adding captured job outputs, status info, ability to re-run jobs, etc).

Re: Deno Cron

#107

The AI-generated imagery at https://deno.com/blog/cron/cover.png is actually painful the longer you look at it. The multiple watch hands might be an artistic effect, but the clock lacks the tenth hour and has two elevenths, the dinosaur's legs make absolutely no sense, and the water reflections show a different pattern on the dinosaur legs and a completely different set of clock hands than what is visible above. I kn…

I mean, it's a hero image above a technical article. What percentage of readers even did look at it for more than one second?

I thought it was awesome, even though it was pretty obviously AI-generated for the reasons you stated.

Re: Deno Cron

#108
Overlapping as an option would be nice, if I'm using cron to pull data to append to a database, and the append fails, I can normally retry. However, without overlap, I can't sit there doing retries since that will block future cron runs.

Timezones would be nice, "This helps avoid issues with time zones which observe daylight saving time." But it also causes issues with daylight saving time. I can't run something at 9 in the morning, I need to run it 1-2 hours before-hand, calculate the offset, and then queue a run 1-2 hours later. Or I can run 2 crons and have one or the other die early. Point being, all solutions become very hacky very fast.

It would be nice if an object was passed to the handler that had a targetDate for the ideal start time would be, so runs can be easily labeled and separated.

Yes I could round the Date.now() to the last minute, however, if Deploy ever goes over the minute boundary, that's all kaput.

In a similar vein: Systemd timers have some nice features, AccuracySec/RandomizedDelaySec/FixedRandomDelay, some options similar to that would be nice (of course, with minute resolution instead) (and of course, fixed delay can be pre-calculated, but it would be nice to just say 30m and have deno runtime manage that for me)

https://www.freedesktop.org/software/systemd/man/latest/syst...

Re: Deno Cron

#109
post #74

Earlier quoted context omitted.

I wonder why more people don't just set up a cheap VM and run this sort of thing via crontab.

The same reason why most people stopped manually editing some random files via FTP to do deployments: to get a proper reproducible, automated and monitored production environment.

I think there's a threshold below which this is just unnecessary infrastructure overhead, and I'd posit that most cron use cases fall below this threshold. If yours is above it, well and good.

Re: Deno Cron

#110
post #62

Earlier quoted context omitted.

I wonder why more people don't just set up a cheap VM and run this sort of thing via crontab.

Does crontab on a self-managed VM guarantee at least once delivery? For many, if not most, use-cases that guarantee is critical.

No. But I don't think there's any environment out there that is going to 100% guarantee that your cron succeeds. Even if it is reenqueued on failure, it could just keep hitting the same problem and crashlooping. You still need some kind of failure reporting, and a human to jump in to fix whatever went wrong.
Post reply on HN